102 lines
7.6 KiB
Swift
102 lines
7.6 KiB
Swift
import Foundation
|
|
|
|
// English is the explicit first-launch default, independent of macOS language.
|
|
enum EasyLanguage: String, CaseIterable {
|
|
case english = "en"
|
|
case spanish = "es"
|
|
static func load(defaults: UserDefaults = .standard) -> EasyLanguage {
|
|
EasyLanguage(rawValue: defaults.string(forKey:"interfaceLanguage") ?? "en") ?? .english
|
|
}
|
|
func save(defaults: UserDefaults = .standard) { defaults.set(rawValue,forKey:"interfaceLanguage") }
|
|
}
|
|
|
|
struct EasyStrings {
|
|
static let english: [String:String] = [
|
|
"Juegos con soporte en la herramienta": "Supported game profiles",
|
|
"No incluye ni descarga juegos. Debes añadir tus propios archivos.": "No games are included or downloaded. You must add your own files.",
|
|
"Carpeta de tu juego": "Your game folder",
|
|
"Descargar Sideloadly": "Get Sideloadly",
|
|
"Enviar a Sideloadly": "Send to Sideloadly",
|
|
"Prepara tu juego.": "Prepare your game.",
|
|
"Creamos la IPA. La instalas en tu iPhone con Sideloadly.": "We create the IPA. You install it on your iPhone with Sideloadly.",
|
|
"Carpeta del juego": "Game folder",
|
|
"Con el juego base y sus actualizaciones.": "With the base game and its updates.",
|
|
"Elegir": "Choose",
|
|
"Carpeta de llaves": "Keys folder",
|
|
"Selecciona tus propias prod.keys.": "Select your own prod.keys.",
|
|
"Seleccionada": "Selected",
|
|
"Preparar juego": "Prepare game",
|
|
"Intentar de nuevo": "Try again",
|
|
"Listo. Instálalo en tu iPhone.": "Ready. Install it on your iPhone.",
|
|
"1. Envía la IPA a Sideloadly y pulsa Start con tu cuenta personal.": "1. Send the IPA to Sideloadly, then click Start with your personal account.",
|
|
"2. La primera vez, copia romfs por Finder → iPhone → Archivos → tu juego.": "2. First install: copy romfs using Finder → iPhone → Files → your game.",
|
|
"Mostrar datos del juego": "Show game data",
|
|
"Para actualizar: misma cuenta e identificador de Sideloadly. Instala encima, sin desinstalar.": "For updates: keep the same Sideloadly account and identifier. Install over the existing app; do not uninstall.",
|
|
"Preparar de nuevo": "Prepare again",
|
|
"Ver error": "View error",
|
|
"No pudimos preparar el juego.": "We could not prepare the game.",
|
|
"Instala Xcode y ábrelo una vez. Después vuelve a intentar.": "Install Xcode and open it once, then try again.",
|
|
"Instala Homebrew desde brew.sh y vuelve a intentar.": "Install Homebrew from brew.sh, then try again.",
|
|
"Actualiza Xcode: necesitas el SDK de iOS 26 o posterior.": "Update Xcode: iOS SDK 26 or newer is required.",
|
|
"Tus archivos anteriores se conservaron. Puedes ver o copiar el error para revisarlo.": "Your existing files were preserved. View or copy the error to review it.",
|
|
"Juegos del repositorio. Consulta cada ficha para ver dispositivos probados y versiones.": "Games listed by the repository. Check the notes for tested devices and versions.",
|
|
"juegos en la lista": "games listed",
|
|
"Buscar un juego": "Find a game",
|
|
"Versiones": "Versions",
|
|
|
|
"Ver todos": "View all",
|
|
"Todos los juegos": "All games",
|
|
"Cerrar": "Close",
|
|
"Limpiar búsqueda": "Clear search",
|
|
"No pudimos leer los perfiles. Comprueba que el repositorio siga en su ubicación original.": "Could not read the profiles. Check that the source checkout is still at its original location.",
|
|
"No encontramos juegos con esa búsqueda.": "No games match your search.",
|
|
"Ficha del juego": "Game notes",
|
|
|
|
"Tu próximo juego empieza aquí.": "Your next game starts here.",
|
|
"Elige su carpeta. Nosotros preparamos la IPA ligera.": "Choose its folder. We will prepare the lightweight IPA.",
|
|
"Ningún juego seleccionado": "No game selected",
|
|
"Elegir juego": "Choose game",
|
|
"Selecciona la carpeta con el juego base y sus actualizaciones NSP/XCI.": "Select the folder containing the base game and its NSP/XCI updates.",
|
|
"No encontramos el juego en esa carpeta.": "No game files found in that folder.",
|
|
"Elige la carpeta que contiene los archivos NSP o XCI directamente.": "Choose the folder that directly contains the NSP or XCI files.",
|
|
"Guarda el juego fuera del repositorio.": "Keep game files outside the repository.",
|
|
"Así tus juegos y llaves se quedan fuera de GitHub.": "This keeps your games and keys out of GitHub.",
|
|
"Listo para preparar el juego.": "Ready to prepare your game.",
|
|
"Un clic más. Los archivos anteriores se conservan.": "One more click. Existing files are preserved.",
|
|
"No pudimos leer esa carpeta.": "We could not read that folder.",
|
|
"Usar mis llaves": "Use my keys",
|
|
"Elige tu carpeta con prod.keys. No copiamos las llaves ni las incluimos en la app.": "Choose your folder containing prod.keys. Keys are not copied or bundled with this app.",
|
|
"Elige una carpeta externa con tu prod.keys.": "Choose an external folder containing your prod.keys.",
|
|
"No se proporcionan llaves. Debes seleccionar las tuyas.": "No keys are provided. You must select your own.",
|
|
"Tus llaves están seleccionadas.": "Your keys folder is selected.",
|
|
"Sólo guardamos la ruta en este Mac, nunca su contenido.": "Only the folder path is saved on this Mac, never its contents.",
|
|
"No encontramos el código de nxnative.": "The nxnative source checkout could not be found.",
|
|
"Vuelve a crear la app desde el repositorio con Abrir-interfaz.command.": "Recreate the app from the repository using Abrir-interfaz.command.",
|
|
"Preparando herramientas…": "Preparing build tools…",
|
|
"Puedes dejar esta ventana abierta. No necesitas usar Terminal.": "You can leave this window open. No Terminal commands are needed.",
|
|
"Preparación cancelada.": "Preparation cancelled.",
|
|
"Tus archivos y partidas anteriores se conservaron.": "Your existing files and saves were preserved.",
|
|
"Terminó, pero no encontramos la IPA.": "The process finished, but the IPA was not found.",
|
|
"Tu juego está listo para Sideloadly.": "Your game is ready for Sideloadly.",
|
|
"Usa Ver error para revisar lo que ocurrió.": "Use View error to review what happened.",
|
|
"Abre la IPA y arrástrala a Sideloadly. La firma se hace con tu cuenta personal.": "Show the IPA and drag it into Sideloadly. Sign it there with your personal account.",
|
|
"No pudimos iniciar la preparación.": "Preparation could not be started.",
|
|
"Creando tu IPA ligera…": "Creating your lightweight IPA…",
|
|
"Compilando la app para iPhone…": "Building the iPhone app…",
|
|
"Preparando los gráficos del juego…": "Preparing game graphics…",
|
|
"Preparando los archivos del juego…": "Preparing game files…",
|
|
"Cancelando…": "Cancelling…",
|
|
"Cambiar": "Change",
|
|
"Tus llaves: selecciona su carpeta": "Your keys: select their folder",
|
|
"Tus llaves: carpeta seleccionada": "Your keys: folder selected",
|
|
"Cancelar": "Cancel",
|
|
"Mostrar IPA": "Show IPA",
|
|
"Primera instalación: instala la IPA ligera y copia romfs por Finder. Para actualizar, conserva la misma cuenta y bundle ID; no desinstales la app.": "First install: install the lightweight IPA, then copy romfs using Finder. For updates, keep the same account and bundle ID; do not uninstall the game.",
|
|
"Copiar diagnóstico": "Copy diagnostics",
|
|
"Idioma de la interfaz": "Interface language",
|
|
]
|
|
static func text(_ source:String, language:EasyLanguage) -> String {
|
|
language == .spanish ? source : (english[source] ?? source)
|
|
}
|
|
}
|