diff --git a/CLAUDE.md b/CLAUDE.md index 50dc9c8a..0a1fb914 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -100,7 +100,7 @@ Two independent layers share one selected language (`AppSettings.get_selected_la 1. **UI chrome** is translated via `src/utils/i18n.py`: `tr("dot.path.key", **kwargs)` reads `languages/{lang}/ui.json`, overlaid on English so missing keys fall back (then to the bare key). A runtime switch re-merges strings, and `MainWindow.retranslate_ui()` (with each tab's own `retranslate_ui`) sets the built widgets' texts again, the texts a refresh or a load writes included, so a switch shows what a restart in that language shows. `tests/test_language_switch_text.py` compares the two text by text, in both views with nothing loaded, and fails on a text there that has no `retranslate_ui` line (#540). Languages whose `ui.json` is a stub (only `_comment`) are hidden from the selector by `get_available_languages()`. 2. **Game strings**: English `base.ini` comes from local P4K extraction; every other language downloads a community `global.ini` per `languages/sources.json` (per-user URL override via the Config tab's *Map Language File* dialog). Caches are per-language: English at `{channel}\cache\base.ini`, others at `{channel}\cache\lang\{language}\base.ini` (`get_base_ini_path(language)`). The `global` merge source follows the selected language by one rule, `AppSettings.get_global_source_base_ini()` (the language's own base.ini when this channel has it, otherwise the English one), at startup, after a channel switch or a data-folder change and after a successful global.ini extraction (#502). The Blueprint Tracker's Owned set holds display names, so each load renames an owned name saved in another language to the loaded one through its loc key, read from one cached base.ini per other language (whichever channel has it), and a scan and Import Owned Blueprints do the same with their names (#569, see `src/gui/CLAUDE.md`). -Enhancements are language-aware: generated INIs live next to that language's `base.ini` (`get_enhancements_dir()`), and a `.dataforge_stamp` marker per language triggers regeneration on switch when stale (English included). A generation empties that stamp just before the generator's `main()` runs (a failure before that keeps the old one) and writes it when `main()` returns, so the startup check also offers to regenerate a set whose last run was cut off or failed. Generator annotation paths always parse the *English* base.ini, so stat blocks stay English by design; mixed values (e.g. `Role: Cannoniere`) are intentional. The apply side is language-aware too: `get_global_ini_path()` writes `Localization\{sc_id}\global.ini` and `ensure_user_cfg_language()` sets `g_language` to match, both via `SC_LANGUAGE_IDS` (app folder name `portuguese_br` → game id `portuguese_(brazil)`). Turkish borrows `polish_(poland)` and Russian borrows `korean_(south_korea)`, because the game accepts neither language's own id; Russian and Korean sharing one slot is the one deliberate exception to "a borrowed slot is never shared" (the Korean font is the only in-game font with Cyrillic), so applying either replaces the other's `global.ini`. +Enhancements are language-aware: generated INIs live next to that language's `base.ini` (`get_enhancements_dir()`), and a `.dataforge_stamp` marker per language triggers regeneration on switch when stale (English included). A generation empties that stamp just before the generator's `main()` runs (a failure before that keeps the old one) and writes it when `main()` returns, so the startup check also offers to regenerate a set whose last run was cut off or failed. Generator annotation paths always parse the *English* base.ini (tags and lookups stay English), while the text the generator adds itself (stat labels, mission details, journal lines) is translated through `languages/{lang}/enhancements.json` (#579, see `src/utils/CLAUDE.md` → `enhancement_text.py`); the mission section headers, the Rep label, tags such as `[BP]` and item names stay as they are. A translated language's `.dataforge_stamp` carries its table's fingerprint (`AppSettings.enhancements_stamp_value`), so an update that changes the table makes the set out of date. Each start also fetches the selected language's community global.ini again when its source is a URL (`MainWindow._check_language_translation_at_startup`, a conditional request) and, when a new file came down, empties that language's stamp and reloads as a language switch does, so a translation fixed after a game patch arrives without a switch. The apply side is language-aware too: `get_global_ini_path()` writes `Localization\{sc_id}\global.ini` and `ensure_user_cfg_language()` sets `g_language` to match, both via `SC_LANGUAGE_IDS` (app folder name `portuguese_br` → game id `portuguese_(brazil)`). Turkish borrows `polish_(poland)` and Russian borrows `korean_(south_korea)`, because the game accepts neither language's own id; Russian and Korean sharing one slot is the one deliberate exception to "a borrowed slot is never shared" (the Korean font is the only in-game font with Cyrillic), so applying either replaces the other's `global.ini`. `languages/` must be bundled in **both** build lists (`SmartCitizen.spec` and `scripts/build/build_exe.py`), or the frozen app shows raw `tr()` keys. @@ -213,7 +213,8 @@ Anchor examples already in-tree: `COL_*` constants in `src/gui/string_table_mode | Move the DataForge cache off the default path | `src/utils/settings.py`, `src/gui/config_tab.py` | `AppSettings.get_cache_dir_override()` / `set_cache_dir()` (1.4.1+; independent of the user-data override); `ConfigTab._maybe_apply_cache_change()` (undoes a change whose cache folder cannot be made, as Cancel does, and `_report_cache_folder_error()` says why in one box, #494) | | Add or fix a translated UI string | `languages/{language}/ui.json`, `src/utils/i18n.py` | `tr()`, `set_language()` (dot-path keys; English is the fallback base) | | Change the language-switch flow | `src/gui/config_tab.py`, `src/gui/main_window.py` | `language_changed` signal, `MainWindow._on_language_changed()` (retranslate chrome, repoint the `global` source, download base.ini when a URL is mapped, regen stale enhancements, reload) | -| Change per-language base.ini download / URL mapping | `src/gui/workers.py`, `src/utils/settings.py`, `languages/sources.json` | `LanguageBaseDownloadWorker`, `get_language_base_url()`, `LanguageSourceDialog` (Config tab's *Map Language File*) | +| Translate the text the generator adds (stat labels, mission details, journal lines) | `scripts/generate_enhancements_ini.py`, `src/utils/enhancement_text.py`, `languages/{language}/enhancements.json` | `_t()` (keyed by the English text), `load_table()`, `table_fingerprint()`; after adding a `_t()` text run `python tests/test_enhancement_text.py --write` and add it to every language's table (#579) | +| Change per-language base.ini download / URL mapping | `src/gui/workers.py`, `src/utils/settings.py`, `languages/sources.json` | `LanguageBaseDownloadWorker`, `get_language_base_url()`, `LanguageSourceDialog` (Config tab's *Map Language File*), `MainWindow._check_language_translation_at_startup()` / `_on_language_translation_checked()` (the start-time re-download, #579) | | Change per-language cache or enhancements layout | `src/utils/settings.py` | `get_base_ini_path(language)` (and `get_base_ini_leaf(language, channel)`, the same file for any channel with no folder made, #564), `get_enhancements_dir(language)`, `get_/set_enhancements_stamp()` (the setters' `folder=` takes the folder a generation started with), `invalidate_enhancements_stamp()` | | Toggle mission-detail fields per user | `src/gui/enhancements_tab.py`, `src/utils/settings.py` | `_MISSION_FIELD_SETTING` (per-field show/hide for mission bodies, #121); the `route` key adds the haul route to titles (#166) | | Change hauling/delivery route-in-title | `scripts/generate_enhancements_ini.py` | `_derive_route_fragment()` / `_route_token_role()` / `_title_route_token()` / `_expand_nested_route_vars()` (#166, reworked in #200: |Address default, comma-listed endpoints, one-level `*Token` expansion, per-body intersection; applied in both the contractgen title loop and the pu-only second pass; placed before the [BP]/XP tags via the mission_titles TagConfig) | diff --git a/docs/HELP.md b/docs/HELP.md index 110e37c1..8dd58cbd 100644 --- a/docs/HELP.md +++ b/docs/HELP.md @@ -116,7 +116,8 @@ Pick a language from the **Language** dropdown in the **Config** tab (next to Ch - **English** (the default) uses the stock strings extracted from your own `Data.p4k`. - **Other languages** download that language's community-translated `global.ini` and layer it over the English base, so any string the translation doesn't cover falls back to English instead of going missing. The download is cached per language; switching back later reuses the cache. -- **Enhancements stay in English.** Stat blocks, tags, and mission details are generated from game data and keep their English form on top of the translated prose. A mixed line (say, a French role name inside an English stat block) is expected, not a bug. +- **Enhancements follow your language.** The stat labels, mission details and journal lines Smart Citizen adds are written in the language you picked. Item names come from the translation itself, and tags such as `[BP]` and the mission section headers stay as they are. +- **The translation stays up to date.** Each time Smart Citizen starts, it checks for a newer version of the community translation and reloads with it, so a fix made after a game patch reaches you without switching language. - **Map Language File** (Config tab) lets you point a language at a different `global.ini` — a URL (for example your own fork of a community translation) or, via **Browse...**, a file you already have on disk. A URL is downloaded and cached; a local file is copied in. Either way it wins over the bundled default. For a language whose community translation can't be redistributed (e.g. Korean), local-file mapping is the only option — install that community's own patch first, **copy its `global.ini` somewhere other than your Star Citizen install** (mapping the copy Smart Citizen already applies there would feed its own merged output back in as the next "source" and double every enhancement), then Browse to that copy. - **Russian and Korean share one game language slot.** The game has no Russian slot, and its Korean font is the only one that draws Cyrillic, so Russian is applied as the game's Korean language. Applying one replaces the other's file in the game, and only the one you applied last shows in-game. - Some interface text updates only after an app restart. The table strings reload immediately. diff --git a/languages/TRANSLATIONS.md b/languages/TRANSLATIONS.md index b46f6d20..c80a40cd 100644 --- a/languages/TRANSLATIONS.md +++ b/languages/TRANSLATIONS.md @@ -1135,3 +1135,7 @@ them against the new source. one overwrites the other's `global.ini` in that folder. A Russian-speaking reviewer replacing the `at` strings with `ht` is the next step to promote it from AI-only to human-reviewed. + +## Generated text (`enhancements.json`, #579) + +The text Smart Citizen adds to the game strings (stat labels such as `Max HP`, mission details, journal lines) is translated in `languages//enhancements.json`, beside `ui.json`. Its keys are the English texts, listed in `languages/english/enhancements.json`, and each leaf has the same `ht` / `at` fields with the same rules: `ht` wins, then `at`, and an empty leaf stays English. Keep every `{placeholder}` and ``-style tag. Every non-English table was first written as AI drafts (`at`, with `ht` empty), so all of it is open for review. Item names, tags such as `[BP]`, the mission section headers and the Rep label are not in this file: names come from the community translation, and the headers and the label are settings on the Enhancements tab. diff --git a/languages/chinese/HELP.md b/languages/chinese/HELP.md index 4625f295..71861582 100644 --- a/languages/chinese/HELP.md +++ b/languages/chinese/HELP.md @@ -116,7 +116,8 @@ - **英语**(默认)使用从你自己的 `Data.p4k` 中提取的官方字符串。 - **其他语言** 会下载该语言社区翻译的 `global.ini`,并将其叠加在英文基础内容之上,因此任何翻译未覆盖的字符串会回退到英文而不是缺失。下载内容按语言缓存;之后切换回来会复用缓存。 -- **增强内容始终保持英文。** 数据统计块、标签和任务详情是根据游戏数据生成的,会在翻译后的文本之上保留其英文形式。混合行(例如英文数据统计块中出现的法语阵营名称)是预期行为,而非 Bug。 +- **增强内容跟随你的语言。** Smart Citizen 添加的属性标签、任务详情和日志条目会以你选择的语言显示。物品名称来自翻译本身,`[BP]` 等标签和任务的章节标题保持不变。 +- **翻译会保持最新。** 每次启动时,Smart Citizen 都会检查社区翻译是否有更新版本,如有则用它重新加载。因此游戏补丁后的修正无需切换语言即可送达。 - **映射语言文件**(配置标签页)可让你将某种语言指向另一个 `global.ini`:可以是一个地址(例如你自己分支的社区翻译),也可以通过 **浏览…** 选择磁盘上已有的文件。地址会被下载并缓存,本地文件会被复制进来。无论哪种方式,都优先于内置默认值。对于社区翻译不能再分发的语言(例如韩语),映射本地文件是唯一的选择:先安装该社区自己的补丁,**把它的 `global.ini` 复制到《星际公民》安装目录之外的位置**(如果映射 Smart Citizen 已在那里应用的副本,会把它自己合并后的输出当作下一个“来源”再读进来,使每项增强内容翻倍),然后用浏览选择该副本。 - **俄语和韩语共用游戏的同一个语言槽位。** 游戏没有俄语槽位,而只有韩语字体能显示西里尔字母,因此俄语会作为游戏的韩语来应用。应用其中一种会替换游戏中另一种的文件,游戏内只显示最后应用的那一种。 - 部分界面文本仅在应用重启后才会更新。表格字符串会立即重新加载。 diff --git a/languages/chinese/enhancements.json b/languages/chinese/enhancements.json new file mode 100644 index 00000000..6ec548d7 --- /dev/null +++ b/languages/chinese/enhancements.json @@ -0,0 +1,833 @@ +{ + "_comment": "Translations of the text Smart Citizen adds to the game strings (stat labels, mission details, journal lines). Each key is the English text from languages/english/enhancements.json. 'ht' is a human translation and wins; 'at' is an AI draft. Keep each {placeholder} as it is.", + "strings": { + "--- EFFECT ---": { + "ht": "", + "at": "--- 效果 ---" + }, + "--- STATS ---": { + "ht": "", + "at": "--- 属性 ---" + }, + "Absolute Range": { + "ht": "", + "at": "绝对射程" + }, + "Acceleration": { + "ht": "", + "at": "加速度" + }, + "Ace Pilot": { + "ht": "", + "at": "王牌飞行员" + }, + "Ace Pilots": { + "ht": "", + "at": "王牌飞行员" + }, + "Aim Assist Range": { + "ht": "", + "at": "辅助瞄准范围" + }, + "Alpha Dmg": { + "ht": "", + "at": "单发伤害" + }, + "Ammo": { + "ht": "", + "at": "弹药" + }, + "Arm Dist": { + "ht": "", + "at": "解保距离" + }, + "Arm Time": { + "ht": "", + "at": "解保时间" + }, + "Armor HP": { + "ht": "", + "at": "装甲耐久" + }, + "Armour": { + "ht": "", + "at": "护甲" + }, + "Attackers": { + "ht": "", + "at": "进攻者" + }, + "Auto": { + "ht": "", + "at": "全自动" + }, + "Backup": { + "ht": "", + "at": "增援" + }, + "Bandits": { + "ht": "", + "at": "强盗" + }, + "Base Resource Signature": { + "ht": "", + "at": "基础资源信号" + }, + "Beam": { + "ht": "", + "at": "光束" + }, + "Bio": { + "ht": "", + "at": "生化" + }, + "Blast Radius": { + "ht": "", + "at": "爆炸半径" + }, + "Blueprint Reward": { + "ht": "", + "at": "蓝图奖励" + }, + "Bomb Slots": { + "ht": "", + "at": "炸弹挂点" + }, + "Boost": { + "ht": "", + "at": "加力" + }, + "Boss": { + "ht": "", + "at": "首领" + }, + "Burst": { + "ht": "", + "at": "点射" + }, + "CQC": { + "ht": "", + "at": "近战" + }, + "Cal Rate": { + "ht": "", + "at": "校准速率" + }, + "Captain": { + "ht": "", + "at": "舰长" + }, + "Chain": { + "ht": "", + "at": "连续" + }, + "Charge": { + "ht": "", + "at": "蓄力" + }, + "Civilians": { + "ht": "", + "at": "平民" + }, + "Class": { + "ht": "", + "at": "类别" + }, + "Combat": { + "ht": "", + "at": "战斗" + }, + "Complexity": { + "ht": "", + "at": "复杂度" + }, + "Component HP": { + "ht": "", + "at": "组件耐久" + }, + "Cooldown": { + "ht": "", + "at": "冷却" + }, + "Coolers": { + "ht": "", + "at": "冷却器" + }, + "Cooling Rate": { + "ht": "", + "at": "冷却速率" + }, + "Cost/Shot": { + "ht": "", + "at": "每发消耗" + }, + "Crew": { + "ht": "", + "at": "乘员" + }, + "DPS": { + "ht": "", + "at": "DPS" + }, + "Damage": { + "ht": "", + "at": "伤害" + }, + "Damage-Map Rate": { + "ht": "", + "at": "损伤修复速率" + }, + "Damaged Delay": { + "ht": "", + "at": "受损延迟" + }, + "Defenders": { + "ht": "", + "at": "防守者" + }, + "Deflect": { + "ht": "", + "at": "偏转" + }, + "Detection Mode": { + "ht": "", + "at": "探测模式" + }, + "Detonation": { + "ht": "", + "at": "引爆" + }, + "Difficulty (1-7)": { + "ht": "", + "at": "难度 (1-7)" + }, + "Distort": { + "ht": "", + "at": "扭曲" + }, + "Dmg Mult": { + "ht": "", + "at": "伤害倍率" + }, + "Downed Delay": { + "ht": "", + "at": "宕机延迟" + }, + "Drop": { + "ht": "", + "at": "衰减" + }, + "EM": { + "ht": "", + "at": "EM" + }, + "EM Signature": { + "ht": "", + "at": "EM 信号" + }, + "Effective Range": { + "ht": "", + "at": "有效射程" + }, + "Energy": { + "ht": "", + "at": "能量" + }, + "Engagement Type": { + "ht": "", + "at": "交战类型" + }, + "Escort Wings": { + "ht": "", + "at": "护航编队" + }, + "Escorts": { + "ht": "", + "at": "护航" + }, + "Extraction": { + "ht": "", + "at": "抽取" + }, + "FPS": { + "ht": "", + "at": "FPS" + }, + "FPS & Ship": { + "ht": "", + "at": "FPS 与舰船" + }, + "Failure": { + "ht": "", + "at": "失败" + }, + "Failure Penalty": { + "ht": "", + "at": "失败惩罚" + }, + "Fire Modes": { + "ht": "", + "at": "射击模式" + }, + "Fire Rate": { + "ht": "", + "at": "射速" + }, + "Fracture": { + "ht": "", + "at": "破碎" + }, + "Friendlies": { + "ht": "", + "at": "友军" + }, + "Fuel": { + "ht": "", + "at": "燃料" + }, + "Fuel/Gm": { + "ht": "", + "at": "燃料/Gm" + }, + "Full Dmg to": { + "ht": "", + "at": "满伤距离" + }, + "Grade": { + "ht": "", + "at": "等级" + }, + "Grunts": { + "ht": "", + "at": "喽啰" + }, + "Guaranteed": { + "ht": "", + "at": "必定获得" + }, + "Guards": { + "ht": "", + "at": "守卫" + }, + "Guidance": { + "ht": "", + "at": "制导" + }, + "Guns": { + "ht": "", + "at": "机炮" + }, + "HP Rate": { + "ht": "", + "at": "耐久速率" + }, + "HP/Ammo": { + "ht": "", + "at": "耐久/弹药" + }, + "Heat": { + "ht": "", + "at": "热量" + }, + "Heist Target": { + "ht": "", + "at": "劫掠目标" + }, + "Hostages": { + "ht": "", + "at": "人质" + }, + "Hostile Allies": { + "ht": "", + "at": "敌方援军" + }, + "Hostile Wave": { + "ht": "", + "at": "敌方波次" + }, + "Hostiles": { + "ht": "", + "at": "敌人" + }, + "IR": { + "ht": "", + "at": "IR" + }, + "IR Signature": { + "ht": "", + "at": "IR 信号" + }, + "Inert Filter": { + "ht": "", + "at": "惰性过滤" + }, + "Insurance": { + "ht": "", + "at": "保险" + }, + "Interdiction Ships": { + "ht": "", + "at": "拦截舰" + }, + "Item Type": { + "ht": "", + "at": "物品类型" + }, + "Juggernauts": { + "ht": "", + "at": "重装兵" + }, + "Jump Drives": { + "ht": "", + "at": "跳跃引擎" + }, + "Knowledge": { + "ht": "", + "at": "知识" + }, + "Kopions": { + "ht": "", + "at": "科皮恩" + }, + "Length": { + "ht": "", + "at": "长度" + }, + "Lifetime": { + "ht": "", + "at": "存在时间" + }, + "Locations": { + "ht": "", + "at": "地点" + }, + "Lock Range": { + "ht": "", + "at": "锁定范围" + }, + "Lock Time": { + "ht": "", + "at": "锁定时间" + }, + "MRacks": { + "ht": "", + "at": "导弹架" + }, + "Material Efficiency": { + "ht": "", + "at": "材料效率" + }, + "Maulers": { + "ht": "", + "at": "Maulers" + }, + "Max": { + "ht": "", + "at": "最大" + }, + "Max Distortion": { + "ht": "", + "at": "最大扭曲" + }, + "Max G-Force": { + "ht": "", + "at": "最大过载" + }, + "Max HP": { + "ht": "", + "at": "最大耐久" + }, + "Max Lifetime": { + "ht": "", + "at": "最大寿命" + }, + "Max Lock Range": { + "ht": "", + "at": "最大锁定距离" + }, + "Min Detonate": { + "ht": "", + "at": "最小引爆距离" + }, + "Min Dmg": { + "ht": "", + "at": "最小伤害" + }, + "Min Lock Range": { + "ht": "", + "at": "最小锁定距离" + }, + "Mission Type": { + "ht": "", + "at": "任务类型" + }, + "Nine Tails": { + "ht": "", + "at": "Nine Tails" + }, + "Objectives": { + "ht": "", + "at": "目标" + }, + "Overheat Temp": { + "ht": "", + "at": "过热温度" + }, + "Phys": { + "ht": "", + "at": "物理" + }, + "Ping Cooldown": { + "ht": "", + "at": "探测冷却" + }, + "Pirates": { + "ht": "", + "at": "海盗" + }, + "Pitch": { + "ht": "", + "at": "俯仰" + }, + "Polaris": { + "ht": "", + "at": "Polaris" + }, + "Power": { + "ht": "", + "at": "电源" + }, + "Power Draw": { + "ht": "", + "at": "耗电" + }, + "Power Output": { + "ht": "", + "at": "发电量" + }, + "Power Plants": { + "ht": "", + "at": "发电机" + }, + "Private Security": { + "ht": "", + "at": "私人安保" + }, + "Probe": { + "ht": "", + "at": "探测器" + }, + "Prospectors": { + "ht": "", + "at": "Prospector" + }, + "Protected": { + "ht": "", + "at": "受保护者" + }, + "Proximity Range": { + "ht": "", + "at": "近炸距离" + }, + "QD": { + "ht": "", + "at": "量子" + }, + "QT Fuel Use": { + "ht": "", + "at": "量子油耗" + }, + "QT Speed": { + "ht": "", + "at": "量子速度" + }, + "Quantum Drives": { + "ht": "", + "at": "量子引擎" + }, + "Quantum Enforcement Devices": { + "ht": "", + "at": "量子拦截装置" + }, + "Radars": { + "ht": "", + "at": "雷达" + }, + "Ramp": { + "ht": "", + "at": "爬升" + }, + "Range": { + "ht": "", + "at": "射程" + }, + "Rank": { + "ht": "", + "at": "等级" + }, + "Recharges Oxygen reserves of a suit.": { + "ht": "", + "at": "为宇航服补充氧气储备。" + }, + "Recipient": { + "ht": "", + "at": "收件人" + }, + "Reduces concussion symptoms, normalizes weapon handling and movement speed.": { + "ht": "", + "at": "缓解脑震荡症状,恢复武器操控和移动速度。" + }, + "Reduces injuries from radiation.": { + "ht": "", + "at": "减轻辐射伤害。" + }, + "Reduces pain symptoms, normalizes movement ability.": { + "ht": "", + "at": "缓解疼痛症状,恢复行动能力。" + }, + "Reduces vision and hearing symptoms, normalizes stamina.": { + "ht": "", + "at": "缓解视觉和听觉症状,恢复耐力。" + }, + "Refuel Nozzles": { + "ht": "", + "at": "加油喷嘴" + }, + "Regen": { + "ht": "", + "at": "恢复" + }, + "Reinforcements": { + "ht": "", + "at": "增援" + }, + "Required": { + "ht": "", + "at": "需求" + }, + "Resource Signatures": { + "ht": "", + "at": "资源信号" + }, + "Restores health and stops bleeding. When used on another person recovers from incapacitated state.": { + "ht": "", + "at": "恢复生命并止血。对他人使用时可使其脱离失能状态。" + }, + "Revives an overdosed person (if not incapacitated), doubles decay rate of Blood Drug Level.": { + "ht": "", + "at": "救醒药物过量者(未失能时),使血液药物浓度下降速度加倍。" + }, + "Risk": { + "ht": "", + "at": "风险" + }, + "Role": { + "ht": "", + "at": "定位" + }, + "Roll": { + "ht": "", + "at": "滚转" + }, + "SCM": { + "ht": "", + "at": "SCM" + }, + "Salvageable Ships": { + "ht": "", + "at": "可打捞舰船" + }, + "Scanners": { + "ht": "", + "at": "扫描仪" + }, + "Security Forces": { + "ht": "", + "at": "安保部队" + }, + "Seeker": { + "ht": "", + "at": "导引头" + }, + "Semi-Auto": { + "ht": "", + "at": "半自动" + }, + "Sentries": { + "ht": "", + "at": "哨兵" + }, + "Shields": { + "ht": "", + "at": "护盾" + }, + "Ship": { + "ht": "", + "at": "舰船" + }, + "Ships to Defend": { + "ht": "", + "at": "需保护的舰船" + }, + "Shotgun": { + "ht": "", + "at": "霰弹" + }, + "Size": { + "ht": "", + "at": "尺寸" + }, + "Snipers": { + "ht": "", + "at": "狙击手" + }, + "Soldiers": { + "ht": "", + "at": "士兵" + }, + "Spool": { + "ht": "", + "at": "启动" + }, + "Standard": { + "ht": "", + "at": "标准" + }, + "Starter": { + "ht": "", + "at": "新手" + }, + "Stun": { + "ht": "", + "at": "眩晕" + }, + "Targets": { + "ht": "", + "at": "目标" + }, + "Technicians": { + "ht": "", + "at": "技术员" + }, + "Thermal": { + "ht": "", + "at": "热能" + }, + "Tier": { + "ht": "", + "at": "阶段" + }, + "Tracking": { + "ht": "", + "at": "追踪" + }, + "Tracking Range": { + "ht": "", + "at": "追踪范围" + }, + "Turn Rate": { + "ht": "", + "at": "转向速率" + }, + "Turrets": { + "ht": "", + "at": "炮塔" + }, + "Unique": { + "ht": "", + "at": "一次性" + }, + "Used To Craft": { + "ht": "", + "at": "可制造" + }, + "Velocity": { + "ht": "", + "at": "速度" + }, + "Wear": { + "ht": "", + "at": "磨损" + }, + "Weight": { + "ht": "", + "at": "重量" + }, + "Xeno Threat": { + "ht": "", + "at": "Xeno Threat" + }, + "Yaw": { + "ht": "", + "at": "偏航" + }, + "Yes": { + "ht": "", + "at": "是" + }, + "base": { + "ht": "", + "at": "基础" + }, + "down": { + "ht": "", + "at": "下降" + }, + "empty": { + "ht": "", + "at": "空" + }, + "express": { + "ht": "", + "at": "加急" + }, + "friendly": { + "ht": "", + "at": "友方" + }, + "hostile": { + "ht": "", + "at": "敌对" + }, + "present": { + "ht": "", + "at": "存在" + }, + "select variants": { + "ht": "", + "at": "部分变体" + }, + "up": { + "ht": "", + "at": "上升" + }, + "{count} items": { + "ht": "", + "at": "{count} 件物品" + }, + "{count} sets": { + "ht": "", + "at": "{count} 套" + }, + "{count} types": { + "ht": "", + "at": "{count} 种" + }, + "{item} Set": { + "ht": "", + "at": "{item} 套装" + }, + "{pct}% chance": { + "ht": "", + "at": "{pct}% 概率" + }, + "{pct}% chance ({variants} only)": { + "ht": "", + "at": "{pct}% 概率(仅 {variants})" + }, + "{type} Ammo": { + "ht": "", + "at": "{type} 弹药" + } + } +} diff --git a/languages/chinese/ui.json b/languages/chinese/ui.json index 8a537646..6285b676 100644 --- a/languages/chinese/ui.json +++ b/languages/chinese/ui.json @@ -2286,6 +2286,10 @@ "ht": "", "at": "无法从所设置的来源加载 {language} 本地化内容,也未找到缓存副本。改为显示英文基础内容。请检查“映射语言文件”中的地址或文件,然后重试。" }, + "language_updated_status": { + "ht": "", + "at": "已下载更新的 {language} 翻译,正在重新加载。" + }, "language_generating_enhancements": { "ht": "", "at": "正在从 DataForge 生成 {language} 增强内容…" diff --git a/languages/chinese_traditional/HELP.md b/languages/chinese_traditional/HELP.md index b838a82e..53f4d6d0 100644 --- a/languages/chinese_traditional/HELP.md +++ b/languages/chinese_traditional/HELP.md @@ -116,7 +116,8 @@ - **英語**(預設)使用從你自己的 `Data.p4k` 中提取的官方字串。 - **其他語言** 會下載該語言社群翻譯的 `global.ini`,並將其疊加在英文基礎內容之上,因此任何翻譯未覆蓋的字串會回退到英文而不是缺失。下載內容按語言快取;之後切換回來會複用快取。 -- **增強內容始終保持英文。** 資料統計塊、標籤和任務詳情是根據遊戲資料生成的,會在翻譯後的文字之上保留其英文形式。混合行(例如英文資料統計塊中出現的法語陣營名稱)是預期行為,而非 Bug。 +- **增強內容跟隨你的語言。** Smart Citizen 加入的屬性標籤、任務詳情和日誌條目會以你選擇的語言顯示。物品名稱來自翻譯本身,`[BP]` 等標籤和任務的章節標題保持不變。 +- **翻譯會保持最新。** 每次啟動時,Smart Citizen 都會檢查社群翻譯是否有更新版本,如有則用它重新載入。因此遊戲修補後的修正無需切換語言即可送達。 - **對映語言檔案**(配置標籤頁)可讓你將某種語言指向另一個 `global.ini`:可以是一個地址(例如你自己分支的社群翻譯),也可以透過 **瀏覽…** 選擇磁碟上已有的檔案。地址會被下載並快取,本機檔案會被複製進來。無論哪種方式,都優先於內建預設值。對於社群翻譯不能再散布的語言(例如韓語),對映本機檔案是唯一的選擇:先安裝該社群自己的修補程式,**把它的 `global.ini` 複製到《星際公民》安裝目錄之外的位置**(如果對映 Smart Citizen 已在那裡套用的副本,會把它自己合併後的輸出當作下一個“來源”再讀進來,使每項增強內容翻倍),然後用瀏覽選擇該副本。 - **俄語和韓語共用遊戲的同一個語言欄位。** 遊戲沒有俄語欄位,而只有韓語字型能顯示西里爾字母,因此俄語會作為遊戲的韓語來套用。套用其中一種會取代遊戲中另一種的檔案,遊戲內只顯示最後套用的那一種。 - 部分介面文字僅在應用重啟後才會更新。表格字串會立即重新載入。 diff --git a/languages/chinese_traditional/enhancements.json b/languages/chinese_traditional/enhancements.json new file mode 100644 index 00000000..f631ede6 --- /dev/null +++ b/languages/chinese_traditional/enhancements.json @@ -0,0 +1,833 @@ +{ + "_comment": "Translations of the text Smart Citizen adds to the game strings (stat labels, mission details, journal lines). Each key is the English text from languages/english/enhancements.json. 'ht' is a human translation and wins; 'at' is an AI draft. Keep each {placeholder} as it is.", + "strings": { + "--- EFFECT ---": { + "ht": "", + "at": "--- 效果 ---" + }, + "--- STATS ---": { + "ht": "", + "at": "--- 屬性 ---" + }, + "Absolute Range": { + "ht": "", + "at": "絕對射程" + }, + "Acceleration": { + "ht": "", + "at": "加速度" + }, + "Ace Pilot": { + "ht": "", + "at": "王牌飛行員" + }, + "Ace Pilots": { + "ht": "", + "at": "王牌飛行員" + }, + "Aim Assist Range": { + "ht": "", + "at": "輔助瞄準範圍" + }, + "Alpha Dmg": { + "ht": "", + "at": "單發傷害" + }, + "Ammo": { + "ht": "", + "at": "彈藥" + }, + "Arm Dist": { + "ht": "", + "at": "解保距離" + }, + "Arm Time": { + "ht": "", + "at": "解保時間" + }, + "Armor HP": { + "ht": "", + "at": "裝甲耐久" + }, + "Armour": { + "ht": "", + "at": "護甲" + }, + "Attackers": { + "ht": "", + "at": "進攻者" + }, + "Auto": { + "ht": "", + "at": "全自動" + }, + "Backup": { + "ht": "", + "at": "增援" + }, + "Bandits": { + "ht": "", + "at": "強盜" + }, + "Base Resource Signature": { + "ht": "", + "at": "基礎資源訊號" + }, + "Beam": { + "ht": "", + "at": "光束" + }, + "Bio": { + "ht": "", + "at": "生化" + }, + "Blast Radius": { + "ht": "", + "at": "爆炸半徑" + }, + "Blueprint Reward": { + "ht": "", + "at": "藍圖獎勵" + }, + "Bomb Slots": { + "ht": "", + "at": "炸彈掛點" + }, + "Boost": { + "ht": "", + "at": "加力" + }, + "Boss": { + "ht": "", + "at": "首領" + }, + "Burst": { + "ht": "", + "at": "點放" + }, + "CQC": { + "ht": "", + "at": "近戰" + }, + "Cal Rate": { + "ht": "", + "at": "校準速率" + }, + "Captain": { + "ht": "", + "at": "艦長" + }, + "Chain": { + "ht": "", + "at": "連續" + }, + "Charge": { + "ht": "", + "at": "蓄力" + }, + "Civilians": { + "ht": "", + "at": "平民" + }, + "Class": { + "ht": "", + "at": "類別" + }, + "Combat": { + "ht": "", + "at": "戰鬥" + }, + "Complexity": { + "ht": "", + "at": "複雜度" + }, + "Component HP": { + "ht": "", + "at": "組件耐久" + }, + "Cooldown": { + "ht": "", + "at": "冷卻" + }, + "Coolers": { + "ht": "", + "at": "冷卻器" + }, + "Cooling Rate": { + "ht": "", + "at": "冷卻速率" + }, + "Cost/Shot": { + "ht": "", + "at": "每發消耗" + }, + "Crew": { + "ht": "", + "at": "乘員" + }, + "DPS": { + "ht": "", + "at": "DPS" + }, + "Damage": { + "ht": "", + "at": "傷害" + }, + "Damage-Map Rate": { + "ht": "", + "at": "損傷修復速率" + }, + "Damaged Delay": { + "ht": "", + "at": "受損延遲" + }, + "Defenders": { + "ht": "", + "at": "防守者" + }, + "Deflect": { + "ht": "", + "at": "偏轉" + }, + "Detection Mode": { + "ht": "", + "at": "偵測模式" + }, + "Detonation": { + "ht": "", + "at": "引爆" + }, + "Difficulty (1-7)": { + "ht": "", + "at": "難度 (1-7)" + }, + "Distort": { + "ht": "", + "at": "扭曲" + }, + "Dmg Mult": { + "ht": "", + "at": "傷害倍率" + }, + "Downed Delay": { + "ht": "", + "at": "停機延遲" + }, + "Drop": { + "ht": "", + "at": "衰減" + }, + "EM": { + "ht": "", + "at": "EM" + }, + "EM Signature": { + "ht": "", + "at": "EM 訊號" + }, + "Effective Range": { + "ht": "", + "at": "有效射程" + }, + "Energy": { + "ht": "", + "at": "能量" + }, + "Engagement Type": { + "ht": "", + "at": "交戰類型" + }, + "Escort Wings": { + "ht": "", + "at": "護航編隊" + }, + "Escorts": { + "ht": "", + "at": "護航" + }, + "Extraction": { + "ht": "", + "at": "抽取" + }, + "FPS": { + "ht": "", + "at": "FPS" + }, + "FPS & Ship": { + "ht": "", + "at": "FPS 與艦船" + }, + "Failure": { + "ht": "", + "at": "失敗" + }, + "Failure Penalty": { + "ht": "", + "at": "失敗懲罰" + }, + "Fire Modes": { + "ht": "", + "at": "射擊模式" + }, + "Fire Rate": { + "ht": "", + "at": "射速" + }, + "Fracture": { + "ht": "", + "at": "破碎" + }, + "Friendlies": { + "ht": "", + "at": "友軍" + }, + "Fuel": { + "ht": "", + "at": "燃料" + }, + "Fuel/Gm": { + "ht": "", + "at": "燃料/Gm" + }, + "Full Dmg to": { + "ht": "", + "at": "滿傷距離" + }, + "Grade": { + "ht": "", + "at": "等級" + }, + "Grunts": { + "ht": "", + "at": "嘍囉" + }, + "Guaranteed": { + "ht": "", + "at": "必定獲得" + }, + "Guards": { + "ht": "", + "at": "守衛" + }, + "Guidance": { + "ht": "", + "at": "導引" + }, + "Guns": { + "ht": "", + "at": "機砲" + }, + "HP Rate": { + "ht": "", + "at": "耐久速率" + }, + "HP/Ammo": { + "ht": "", + "at": "耐久/彈藥" + }, + "Heat": { + "ht": "", + "at": "熱量" + }, + "Heist Target": { + "ht": "", + "at": "劫掠目標" + }, + "Hostages": { + "ht": "", + "at": "人質" + }, + "Hostile Allies": { + "ht": "", + "at": "敵方援軍" + }, + "Hostile Wave": { + "ht": "", + "at": "敵方波次" + }, + "Hostiles": { + "ht": "", + "at": "敵人" + }, + "IR": { + "ht": "", + "at": "IR" + }, + "IR Signature": { + "ht": "", + "at": "IR 訊號" + }, + "Inert Filter": { + "ht": "", + "at": "惰性過濾" + }, + "Insurance": { + "ht": "", + "at": "保險" + }, + "Interdiction Ships": { + "ht": "", + "at": "攔截艦" + }, + "Item Type": { + "ht": "", + "at": "物品類型" + }, + "Juggernauts": { + "ht": "", + "at": "重裝兵" + }, + "Jump Drives": { + "ht": "", + "at": "跳躍引擎" + }, + "Knowledge": { + "ht": "", + "at": "知識" + }, + "Kopions": { + "ht": "", + "at": "科皮恩" + }, + "Length": { + "ht": "", + "at": "長度" + }, + "Lifetime": { + "ht": "", + "at": "存在時間" + }, + "Locations": { + "ht": "", + "at": "地點" + }, + "Lock Range": { + "ht": "", + "at": "鎖定範圍" + }, + "Lock Time": { + "ht": "", + "at": "鎖定時間" + }, + "MRacks": { + "ht": "", + "at": "飛彈架" + }, + "Material Efficiency": { + "ht": "", + "at": "材料效率" + }, + "Maulers": { + "ht": "", + "at": "Maulers" + }, + "Max": { + "ht": "", + "at": "最大" + }, + "Max Distortion": { + "ht": "", + "at": "最大扭曲" + }, + "Max G-Force": { + "ht": "", + "at": "最大過載" + }, + "Max HP": { + "ht": "", + "at": "最大耐久" + }, + "Max Lifetime": { + "ht": "", + "at": "最大壽命" + }, + "Max Lock Range": { + "ht": "", + "at": "最大鎖定距離" + }, + "Min Detonate": { + "ht": "", + "at": "最小引爆距離" + }, + "Min Dmg": { + "ht": "", + "at": "最小傷害" + }, + "Min Lock Range": { + "ht": "", + "at": "最小鎖定距離" + }, + "Mission Type": { + "ht": "", + "at": "任務類型" + }, + "Nine Tails": { + "ht": "", + "at": "Nine Tails" + }, + "Objectives": { + "ht": "", + "at": "目標" + }, + "Overheat Temp": { + "ht": "", + "at": "過熱溫度" + }, + "Phys": { + "ht": "", + "at": "物理" + }, + "Ping Cooldown": { + "ht": "", + "at": "偵測冷卻" + }, + "Pirates": { + "ht": "", + "at": "海盜" + }, + "Pitch": { + "ht": "", + "at": "俯仰" + }, + "Polaris": { + "ht": "", + "at": "Polaris" + }, + "Power": { + "ht": "", + "at": "電源" + }, + "Power Draw": { + "ht": "", + "at": "耗電" + }, + "Power Output": { + "ht": "", + "at": "發電量" + }, + "Power Plants": { + "ht": "", + "at": "發電機" + }, + "Private Security": { + "ht": "", + "at": "私人保全" + }, + "Probe": { + "ht": "", + "at": "探測器" + }, + "Prospectors": { + "ht": "", + "at": "Prospector" + }, + "Protected": { + "ht": "", + "at": "受保護者" + }, + "Proximity Range": { + "ht": "", + "at": "近炸距離" + }, + "QD": { + "ht": "", + "at": "量子" + }, + "QT Fuel Use": { + "ht": "", + "at": "量子油耗" + }, + "QT Speed": { + "ht": "", + "at": "量子速度" + }, + "Quantum Drives": { + "ht": "", + "at": "量子引擎" + }, + "Quantum Enforcement Devices": { + "ht": "", + "at": "量子攔截裝置" + }, + "Radars": { + "ht": "", + "at": "雷達" + }, + "Ramp": { + "ht": "", + "at": "爬升" + }, + "Range": { + "ht": "", + "at": "射程" + }, + "Rank": { + "ht": "", + "at": "等級" + }, + "Recharges Oxygen reserves of a suit.": { + "ht": "", + "at": "為太空衣補充氧氣儲備。" + }, + "Recipient": { + "ht": "", + "at": "收件人" + }, + "Reduces concussion symptoms, normalizes weapon handling and movement speed.": { + "ht": "", + "at": "緩解腦震盪症狀,恢復武器操控與移動速度。" + }, + "Reduces injuries from radiation.": { + "ht": "", + "at": "減輕輻射傷害。" + }, + "Reduces pain symptoms, normalizes movement ability.": { + "ht": "", + "at": "緩解疼痛症狀,恢復行動能力。" + }, + "Reduces vision and hearing symptoms, normalizes stamina.": { + "ht": "", + "at": "緩解視覺與聽覺症狀,恢復耐力。" + }, + "Refuel Nozzles": { + "ht": "", + "at": "加油噴嘴" + }, + "Regen": { + "ht": "", + "at": "恢復" + }, + "Reinforcements": { + "ht": "", + "at": "增援" + }, + "Required": { + "ht": "", + "at": "需求" + }, + "Resource Signatures": { + "ht": "", + "at": "資源訊號" + }, + "Restores health and stops bleeding. When used on another person recovers from incapacitated state.": { + "ht": "", + "at": "恢復生命並止血。對他人使用時可使其脫離失能狀態。" + }, + "Revives an overdosed person (if not incapacitated), doubles decay rate of Blood Drug Level.": { + "ht": "", + "at": "救醒藥物過量者(未失能時),使血液藥物濃度下降速度加倍。" + }, + "Risk": { + "ht": "", + "at": "風險" + }, + "Role": { + "ht": "", + "at": "定位" + }, + "Roll": { + "ht": "", + "at": "滾轉" + }, + "SCM": { + "ht": "", + "at": "SCM" + }, + "Salvageable Ships": { + "ht": "", + "at": "可打撈艦船" + }, + "Scanners": { + "ht": "", + "at": "掃描器" + }, + "Security Forces": { + "ht": "", + "at": "保安部隊" + }, + "Seeker": { + "ht": "", + "at": "導引頭" + }, + "Semi-Auto": { + "ht": "", + "at": "半自動" + }, + "Sentries": { + "ht": "", + "at": "哨兵" + }, + "Shields": { + "ht": "", + "at": "護盾" + }, + "Ship": { + "ht": "", + "at": "艦船" + }, + "Ships to Defend": { + "ht": "", + "at": "需保護的艦船" + }, + "Shotgun": { + "ht": "", + "at": "霰彈" + }, + "Size": { + "ht": "", + "at": "尺寸" + }, + "Snipers": { + "ht": "", + "at": "狙擊手" + }, + "Soldiers": { + "ht": "", + "at": "士兵" + }, + "Spool": { + "ht": "", + "at": "啟動" + }, + "Standard": { + "ht": "", + "at": "標準" + }, + "Starter": { + "ht": "", + "at": "新手" + }, + "Stun": { + "ht": "", + "at": "暈眩" + }, + "Targets": { + "ht": "", + "at": "目標" + }, + "Technicians": { + "ht": "", + "at": "技術員" + }, + "Thermal": { + "ht": "", + "at": "熱能" + }, + "Tier": { + "ht": "", + "at": "階段" + }, + "Tracking": { + "ht": "", + "at": "追蹤" + }, + "Tracking Range": { + "ht": "", + "at": "追蹤範圍" + }, + "Turn Rate": { + "ht": "", + "at": "轉向速率" + }, + "Turrets": { + "ht": "", + "at": "砲塔" + }, + "Unique": { + "ht": "", + "at": "一次性" + }, + "Used To Craft": { + "ht": "", + "at": "可製造" + }, + "Velocity": { + "ht": "", + "at": "速度" + }, + "Wear": { + "ht": "", + "at": "磨損" + }, + "Weight": { + "ht": "", + "at": "重量" + }, + "Xeno Threat": { + "ht": "", + "at": "Xeno Threat" + }, + "Yaw": { + "ht": "", + "at": "偏航" + }, + "Yes": { + "ht": "", + "at": "是" + }, + "base": { + "ht": "", + "at": "基礎" + }, + "down": { + "ht": "", + "at": "下降" + }, + "empty": { + "ht": "", + "at": "空" + }, + "express": { + "ht": "", + "at": "加急" + }, + "friendly": { + "ht": "", + "at": "友方" + }, + "hostile": { + "ht": "", + "at": "敵對" + }, + "present": { + "ht": "", + "at": "存在" + }, + "select variants": { + "ht": "", + "at": "部分變體" + }, + "up": { + "ht": "", + "at": "上升" + }, + "{count} items": { + "ht": "", + "at": "{count} 件物品" + }, + "{count} sets": { + "ht": "", + "at": "{count} 套" + }, + "{count} types": { + "ht": "", + "at": "{count} 種" + }, + "{item} Set": { + "ht": "", + "at": "{item} 套裝" + }, + "{pct}% chance": { + "ht": "", + "at": "{pct}% 機率" + }, + "{pct}% chance ({variants} only)": { + "ht": "", + "at": "{pct}% 機率(僅 {variants})" + }, + "{type} Ammo": { + "ht": "", + "at": "{type} 彈藥" + } + } +} diff --git a/languages/chinese_traditional/ui.json b/languages/chinese_traditional/ui.json index d8a6afad..b1d2eeee 100644 --- a/languages/chinese_traditional/ui.json +++ b/languages/chinese_traditional/ui.json @@ -2286,6 +2286,10 @@ "ht": "", "at": "無法從所設定的來源載入 {language} 本地化內容,也未找到快取副本。改為顯示英文基礎內容。請檢查“對映語言檔案”中的地址或檔案,然後重試。" }, + "language_updated_status": { + "ht": "", + "at": "已下載更新的 {language} 翻譯,正在重新載入。" + }, "language_generating_enhancements": { "ht": "", "at": "正在從 DataForge 生成 {language} 增強內容…" diff --git a/languages/english/enhancements.json b/languages/english/enhancements.json new file mode 100644 index 00000000..8217ca8e --- /dev/null +++ b/languages/english/enhancements.json @@ -0,0 +1,833 @@ +{ + "_comment": "Every text Smart Citizen adds to the game strings (stat labels, mission details, journal lines), in English. Each language's enhancements.json maps these same English texts to its own words: 'ht' for a human translation, 'at' for an AI draft. Keep each {placeholder} as it is. Generated by tests/test_enhancement_text.py --write; not loaded by the app.", + "strings": { + "--- EFFECT ---": { + "ht": "--- EFFECT ---", + "at": "" + }, + "--- STATS ---": { + "ht": "--- STATS ---", + "at": "" + }, + "Absolute Range": { + "ht": "Absolute Range", + "at": "" + }, + "Acceleration": { + "ht": "Acceleration", + "at": "" + }, + "Ace Pilot": { + "ht": "Ace Pilot", + "at": "" + }, + "Ace Pilots": { + "ht": "Ace Pilots", + "at": "" + }, + "Aim Assist Range": { + "ht": "Aim Assist Range", + "at": "" + }, + "Alpha Dmg": { + "ht": "Alpha Dmg", + "at": "" + }, + "Ammo": { + "ht": "Ammo", + "at": "" + }, + "Arm Dist": { + "ht": "Arm Dist", + "at": "" + }, + "Arm Time": { + "ht": "Arm Time", + "at": "" + }, + "Armor HP": { + "ht": "Armor HP", + "at": "" + }, + "Armour": { + "ht": "Armour", + "at": "" + }, + "Attackers": { + "ht": "Attackers", + "at": "" + }, + "Auto": { + "ht": "Auto", + "at": "" + }, + "Backup": { + "ht": "Backup", + "at": "" + }, + "Bandits": { + "ht": "Bandits", + "at": "" + }, + "Base Resource Signature": { + "ht": "Base Resource Signature", + "at": "" + }, + "Beam": { + "ht": "Beam", + "at": "" + }, + "Bio": { + "ht": "Bio", + "at": "" + }, + "Blast Radius": { + "ht": "Blast Radius", + "at": "" + }, + "Blueprint Reward": { + "ht": "Blueprint Reward", + "at": "" + }, + "Bomb Slots": { + "ht": "Bomb Slots", + "at": "" + }, + "Boost": { + "ht": "Boost", + "at": "" + }, + "Boss": { + "ht": "Boss", + "at": "" + }, + "Burst": { + "ht": "Burst", + "at": "" + }, + "CQC": { + "ht": "CQC", + "at": "" + }, + "Cal Rate": { + "ht": "Cal Rate", + "at": "" + }, + "Captain": { + "ht": "Captain", + "at": "" + }, + "Chain": { + "ht": "Chain", + "at": "" + }, + "Charge": { + "ht": "Charge", + "at": "" + }, + "Civilians": { + "ht": "Civilians", + "at": "" + }, + "Class": { + "ht": "Class", + "at": "" + }, + "Combat": { + "ht": "Combat", + "at": "" + }, + "Complexity": { + "ht": "Complexity", + "at": "" + }, + "Component HP": { + "ht": "Component HP", + "at": "" + }, + "Cooldown": { + "ht": "Cooldown", + "at": "" + }, + "Coolers": { + "ht": "Coolers", + "at": "" + }, + "Cooling Rate": { + "ht": "Cooling Rate", + "at": "" + }, + "Cost/Shot": { + "ht": "Cost/Shot", + "at": "" + }, + "Crew": { + "ht": "Crew", + "at": "" + }, + "DPS": { + "ht": "DPS", + "at": "" + }, + "Damage": { + "ht": "Damage", + "at": "" + }, + "Damage-Map Rate": { + "ht": "Damage-Map Rate", + "at": "" + }, + "Damaged Delay": { + "ht": "Damaged Delay", + "at": "" + }, + "Defenders": { + "ht": "Defenders", + "at": "" + }, + "Deflect": { + "ht": "Deflect", + "at": "" + }, + "Detection Mode": { + "ht": "Detection Mode", + "at": "" + }, + "Detonation": { + "ht": "Detonation", + "at": "" + }, + "Difficulty (1-7)": { + "ht": "Difficulty (1-7)", + "at": "" + }, + "Distort": { + "ht": "Distort", + "at": "" + }, + "Dmg Mult": { + "ht": "Dmg Mult", + "at": "" + }, + "Downed Delay": { + "ht": "Downed Delay", + "at": "" + }, + "Drop": { + "ht": "Drop", + "at": "" + }, + "EM": { + "ht": "EM", + "at": "" + }, + "EM Signature": { + "ht": "EM Signature", + "at": "" + }, + "Effective Range": { + "ht": "Effective Range", + "at": "" + }, + "Energy": { + "ht": "Energy", + "at": "" + }, + "Engagement Type": { + "ht": "Engagement Type", + "at": "" + }, + "Escort Wings": { + "ht": "Escort Wings", + "at": "" + }, + "Escorts": { + "ht": "Escorts", + "at": "" + }, + "Extraction": { + "ht": "Extraction", + "at": "" + }, + "FPS": { + "ht": "FPS", + "at": "" + }, + "FPS & Ship": { + "ht": "FPS & Ship", + "at": "" + }, + "Failure": { + "ht": "Failure", + "at": "" + }, + "Failure Penalty": { + "ht": "Failure Penalty", + "at": "" + }, + "Fire Modes": { + "ht": "Fire Modes", + "at": "" + }, + "Fire Rate": { + "ht": "Fire Rate", + "at": "" + }, + "Fracture": { + "ht": "Fracture", + "at": "" + }, + "Friendlies": { + "ht": "Friendlies", + "at": "" + }, + "Fuel": { + "ht": "Fuel", + "at": "" + }, + "Fuel/Gm": { + "ht": "Fuel/Gm", + "at": "" + }, + "Full Dmg to": { + "ht": "Full Dmg to", + "at": "" + }, + "Grade": { + "ht": "Grade", + "at": "" + }, + "Grunts": { + "ht": "Grunts", + "at": "" + }, + "Guaranteed": { + "ht": "Guaranteed", + "at": "" + }, + "Guards": { + "ht": "Guards", + "at": "" + }, + "Guidance": { + "ht": "Guidance", + "at": "" + }, + "Guns": { + "ht": "Guns", + "at": "" + }, + "HP Rate": { + "ht": "HP Rate", + "at": "" + }, + "HP/Ammo": { + "ht": "HP/Ammo", + "at": "" + }, + "Heat": { + "ht": "Heat", + "at": "" + }, + "Heist Target": { + "ht": "Heist Target", + "at": "" + }, + "Hostages": { + "ht": "Hostages", + "at": "" + }, + "Hostile Allies": { + "ht": "Hostile Allies", + "at": "" + }, + "Hostile Wave": { + "ht": "Hostile Wave", + "at": "" + }, + "Hostiles": { + "ht": "Hostiles", + "at": "" + }, + "IR": { + "ht": "IR", + "at": "" + }, + "IR Signature": { + "ht": "IR Signature", + "at": "" + }, + "Inert Filter": { + "ht": "Inert Filter", + "at": "" + }, + "Insurance": { + "ht": "Insurance", + "at": "" + }, + "Interdiction Ships": { + "ht": "Interdiction Ships", + "at": "" + }, + "Item Type": { + "ht": "Item Type", + "at": "" + }, + "Juggernauts": { + "ht": "Juggernauts", + "at": "" + }, + "Jump Drives": { + "ht": "Jump Drives", + "at": "" + }, + "Knowledge": { + "ht": "Knowledge", + "at": "" + }, + "Kopions": { + "ht": "Kopions", + "at": "" + }, + "Length": { + "ht": "Length", + "at": "" + }, + "Lifetime": { + "ht": "Lifetime", + "at": "" + }, + "Locations": { + "ht": "Locations", + "at": "" + }, + "Lock Range": { + "ht": "Lock Range", + "at": "" + }, + "Lock Time": { + "ht": "Lock Time", + "at": "" + }, + "MRacks": { + "ht": "MRacks", + "at": "" + }, + "Material Efficiency": { + "ht": "Material Efficiency", + "at": "" + }, + "Maulers": { + "ht": "Maulers", + "at": "" + }, + "Max": { + "ht": "Max", + "at": "" + }, + "Max Distortion": { + "ht": "Max Distortion", + "at": "" + }, + "Max G-Force": { + "ht": "Max G-Force", + "at": "" + }, + "Max HP": { + "ht": "Max HP", + "at": "" + }, + "Max Lifetime": { + "ht": "Max Lifetime", + "at": "" + }, + "Max Lock Range": { + "ht": "Max Lock Range", + "at": "" + }, + "Min Detonate": { + "ht": "Min Detonate", + "at": "" + }, + "Min Dmg": { + "ht": "Min Dmg", + "at": "" + }, + "Min Lock Range": { + "ht": "Min Lock Range", + "at": "" + }, + "Mission Type": { + "ht": "Mission Type", + "at": "" + }, + "Nine Tails": { + "ht": "Nine Tails", + "at": "" + }, + "Objectives": { + "ht": "Objectives", + "at": "" + }, + "Overheat Temp": { + "ht": "Overheat Temp", + "at": "" + }, + "Phys": { + "ht": "Phys", + "at": "" + }, + "Ping Cooldown": { + "ht": "Ping Cooldown", + "at": "" + }, + "Pirates": { + "ht": "Pirates", + "at": "" + }, + "Pitch": { + "ht": "Pitch", + "at": "" + }, + "Polaris": { + "ht": "Polaris", + "at": "" + }, + "Power": { + "ht": "Power", + "at": "" + }, + "Power Draw": { + "ht": "Power Draw", + "at": "" + }, + "Power Output": { + "ht": "Power Output", + "at": "" + }, + "Power Plants": { + "ht": "Power Plants", + "at": "" + }, + "Private Security": { + "ht": "Private Security", + "at": "" + }, + "Probe": { + "ht": "Probe", + "at": "" + }, + "Prospectors": { + "ht": "Prospectors", + "at": "" + }, + "Protected": { + "ht": "Protected", + "at": "" + }, + "Proximity Range": { + "ht": "Proximity Range", + "at": "" + }, + "QD": { + "ht": "QD", + "at": "" + }, + "QT Fuel Use": { + "ht": "QT Fuel Use", + "at": "" + }, + "QT Speed": { + "ht": "QT Speed", + "at": "" + }, + "Quantum Drives": { + "ht": "Quantum Drives", + "at": "" + }, + "Quantum Enforcement Devices": { + "ht": "Quantum Enforcement Devices", + "at": "" + }, + "Radars": { + "ht": "Radars", + "at": "" + }, + "Ramp": { + "ht": "Ramp", + "at": "" + }, + "Range": { + "ht": "Range", + "at": "" + }, + "Rank": { + "ht": "Rank", + "at": "" + }, + "Recharges Oxygen reserves of a suit.": { + "ht": "Recharges Oxygen reserves of a suit.", + "at": "" + }, + "Recipient": { + "ht": "Recipient", + "at": "" + }, + "Reduces concussion symptoms, normalizes weapon handling and movement speed.": { + "ht": "Reduces concussion symptoms, normalizes weapon handling and movement speed.", + "at": "" + }, + "Reduces injuries from radiation.": { + "ht": "Reduces injuries from radiation.", + "at": "" + }, + "Reduces pain symptoms, normalizes movement ability.": { + "ht": "Reduces pain symptoms, normalizes movement ability.", + "at": "" + }, + "Reduces vision and hearing symptoms, normalizes stamina.": { + "ht": "Reduces vision and hearing symptoms, normalizes stamina.", + "at": "" + }, + "Refuel Nozzles": { + "ht": "Refuel Nozzles", + "at": "" + }, + "Regen": { + "ht": "Regen", + "at": "" + }, + "Reinforcements": { + "ht": "Reinforcements", + "at": "" + }, + "Required": { + "ht": "Required", + "at": "" + }, + "Resource Signatures": { + "ht": "Resource Signatures", + "at": "" + }, + "Restores health and stops bleeding. When used on another person recovers from incapacitated state.": { + "ht": "Restores health and stops bleeding. When used on another person recovers from incapacitated state.", + "at": "" + }, + "Revives an overdosed person (if not incapacitated), doubles decay rate of Blood Drug Level.": { + "ht": "Revives an overdosed person (if not incapacitated), doubles decay rate of Blood Drug Level.", + "at": "" + }, + "Risk": { + "ht": "Risk", + "at": "" + }, + "Role": { + "ht": "Role", + "at": "" + }, + "Roll": { + "ht": "Roll", + "at": "" + }, + "SCM": { + "ht": "SCM", + "at": "" + }, + "Salvageable Ships": { + "ht": "Salvageable Ships", + "at": "" + }, + "Scanners": { + "ht": "Scanners", + "at": "" + }, + "Security Forces": { + "ht": "Security Forces", + "at": "" + }, + "Seeker": { + "ht": "Seeker", + "at": "" + }, + "Semi-Auto": { + "ht": "Semi-Auto", + "at": "" + }, + "Sentries": { + "ht": "Sentries", + "at": "" + }, + "Shields": { + "ht": "Shields", + "at": "" + }, + "Ship": { + "ht": "Ship", + "at": "" + }, + "Ships to Defend": { + "ht": "Ships to Defend", + "at": "" + }, + "Shotgun": { + "ht": "Shotgun", + "at": "" + }, + "Size": { + "ht": "Size", + "at": "" + }, + "Snipers": { + "ht": "Snipers", + "at": "" + }, + "Soldiers": { + "ht": "Soldiers", + "at": "" + }, + "Spool": { + "ht": "Spool", + "at": "" + }, + "Standard": { + "ht": "Standard", + "at": "" + }, + "Starter": { + "ht": "Starter", + "at": "" + }, + "Stun": { + "ht": "Stun", + "at": "" + }, + "Targets": { + "ht": "Targets", + "at": "" + }, + "Technicians": { + "ht": "Technicians", + "at": "" + }, + "Thermal": { + "ht": "Thermal", + "at": "" + }, + "Tier": { + "ht": "Tier", + "at": "" + }, + "Tracking": { + "ht": "Tracking", + "at": "" + }, + "Tracking Range": { + "ht": "Tracking Range", + "at": "" + }, + "Turn Rate": { + "ht": "Turn Rate", + "at": "" + }, + "Turrets": { + "ht": "Turrets", + "at": "" + }, + "Unique": { + "ht": "Unique", + "at": "" + }, + "Used To Craft": { + "ht": "Used To Craft", + "at": "" + }, + "Velocity": { + "ht": "Velocity", + "at": "" + }, + "Wear": { + "ht": "Wear", + "at": "" + }, + "Weight": { + "ht": "Weight", + "at": "" + }, + "Xeno Threat": { + "ht": "Xeno Threat", + "at": "" + }, + "Yaw": { + "ht": "Yaw", + "at": "" + }, + "Yes": { + "ht": "Yes", + "at": "" + }, + "base": { + "ht": "base", + "at": "" + }, + "down": { + "ht": "down", + "at": "" + }, + "empty": { + "ht": "empty", + "at": "" + }, + "express": { + "ht": "express", + "at": "" + }, + "friendly": { + "ht": "friendly", + "at": "" + }, + "hostile": { + "ht": "hostile", + "at": "" + }, + "present": { + "ht": "present", + "at": "" + }, + "select variants": { + "ht": "select variants", + "at": "" + }, + "up": { + "ht": "up", + "at": "" + }, + "{count} items": { + "ht": "{count} items", + "at": "" + }, + "{count} sets": { + "ht": "{count} sets", + "at": "" + }, + "{count} types": { + "ht": "{count} types", + "at": "" + }, + "{item} Set": { + "ht": "{item} Set", + "at": "" + }, + "{pct}% chance": { + "ht": "{pct}% chance", + "at": "" + }, + "{pct}% chance ({variants} only)": { + "ht": "{pct}% chance ({variants} only)", + "at": "" + }, + "{type} Ammo": { + "ht": "{type} Ammo", + "at": "" + } + } +} diff --git a/languages/english/ui.json b/languages/english/ui.json index 5a6f5ea5..b2976245 100644 --- a/languages/english/ui.json +++ b/languages/english/ui.json @@ -2286,6 +2286,10 @@ "ht": "Couldn't load the {language} localization from the configured source, and no cached copy was found. Showing the English base instead. Check the URL or file in Map Language File, then try again.", "at": "" }, + "language_updated_status": { + "ht": "A newer {language} translation was downloaded. Reloading with it.", + "at": "" + }, "language_generating_enhancements": { "ht": "Generating {language} enhancements from DataForge…", "at": "" diff --git a/languages/french/HELP.md b/languages/french/HELP.md index 679d9727..912e9f2c 100644 --- a/languages/french/HELP.md +++ b/languages/french/HELP.md @@ -118,7 +118,8 @@ Choisissez une langue dans le menu **Langue** de l'onglet **Paramètres** (à c - **L'anglais** (par défaut) utilise les textes d'origine extraits de votre propre `Data.p4k`. - **Les autres langues** téléchargent le `global.ini` traduit par la communauté pour cette langue et le superposent à la base anglaise : tout texte non couvert par la traduction retombe sur l'anglais au lieu de disparaître. Le téléchargement est mis en cache par langue ; revenir à une langue déjà utilisée réutilise le cache. -- **Les enrichissements restent en anglais.** Les blocs de stats, balises et détails de mission sont générés depuis les données du jeu et gardent leur forme anglaise au-dessus de la prose traduite. Une ligne mixte (par exemple un nom de rôle en français dans un bloc de stats anglais) est un comportement attendu, pas un bug. +- **Les améliorations suivent votre langue.** Les libellés de statistiques, les détails de mission et les lignes de journal ajoutés par Smart Citizen sont écrits dans la langue choisie. Les noms d'objets viennent de la traduction elle-même, et les tags comme `[BP]` ainsi que les titres de section des missions restent tels quels. +- **La traduction reste à jour.** À chaque démarrage, Smart Citizen vérifie s'il existe une version plus récente de la traduction communautaire et recharge avec elle. Une correction publiée après un patch du jeu vous parvient donc sans changer de langue. - **Associer un fichier de langue** (onglet Paramètres) permet de pointer une langue vers un autre `global.ini` : une URL (par exemple votre propre fork d'une traduction communautaire) ou, via **Parcourir...**, un fichier que vous avez déjà sur votre disque. Une URL est téléchargée et mise en cache, un fichier local est copié. Dans les deux cas, il l'emporte sur la valeur par défaut intégrée. Pour une langue dont la traduction communautaire ne peut pas être redistribuée (par ex. le coréen), l'association d'un fichier local est la seule option : installez d'abord le correctif de cette communauté, **copiez son `global.ini` ailleurs que dans votre installation de Star Citizen** (associer la copie que Smart Citizen y applique déjà renverrait sa propre sortie fusionnée comme « source » suivante et doublerait chaque enrichissement), puis utilisez Parcourir pour choisir cette copie. - **Le russe et le coréen partagent un même emplacement de langue du jeu.** Le jeu n'a pas d'emplacement russe et sa police coréenne est la seule à afficher le cyrillique, donc le russe est appliqué comme langue coréenne du jeu. Appliquer l'une remplace le fichier de l'autre dans le jeu, et seule la dernière appliquée s'affiche en jeu. - Certains textes de l'interface ne se mettent à jour qu'après un redémarrage de l'application. Les textes du tableau se rechargent immédiatement. diff --git a/languages/french/enhancements.json b/languages/french/enhancements.json new file mode 100644 index 00000000..14ecb23c --- /dev/null +++ b/languages/french/enhancements.json @@ -0,0 +1,833 @@ +{ + "_comment": "Translations of the text Smart Citizen adds to the game strings (stat labels, mission details, journal lines). Each key is the English text from languages/english/enhancements.json. 'ht' is a human translation and wins; 'at' is an AI draft. Keep each {placeholder} as it is.", + "strings": { + "--- EFFECT ---": { + "ht": "", + "at": "--- EFFET ---" + }, + "--- STATS ---": { + "ht": "", + "at": "--- STATS ---" + }, + "Absolute Range": { + "ht": "", + "at": "Portée absolue" + }, + "Acceleration": { + "ht": "", + "at": "Accélération" + }, + "Ace Pilot": { + "ht": "", + "at": "Pilote d'élite" + }, + "Ace Pilots": { + "ht": "", + "at": "Pilotes d'élite" + }, + "Aim Assist Range": { + "ht": "", + "at": "Portée assist. visée" + }, + "Alpha Dmg": { + "ht": "", + "at": "Dégâts alpha" + }, + "Ammo": { + "ht": "", + "at": "Munitions" + }, + "Arm Dist": { + "ht": "", + "at": "Dist. armement" + }, + "Arm Time": { + "ht": "", + "at": "Délai armement" + }, + "Armor HP": { + "ht": "", + "at": "PV blindage" + }, + "Armour": { + "ht": "", + "at": "Armure" + }, + "Attackers": { + "ht": "", + "at": "Assaillants" + }, + "Auto": { + "ht": "", + "at": "Auto" + }, + "Backup": { + "ht": "", + "at": "Renforts" + }, + "Bandits": { + "ht": "", + "at": "Bandits" + }, + "Base Resource Signature": { + "ht": "", + "at": "Signature de ressource de base" + }, + "Beam": { + "ht": "", + "at": "Rayon" + }, + "Bio": { + "ht": "", + "at": "Bio" + }, + "Blast Radius": { + "ht": "", + "at": "Rayon d'explosion" + }, + "Blueprint Reward": { + "ht": "", + "at": "Plan en récompense" + }, + "Bomb Slots": { + "ht": "", + "at": "Emplacements de bombes" + }, + "Boost": { + "ht": "", + "at": "Boost" + }, + "Boss": { + "ht": "", + "at": "Boss" + }, + "Burst": { + "ht": "", + "at": "Rafale" + }, + "CQC": { + "ht": "", + "at": "CQC" + }, + "Cal Rate": { + "ht": "", + "at": "Vitesse calib." + }, + "Captain": { + "ht": "", + "at": "Capitaine" + }, + "Chain": { + "ht": "", + "at": "Chaîne" + }, + "Charge": { + "ht": "", + "at": "Charge" + }, + "Civilians": { + "ht": "", + "at": "Civils" + }, + "Class": { + "ht": "", + "at": "Classe" + }, + "Combat": { + "ht": "", + "at": "Combat" + }, + "Complexity": { + "ht": "", + "at": "Complexité" + }, + "Component HP": { + "ht": "", + "at": "PV composant" + }, + "Cooldown": { + "ht": "", + "at": "Recharge" + }, + "Coolers": { + "ht": "", + "at": "Refroidisseurs" + }, + "Cooling Rate": { + "ht": "", + "at": "Refroidissement" + }, + "Cost/Shot": { + "ht": "", + "at": "Coût/tir" + }, + "Crew": { + "ht": "", + "at": "Équipage" + }, + "DPS": { + "ht": "", + "at": "DPS" + }, + "Damage": { + "ht": "", + "at": "Dégâts" + }, + "Damage-Map Rate": { + "ht": "", + "at": "Taux carte dégâts" + }, + "Damaged Delay": { + "ht": "", + "at": "Délai si endommagé" + }, + "Defenders": { + "ht": "", + "at": "Défenseurs" + }, + "Deflect": { + "ht": "", + "at": "Déviation" + }, + "Detection Mode": { + "ht": "", + "at": "Mode de détection" + }, + "Detonation": { + "ht": "", + "at": "Détonation" + }, + "Difficulty (1-7)": { + "ht": "", + "at": "Difficulté (1-7)" + }, + "Distort": { + "ht": "", + "at": "Distors." + }, + "Dmg Mult": { + "ht": "", + "at": "Mult. dégâts" + }, + "Downed Delay": { + "ht": "", + "at": "Délai si hors service" + }, + "Drop": { + "ht": "", + "at": "Baisse" + }, + "EM": { + "ht": "", + "at": "EM" + }, + "EM Signature": { + "ht": "", + "at": "Signature EM" + }, + "Effective Range": { + "ht": "", + "at": "Portée efficace" + }, + "Energy": { + "ht": "", + "at": "Énergie" + }, + "Engagement Type": { + "ht": "", + "at": "Type d'engagement" + }, + "Escort Wings": { + "ht": "", + "at": "Escadrilles d'escorte" + }, + "Escorts": { + "ht": "", + "at": "Escortes" + }, + "Extraction": { + "ht": "", + "at": "Extraction" + }, + "FPS": { + "ht": "", + "at": "FPS" + }, + "FPS & Ship": { + "ht": "", + "at": "FPS & vaisseau" + }, + "Failure": { + "ht": "", + "at": "Échec" + }, + "Failure Penalty": { + "ht": "", + "at": "Pénalité d'échec" + }, + "Fire Modes": { + "ht": "", + "at": "Modes de tir" + }, + "Fire Rate": { + "ht": "", + "at": "Cadence" + }, + "Fracture": { + "ht": "", + "at": "Fracturation" + }, + "Friendlies": { + "ht": "", + "at": "Alliés" + }, + "Fuel": { + "ht": "", + "at": "Carburant" + }, + "Fuel/Gm": { + "ht": "", + "at": "Carburant/Gm" + }, + "Full Dmg to": { + "ht": "", + "at": "Dégâts max jusqu'à" + }, + "Grade": { + "ht": "", + "at": "Grade" + }, + "Grunts": { + "ht": "", + "at": "Hommes de main" + }, + "Guaranteed": { + "ht": "", + "at": "Garanti" + }, + "Guards": { + "ht": "", + "at": "Gardes" + }, + "Guidance": { + "ht": "", + "at": "Guidage" + }, + "Guns": { + "ht": "", + "at": "Canons" + }, + "HP Rate": { + "ht": "", + "at": "Taux PV" + }, + "HP/Ammo": { + "ht": "", + "at": "PV/munition" + }, + "Heat": { + "ht": "", + "at": "Chaleur" + }, + "Heist Target": { + "ht": "", + "at": "Cible du casse" + }, + "Hostages": { + "ht": "", + "at": "Otages" + }, + "Hostile Allies": { + "ht": "", + "at": "Alliés hostiles" + }, + "Hostile Wave": { + "ht": "", + "at": "Vague hostile" + }, + "Hostiles": { + "ht": "", + "at": "Hostiles" + }, + "IR": { + "ht": "", + "at": "IR" + }, + "IR Signature": { + "ht": "", + "at": "Signature IR" + }, + "Inert Filter": { + "ht": "", + "at": "Filtre inerte" + }, + "Insurance": { + "ht": "", + "at": "Assurance" + }, + "Interdiction Ships": { + "ht": "", + "at": "Vaisseaux d'interdiction" + }, + "Item Type": { + "ht": "", + "at": "Type d'objet" + }, + "Juggernauts": { + "ht": "", + "at": "Juggernauts" + }, + "Jump Drives": { + "ht": "", + "at": "Moteurs de saut" + }, + "Knowledge": { + "ht": "", + "at": "Connaissances" + }, + "Kopions": { + "ht": "", + "at": "Kopions" + }, + "Length": { + "ht": "", + "at": "Longueur" + }, + "Lifetime": { + "ht": "", + "at": "Durée de vie" + }, + "Locations": { + "ht": "", + "at": "Emplacements" + }, + "Lock Range": { + "ht": "", + "at": "Portée verrouillage" + }, + "Lock Time": { + "ht": "", + "at": "Temps verrouillage" + }, + "MRacks": { + "ht": "", + "at": "Lance-missiles" + }, + "Material Efficiency": { + "ht": "", + "at": "Efficacité matériaux" + }, + "Maulers": { + "ht": "", + "at": "Maulers" + }, + "Max": { + "ht": "", + "at": "Max" + }, + "Max Distortion": { + "ht": "", + "at": "Distorsion max" + }, + "Max G-Force": { + "ht": "", + "at": "Force G max" + }, + "Max HP": { + "ht": "", + "at": "PV max" + }, + "Max Lifetime": { + "ht": "", + "at": "Durée de vie max" + }, + "Max Lock Range": { + "ht": "", + "at": "Portée verr. max" + }, + "Min Detonate": { + "ht": "", + "at": "Détonation min" + }, + "Min Dmg": { + "ht": "", + "at": "Dégâts min" + }, + "Min Lock Range": { + "ht": "", + "at": "Portée verr. min" + }, + "Mission Type": { + "ht": "", + "at": "Type de mission" + }, + "Nine Tails": { + "ht": "", + "at": "Nine Tails" + }, + "Objectives": { + "ht": "", + "at": "Objectifs" + }, + "Overheat Temp": { + "ht": "", + "at": "Temp. surchauffe" + }, + "Phys": { + "ht": "", + "at": "Phys." + }, + "Ping Cooldown": { + "ht": "", + "at": "Recharge ping" + }, + "Pirates": { + "ht": "", + "at": "Pirates" + }, + "Pitch": { + "ht": "", + "at": "Tangage" + }, + "Polaris": { + "ht": "", + "at": "Polaris" + }, + "Power": { + "ht": "", + "at": "Énergie" + }, + "Power Draw": { + "ht": "", + "at": "Consommation" + }, + "Power Output": { + "ht": "", + "at": "Production d'énergie" + }, + "Power Plants": { + "ht": "", + "at": "Générateurs" + }, + "Private Security": { + "ht": "", + "at": "Sécurité privée" + }, + "Probe": { + "ht": "", + "at": "Sonde" + }, + "Prospectors": { + "ht": "", + "at": "Prospectors" + }, + "Protected": { + "ht": "", + "at": "Protégés" + }, + "Proximity Range": { + "ht": "", + "at": "Portée de proximité" + }, + "QD": { + "ht": "", + "at": "MQ" + }, + "QT Fuel Use": { + "ht": "", + "at": "Conso. QT" + }, + "QT Speed": { + "ht": "", + "at": "Vitesse QT" + }, + "Quantum Drives": { + "ht": "", + "at": "Moteurs quantiques" + }, + "Quantum Enforcement Devices": { + "ht": "", + "at": "Dispositifs d'interdiction quantique" + }, + "Radars": { + "ht": "", + "at": "Radars" + }, + "Ramp": { + "ht": "", + "at": "Montée" + }, + "Range": { + "ht": "", + "at": "Portée" + }, + "Rank": { + "ht": "", + "at": "Rang" + }, + "Recharges Oxygen reserves of a suit.": { + "ht": "", + "at": "Recharge les réserves d'oxygène d'une combinaison." + }, + "Recipient": { + "ht": "", + "at": "Destinataire" + }, + "Reduces concussion symptoms, normalizes weapon handling and movement speed.": { + "ht": "", + "at": "Réduit les symptômes de commotion, normalise le maniement des armes et la vitesse de déplacement." + }, + "Reduces injuries from radiation.": { + "ht": "", + "at": "Réduit les blessures dues aux radiations." + }, + "Reduces pain symptoms, normalizes movement ability.": { + "ht": "", + "at": "Réduit la douleur, normalise la capacité de mouvement." + }, + "Reduces vision and hearing symptoms, normalizes stamina.": { + "ht": "", + "at": "Réduit les troubles de la vue et de l'ouïe, normalise l'endurance." + }, + "Refuel Nozzles": { + "ht": "", + "at": "Buses de ravitaillement" + }, + "Regen": { + "ht": "", + "at": "Régén." + }, + "Reinforcements": { + "ht": "", + "at": "Renforts" + }, + "Required": { + "ht": "", + "at": "Requis" + }, + "Resource Signatures": { + "ht": "", + "at": "Signatures de ressources" + }, + "Restores health and stops bleeding. When used on another person recovers from incapacitated state.": { + "ht": "", + "at": "Restaure la santé et arrête les saignements. Utilisé sur une autre personne, la sort de l'état d'incapacité." + }, + "Revives an overdosed person (if not incapacitated), doubles decay rate of Blood Drug Level.": { + "ht": "", + "at": "Ranime une personne en surdose (si elle n'est pas en incapacité), double la vitesse de baisse du taux de drogue sanguin." + }, + "Risk": { + "ht": "", + "at": "Risque" + }, + "Role": { + "ht": "", + "at": "Rôle" + }, + "Roll": { + "ht": "", + "at": "Roulis" + }, + "SCM": { + "ht": "", + "at": "SCM" + }, + "Salvageable Ships": { + "ht": "", + "at": "Vaisseaux récupérables" + }, + "Scanners": { + "ht": "", + "at": "Scanners" + }, + "Security Forces": { + "ht": "", + "at": "Forces de sécurité" + }, + "Seeker": { + "ht": "", + "at": "Autodirecteur" + }, + "Semi-Auto": { + "ht": "", + "at": "Semi-auto" + }, + "Sentries": { + "ht": "", + "at": "Sentinelles" + }, + "Shields": { + "ht": "", + "at": "Boucliers" + }, + "Ship": { + "ht": "", + "at": "Vaisseau" + }, + "Ships to Defend": { + "ht": "", + "at": "Vaisseaux à défendre" + }, + "Shotgun": { + "ht": "", + "at": "Fusil à pompe" + }, + "Size": { + "ht": "", + "at": "Taille" + }, + "Snipers": { + "ht": "", + "at": "Tireurs d'élite" + }, + "Soldiers": { + "ht": "", + "at": "Soldats" + }, + "Spool": { + "ht": "", + "at": "Préchauffage" + }, + "Standard": { + "ht": "", + "at": "Standard" + }, + "Starter": { + "ht": "", + "at": "Débutant" + }, + "Stun": { + "ht": "", + "at": "Étourd." + }, + "Targets": { + "ht": "", + "at": "Cibles" + }, + "Technicians": { + "ht": "", + "at": "Techniciens" + }, + "Thermal": { + "ht": "", + "at": "Thermique" + }, + "Tier": { + "ht": "", + "at": "Palier" + }, + "Tracking": { + "ht": "", + "at": "Suivi" + }, + "Tracking Range": { + "ht": "", + "at": "Portée de suivi" + }, + "Turn Rate": { + "ht": "", + "at": "Vitesse de virage" + }, + "Turrets": { + "ht": "", + "at": "Tourelles" + }, + "Unique": { + "ht": "", + "at": "Unique" + }, + "Used To Craft": { + "ht": "", + "at": "Sert à fabriquer" + }, + "Velocity": { + "ht": "", + "at": "Vitesse" + }, + "Wear": { + "ht": "", + "at": "Usure" + }, + "Weight": { + "ht": "", + "at": "Poids" + }, + "Xeno Threat": { + "ht": "", + "at": "Xeno Threat" + }, + "Yaw": { + "ht": "", + "at": "Lacet" + }, + "Yes": { + "ht": "", + "at": "Oui" + }, + "base": { + "ht": "", + "at": "base" + }, + "down": { + "ht": "", + "at": "descente" + }, + "empty": { + "ht": "", + "at": "vide" + }, + "express": { + "ht": "", + "at": "express" + }, + "friendly": { + "ht": "", + "at": "amical" + }, + "hostile": { + "ht": "", + "at": "hostile" + }, + "present": { + "ht": "", + "at": "présentes" + }, + "select variants": { + "ht": "", + "at": "certaines variantes" + }, + "up": { + "ht": "", + "at": "montée" + }, + "{count} items": { + "ht": "", + "at": "{count} objets" + }, + "{count} sets": { + "ht": "", + "at": "{count} ensembles" + }, + "{count} types": { + "ht": "", + "at": "{count} types" + }, + "{item} Set": { + "ht": "", + "at": "Ensemble {item}" + }, + "{pct}% chance": { + "ht": "", + "at": "{pct}% de chance" + }, + "{pct}% chance ({variants} only)": { + "ht": "", + "at": "{pct}% de chance ({variants} uniquement)" + }, + "{type} Ammo": { + "ht": "", + "at": "Munitions {type}" + } + } +} diff --git a/languages/french/ui.json b/languages/french/ui.json index a3dd6b03..f2fdf9b7 100644 --- a/languages/french/ui.json +++ b/languages/french/ui.json @@ -2286,6 +2286,10 @@ "ht": "", "at": "Impossible de charger la localisation {language} depuis la source configurée, et aucune copie en cache n'a été trouvée. Affichage du texte anglais de base à la place. Vérifiez l'URL ou le fichier dans Associer un fichier de langue, puis réessayez." }, + "language_updated_status": { + "ht": "", + "at": "Une traduction {language} plus récente a été téléchargée. Rechargement en cours." + }, "language_generating_enhancements": { "ht": "", "at": "Génération des enrichissements {language} depuis DataForge…" diff --git a/languages/german/HELP.md b/languages/german/HELP.md index 259b318f..c300d2e1 100644 --- a/languages/german/HELP.md +++ b/languages/german/HELP.md @@ -116,7 +116,8 @@ Wähle eine Sprache aus dem Dropdown-Menü **Sprache** im **Konfiguration**-Tab - **Englisch** (der Standard) verwendet die aus deiner eigenen `Data.p4k` extrahierten Standard-Strings. - **Andere Sprachen** laden die von der Community übersetzte `global.ini` dieser Sprache herunter und legen sie über die englische Basis, sodass jeder String, den die Übersetzung nicht abdeckt, auf Englisch zurückfällt, statt zu fehlen. Der Download wird pro Sprache zwischengespeichert; ein späterer Wechsel zurück nutzt den Cache erneut. -- **Erweiterungen bleiben auf Englisch.** Statistikblöcke, Tags und Missionsdetails werden aus Spieldaten erzeugt und behalten ihre englische Form über dem übersetzten Text bei. Eine gemischte Zeile (etwa ein deutscher Rollenname innerhalb eines englischen Statistikblocks) ist erwartet, kein Fehler. +- **Erweiterungen folgen deiner Sprache.** Die Werte-Bezeichnungen, Missionsdetails und Journalzeilen, die Smart Citizen hinzufügt, erscheinen in der gewählten Sprache. Gegenstandsnamen stammen aus der Übersetzung selbst, und Tags wie `[BP]` sowie die Abschnittsüberschriften der Missionen bleiben, wie sie sind. +- **Die Übersetzung bleibt aktuell.** Bei jedem Start prüft Smart Citizen, ob es eine neuere Version der Community-Übersetzung gibt, und lädt neu, falls ja. So erreicht dich eine Korrektur nach einem Spiel-Patch, ohne dass du die Sprache wechseln musst. - **Sprachdatei zuordnen** (Konfiguration-Tab) lässt dich eine Sprache auf eine andere `global.ini` verweisen — eine URL (zum Beispiel dein eigener Fork einer Community-Übersetzung) oder, über **Durchsuchen…**, eine Datei, die du bereits auf der Festplatte hast. Eine URL wird heruntergeladen und zwischengespeichert, eine lokale Datei wird hineinkopiert. In beiden Fällen gewinnt sie gegenüber dem mitgelieferten Standard. Für eine Sprache, deren Community-Übersetzung nicht weiterverbreitet werden darf (z. B. Koreanisch), ist die Zuordnung einer lokalen Datei die einzige Möglichkeit — installiere zuerst den eigenen Patch dieser Community, **kopiere dessen `global.ini` an einen Ort außerhalb deiner Star-Citizen-Installation** (würdest du die Kopie zuordnen, die Smart Citizen dort bereits anwendet, würde die eigene zusammengeführte Ausgabe als nächste „Quelle“ zurückgespeist und jede Erweiterung verdoppelt), und wähle diese Kopie dann über „Durchsuchen“ aus. - **Russisch und Koreanisch teilen sich einen Sprachplatz im Spiel.** Das Spiel hat keinen russischen Platz, und seine koreanische Schrift ist die einzige, die Kyrillisch darstellt, daher wird Russisch als koreanische Sprache des Spiels angewendet. Wendest du eine an, ersetzt sie die Datei der anderen im Spiel, und im Spiel erscheint nur die zuletzt angewendete. - Einige Oberflächentexte werden erst nach einem Neustart der App aktualisiert. Die Tabellen-Strings laden sofort neu. diff --git a/languages/german/enhancements.json b/languages/german/enhancements.json new file mode 100644 index 00000000..d4dd5ffe --- /dev/null +++ b/languages/german/enhancements.json @@ -0,0 +1,833 @@ +{ + "_comment": "Translations of the text Smart Citizen adds to the game strings (stat labels, mission details, journal lines). Each key is the English text from languages/english/enhancements.json. 'ht' is a human translation and wins; 'at' is an AI draft. Keep each {placeholder} as it is.", + "strings": { + "--- EFFECT ---": { + "ht": "", + "at": "--- WIRKUNG ---" + }, + "--- STATS ---": { + "ht": "", + "at": "--- WERTE ---" + }, + "Absolute Range": { + "ht": "", + "at": "Max. Reichweite" + }, + "Acceleration": { + "ht": "", + "at": "Beschleunigung" + }, + "Ace Pilot": { + "ht": "", + "at": "Ass-Pilot" + }, + "Ace Pilots": { + "ht": "", + "at": "Ass-Piloten" + }, + "Aim Assist Range": { + "ht": "", + "at": "Zielhilfe-Reichweite" + }, + "Alpha Dmg": { + "ht": "", + "at": "Alpha-Schaden" + }, + "Ammo": { + "ht": "", + "at": "Munition" + }, + "Arm Dist": { + "ht": "", + "at": "Scharf-Distanz" + }, + "Arm Time": { + "ht": "", + "at": "Scharf-Zeit" + }, + "Armor HP": { + "ht": "", + "at": "Panzerung TP" + }, + "Armour": { + "ht": "", + "at": "Rüstung" + }, + "Attackers": { + "ht": "", + "at": "Angreifer" + }, + "Auto": { + "ht": "", + "at": "Auto" + }, + "Backup": { + "ht": "", + "at": "Verstärkung" + }, + "Bandits": { + "ht": "", + "at": "Banditen" + }, + "Base Resource Signature": { + "ht": "", + "at": "Basis-Ressourcensignatur" + }, + "Beam": { + "ht": "", + "at": "Strahl" + }, + "Bio": { + "ht": "", + "at": "Bio" + }, + "Blast Radius": { + "ht": "", + "at": "Explosionsradius" + }, + "Blueprint Reward": { + "ht": "", + "at": "Blaupausen-Belohnung" + }, + "Bomb Slots": { + "ht": "", + "at": "Bombenplätze" + }, + "Boost": { + "ht": "", + "at": "Boost" + }, + "Boss": { + "ht": "", + "at": "Boss" + }, + "Burst": { + "ht": "", + "at": "Salve" + }, + "CQC": { + "ht": "", + "at": "Nahkampf" + }, + "Cal Rate": { + "ht": "", + "at": "Kalibrierrate" + }, + "Captain": { + "ht": "", + "at": "Kapitän" + }, + "Chain": { + "ht": "", + "at": "Kette" + }, + "Charge": { + "ht": "", + "at": "Aufladen" + }, + "Civilians": { + "ht": "", + "at": "Zivilisten" + }, + "Class": { + "ht": "", + "at": "Klasse" + }, + "Combat": { + "ht": "", + "at": "Kampf" + }, + "Complexity": { + "ht": "", + "at": "Komplexität" + }, + "Component HP": { + "ht": "", + "at": "Komponenten-TP" + }, + "Cooldown": { + "ht": "", + "at": "Abklingzeit" + }, + "Coolers": { + "ht": "", + "at": "Kühler" + }, + "Cooling Rate": { + "ht": "", + "at": "Kühlrate" + }, + "Cost/Shot": { + "ht": "", + "at": "Kosten/Schuss" + }, + "Crew": { + "ht": "", + "at": "Crew" + }, + "DPS": { + "ht": "", + "at": "DPS" + }, + "Damage": { + "ht": "", + "at": "Schaden" + }, + "Damage-Map Rate": { + "ht": "", + "at": "Schadenskarten-Rate" + }, + "Damaged Delay": { + "ht": "", + "at": "Verzög. n. Schaden" + }, + "Defenders": { + "ht": "", + "at": "Verteidiger" + }, + "Deflect": { + "ht": "", + "at": "Abprallen" + }, + "Detection Mode": { + "ht": "", + "at": "Erfassungsmodus" + }, + "Detonation": { + "ht": "", + "at": "Zündung" + }, + "Difficulty (1-7)": { + "ht": "", + "at": "Schwierigkeit (1-7)" + }, + "Distort": { + "ht": "", + "at": "Verzerr." + }, + "Dmg Mult": { + "ht": "", + "at": "Schadensmult." + }, + "Downed Delay": { + "ht": "", + "at": "Verzög. n. Ausfall" + }, + "Drop": { + "ht": "", + "at": "Abfall" + }, + "EM": { + "ht": "", + "at": "EM" + }, + "EM Signature": { + "ht": "", + "at": "EM-Signatur" + }, + "Effective Range": { + "ht": "", + "at": "Effektive Reichweite" + }, + "Energy": { + "ht": "", + "at": "Energie" + }, + "Engagement Type": { + "ht": "", + "at": "Einsatzart" + }, + "Escort Wings": { + "ht": "", + "at": "Begleitstaffeln" + }, + "Escorts": { + "ht": "", + "at": "Begleitschutz" + }, + "Extraction": { + "ht": "", + "at": "Extraktion" + }, + "FPS": { + "ht": "", + "at": "FPS" + }, + "FPS & Ship": { + "ht": "", + "at": "FPS & Schiff" + }, + "Failure": { + "ht": "", + "at": "Fehlschlag" + }, + "Failure Penalty": { + "ht": "", + "at": "Strafe bei Fehlschlag" + }, + "Fire Modes": { + "ht": "", + "at": "Feuermodi" + }, + "Fire Rate": { + "ht": "", + "at": "Feuerrate" + }, + "Fracture": { + "ht": "", + "at": "Brechen" + }, + "Friendlies": { + "ht": "", + "at": "Verbündete" + }, + "Fuel": { + "ht": "", + "at": "Treibstoff" + }, + "Fuel/Gm": { + "ht": "", + "at": "Treibstoff/Gm" + }, + "Full Dmg to": { + "ht": "", + "at": "Voller Schaden bis" + }, + "Grade": { + "ht": "", + "at": "Güte" + }, + "Grunts": { + "ht": "", + "at": "Fußvolk" + }, + "Guaranteed": { + "ht": "", + "at": "Garantiert" + }, + "Guards": { + "ht": "", + "at": "Wachen" + }, + "Guidance": { + "ht": "", + "at": "Lenkung" + }, + "Guns": { + "ht": "", + "at": "Geschütze" + }, + "HP Rate": { + "ht": "", + "at": "TP-Rate" + }, + "HP/Ammo": { + "ht": "", + "at": "TP/Munition" + }, + "Heat": { + "ht": "", + "at": "Hitze" + }, + "Heist Target": { + "ht": "", + "at": "Raubziel" + }, + "Hostages": { + "ht": "", + "at": "Geiseln" + }, + "Hostile Allies": { + "ht": "", + "at": "Feindliche Verbündete" + }, + "Hostile Wave": { + "ht": "", + "at": "Feindwelle" + }, + "Hostiles": { + "ht": "", + "at": "Feinde" + }, + "IR": { + "ht": "", + "at": "IR" + }, + "IR Signature": { + "ht": "", + "at": "IR-Signatur" + }, + "Inert Filter": { + "ht": "", + "at": "Inertfilter" + }, + "Insurance": { + "ht": "", + "at": "Versicherung" + }, + "Interdiction Ships": { + "ht": "", + "at": "Abfangschiffe" + }, + "Item Type": { + "ht": "", + "at": "Gegenstandstyp" + }, + "Juggernauts": { + "ht": "", + "at": "Juggernauts" + }, + "Jump Drives": { + "ht": "", + "at": "Sprungantriebe" + }, + "Knowledge": { + "ht": "", + "at": "Wissen" + }, + "Kopions": { + "ht": "", + "at": "Kopions" + }, + "Length": { + "ht": "", + "at": "Länge" + }, + "Lifetime": { + "ht": "", + "at": "Lebensdauer" + }, + "Locations": { + "ht": "", + "at": "Fundorte" + }, + "Lock Range": { + "ht": "", + "at": "Erfassungsreichweite" + }, + "Lock Time": { + "ht": "", + "at": "Erfassungszeit" + }, + "MRacks": { + "ht": "", + "at": "Raketenwerfer" + }, + "Material Efficiency": { + "ht": "", + "at": "Materialeffizienz" + }, + "Maulers": { + "ht": "", + "at": "Maulers" + }, + "Max": { + "ht": "", + "at": "Max." + }, + "Max Distortion": { + "ht": "", + "at": "Max. Verzerrung" + }, + "Max G-Force": { + "ht": "", + "at": "Max. G-Kraft" + }, + "Max HP": { + "ht": "", + "at": "Max. TP" + }, + "Max Lifetime": { + "ht": "", + "at": "Max. Lebensdauer" + }, + "Max Lock Range": { + "ht": "", + "at": "Max. Erfassungsreichw." + }, + "Min Detonate": { + "ht": "", + "at": "Min. Zündabstand" + }, + "Min Dmg": { + "ht": "", + "at": "Min. Schaden" + }, + "Min Lock Range": { + "ht": "", + "at": "Min. Erfassungsreichw." + }, + "Mission Type": { + "ht": "", + "at": "Missionsart" + }, + "Nine Tails": { + "ht": "", + "at": "Nine Tails" + }, + "Objectives": { + "ht": "", + "at": "Ziele" + }, + "Overheat Temp": { + "ht": "", + "at": "Überhitzungstemp." + }, + "Phys": { + "ht": "", + "at": "Phys." + }, + "Ping Cooldown": { + "ht": "", + "at": "Ping-Abklingzeit" + }, + "Pirates": { + "ht": "", + "at": "Piraten" + }, + "Pitch": { + "ht": "", + "at": "Nicken" + }, + "Polaris": { + "ht": "", + "at": "Polaris" + }, + "Power": { + "ht": "", + "at": "Energie" + }, + "Power Draw": { + "ht": "", + "at": "Energiebedarf" + }, + "Power Output": { + "ht": "", + "at": "Energieleistung" + }, + "Power Plants": { + "ht": "", + "at": "Generatoren" + }, + "Private Security": { + "ht": "", + "at": "Sicherheitsdienst" + }, + "Probe": { + "ht": "", + "at": "Sonde" + }, + "Prospectors": { + "ht": "", + "at": "Prospectors" + }, + "Protected": { + "ht": "", + "at": "Geschützte" + }, + "Proximity Range": { + "ht": "", + "at": "Annäherungsreichw." + }, + "QD": { + "ht": "", + "at": "QA" + }, + "QT Fuel Use": { + "ht": "", + "at": "QT-Verbrauch" + }, + "QT Speed": { + "ht": "", + "at": "QT-Tempo" + }, + "Quantum Drives": { + "ht": "", + "at": "Quantenantriebe" + }, + "Quantum Enforcement Devices": { + "ht": "", + "at": "Quanten-Abfanggeräte" + }, + "Radars": { + "ht": "", + "at": "Radare" + }, + "Ramp": { + "ht": "", + "at": "Anlauf" + }, + "Range": { + "ht": "", + "at": "Reichweite" + }, + "Rank": { + "ht": "", + "at": "Rang" + }, + "Recharges Oxygen reserves of a suit.": { + "ht": "", + "at": "Füllt die Sauerstoffreserven eines Anzugs auf." + }, + "Recipient": { + "ht": "", + "at": "Empfänger" + }, + "Reduces concussion symptoms, normalizes weapon handling and movement speed.": { + "ht": "", + "at": "Lindert Gehirnerschütterung, normalisiert Waffenhandhabung und Bewegungstempo." + }, + "Reduces injuries from radiation.": { + "ht": "", + "at": "Lindert Strahlenschäden." + }, + "Reduces pain symptoms, normalizes movement ability.": { + "ht": "", + "at": "Lindert Schmerzen, normalisiert die Bewegungsfähigkeit." + }, + "Reduces vision and hearing symptoms, normalizes stamina.": { + "ht": "", + "at": "Lindert Seh- und Hörstörungen, normalisiert die Ausdauer." + }, + "Refuel Nozzles": { + "ht": "", + "at": "Tankdüsen" + }, + "Regen": { + "ht": "", + "at": "Regen." + }, + "Reinforcements": { + "ht": "", + "at": "Verstärkung" + }, + "Required": { + "ht": "", + "at": "Benötigt" + }, + "Resource Signatures": { + "ht": "", + "at": "Ressourcensignaturen" + }, + "Restores health and stops bleeding. When used on another person recovers from incapacitated state.": { + "ht": "", + "at": "Stellt Gesundheit wieder her und stoppt Blutungen. An einer anderen Person angewendet, holt sie aus der Kampfunfähigkeit zurück." + }, + "Revives an overdosed person (if not incapacitated), doubles decay rate of Blood Drug Level.": { + "ht": "", + "at": "Belebt eine überdosierte Person wieder (wenn nicht kampfunfähig), verdoppelt den Abbau des Blutdrogenspiegels." + }, + "Risk": { + "ht": "", + "at": "Risiko" + }, + "Role": { + "ht": "", + "at": "Rolle" + }, + "Roll": { + "ht": "", + "at": "Rollen" + }, + "SCM": { + "ht": "", + "at": "SCM" + }, + "Salvageable Ships": { + "ht": "", + "at": "Bergbare Schiffe" + }, + "Scanners": { + "ht": "", + "at": "Scanner" + }, + "Security Forces": { + "ht": "", + "at": "Sicherheitskräfte" + }, + "Seeker": { + "ht": "", + "at": "Suchkopf" + }, + "Semi-Auto": { + "ht": "", + "at": "Halbautomatik" + }, + "Sentries": { + "ht": "", + "at": "Wachposten" + }, + "Shields": { + "ht": "", + "at": "Schilde" + }, + "Ship": { + "ht": "", + "at": "Schiff" + }, + "Ships to Defend": { + "ht": "", + "at": "Zu schützende Schiffe" + }, + "Shotgun": { + "ht": "", + "at": "Schrot" + }, + "Size": { + "ht": "", + "at": "Größe" + }, + "Snipers": { + "ht": "", + "at": "Scharfschützen" + }, + "Soldiers": { + "ht": "", + "at": "Soldaten" + }, + "Spool": { + "ht": "", + "at": "Hochfahren" + }, + "Standard": { + "ht": "", + "at": "Standard" + }, + "Starter": { + "ht": "", + "at": "Einsteiger" + }, + "Stun": { + "ht": "", + "at": "Betäubung" + }, + "Targets": { + "ht": "", + "at": "Zielpersonen" + }, + "Technicians": { + "ht": "", + "at": "Techniker" + }, + "Thermal": { + "ht": "", + "at": "Thermisch" + }, + "Tier": { + "ht": "", + "at": "Stufe" + }, + "Tracking": { + "ht": "", + "at": "Zielverfolgung" + }, + "Tracking Range": { + "ht": "", + "at": "Verfolgungsreichweite" + }, + "Turn Rate": { + "ht": "", + "at": "Drehrate" + }, + "Turrets": { + "ht": "", + "at": "Geschütztürme" + }, + "Unique": { + "ht": "", + "at": "Einmalig" + }, + "Used To Craft": { + "ht": "", + "at": "Verwendet für" + }, + "Velocity": { + "ht": "", + "at": "Geschwindigkeit" + }, + "Wear": { + "ht": "", + "at": "Verschleiß" + }, + "Weight": { + "ht": "", + "at": "Gewicht" + }, + "Xeno Threat": { + "ht": "", + "at": "Xeno Threat" + }, + "Yaw": { + "ht": "", + "at": "Gieren" + }, + "Yes": { + "ht": "", + "at": "Ja" + }, + "base": { + "ht": "", + "at": "Basis" + }, + "down": { + "ht": "", + "at": "ab" + }, + "empty": { + "ht": "", + "at": "leer" + }, + "express": { + "ht": "", + "at": "Express" + }, + "friendly": { + "ht": "", + "at": "freundlich" + }, + "hostile": { + "ht": "", + "at": "feindlich" + }, + "present": { + "ht": "", + "at": "vorhanden" + }, + "select variants": { + "ht": "", + "at": "bestimmte Varianten" + }, + "up": { + "ht": "", + "at": "an" + }, + "{count} items": { + "ht": "", + "at": "{count} Gegenstände" + }, + "{count} sets": { + "ht": "", + "at": "{count} Sets" + }, + "{count} types": { + "ht": "", + "at": "{count} Typen" + }, + "{item} Set": { + "ht": "", + "at": "{item}-Set" + }, + "{pct}% chance": { + "ht": "", + "at": "{pct}% Chance" + }, + "{pct}% chance ({variants} only)": { + "ht": "", + "at": "{pct}% Chance (nur {variants})" + }, + "{type} Ammo": { + "ht": "", + "at": "{type}-Munition" + } + } +} diff --git a/languages/german/ui.json b/languages/german/ui.json index 817a3852..28aa1d54 100644 --- a/languages/german/ui.json +++ b/languages/german/ui.json @@ -2286,6 +2286,10 @@ "ht": "", "at": "Die {language}-Lokalisierung konnte nicht aus der konfigurierten Quelle geladen werden, und es wurde keine zwischengespeicherte Kopie gefunden. Stattdessen wird die englische Basis angezeigt. Überprüfe die URL oder Datei in Sprachdatei zuordnen und versuche es erneut." }, + "language_updated_status": { + "ht": "", + "at": "Eine neuere {language}-Übersetzung wurde heruntergeladen. Wird neu geladen." + }, "language_generating_enhancements": { "ht": "", "at": "{language}-Erweiterungen werden aus DataForge erstellt…" diff --git a/languages/italian/HELP.md b/languages/italian/HELP.md index d2050a92..80e542c2 100644 --- a/languages/italian/HELP.md +++ b/languages/italian/HELP.md @@ -116,7 +116,8 @@ Scegli una lingua dal menu a tendina **Lingua** nella scheda **Configurazione** - **Inglese** (predefinito) usa i testi originali estratti dal tuo `Data.p4k`. - **Le altre lingue** scaricano il `global.ini` tradotto dalla community per quella lingua e lo sovrappongono alla base inglese, così qualsiasi stringa non coperta dalla traduzione torna all'inglese invece di risultare mancante. Il download viene messo in cache per lingua; tornare a una lingua già usata riutilizza la cache. -- **I miglioramenti restano in inglese.** I blocchi di statistiche, i tag e i dettagli di missione sono generati dai dati di gioco e mantengono la loro forma inglese sopra la prosa tradotta. Una riga mista (per esempio un nome di ruolo in francese dentro un blocco di statistiche in inglese) è un comportamento previsto, non un bug. +- **I miglioramenti seguono la tua lingua.** Le etichette delle statistiche, i dettagli di missione e le righe del diario aggiunti da Smart Citizen sono scritti nella lingua scelta. I nomi degli oggetti vengono dalla traduzione stessa, e i tag come `[BP]` e i titoli delle sezioni delle missioni restano come sono. +- **La traduzione resta aggiornata.** A ogni avvio Smart Citizen controlla se esiste una versione più recente della traduzione della community e ricarica con quella, così una correzione dopo una patch del gioco ti arriva senza cambiare lingua. - **Associa File Lingua** (scheda Configurazione) ti permette di puntare una lingua verso un `global.ini` diverso: un URL (per esempio un tuo fork di una traduzione della community) oppure, tramite **Sfoglia...**, un file che hai già sul disco. Un URL viene scaricato e messo in cache, un file locale viene copiato. In entrambi i casi prevale sul valore predefinito integrato. Per una lingua la cui traduzione della community non può essere ridistribuita (ad es. il coreano), associare un file locale è l'unica opzione: installa prima la patch di quella community, **copia il suo `global.ini` in un punto diverso dall'installazione di Star Citizen** (associare la copia che Smart Citizen applica già lì reimmetterebbe il suo stesso output unito come «sorgente» successiva e raddoppierebbe ogni miglioramento), poi usa Sfoglia per scegliere quella copia. - **Russo e coreano condividono uno stesso slot di lingua del gioco.** Il gioco non ha uno slot per il russo e il suo font coreano è l'unico che mostra il cirillico, quindi il russo viene applicato come lingua coreana del gioco. Applicarne una sostituisce nel gioco il file dell'altra, e in gioco compare solo l'ultima applicata. - Alcuni testi dell'interfaccia si aggiornano solo dopo un riavvio dell'app. I testi della tabella si ricaricano immediatamente. diff --git a/languages/italian/enhancements.json b/languages/italian/enhancements.json new file mode 100644 index 00000000..01e68359 --- /dev/null +++ b/languages/italian/enhancements.json @@ -0,0 +1,833 @@ +{ + "_comment": "Translations of the text Smart Citizen adds to the game strings (stat labels, mission details, journal lines). Each key is the English text from languages/english/enhancements.json. 'ht' is a human translation and wins; 'at' is an AI draft. Keep each {placeholder} as it is.", + "strings": { + "--- EFFECT ---": { + "ht": "", + "at": "--- EFFETTO ---" + }, + "--- STATS ---": { + "ht": "", + "at": "--- STATISTICHE ---" + }, + "Absolute Range": { + "ht": "", + "at": "Gittata assoluta" + }, + "Acceleration": { + "ht": "", + "at": "Accelerazione" + }, + "Ace Pilot": { + "ht": "", + "at": "Pilota asso" + }, + "Ace Pilots": { + "ht": "", + "at": "Piloti assi" + }, + "Aim Assist Range": { + "ht": "", + "at": "Portata mira assistita" + }, + "Alpha Dmg": { + "ht": "", + "at": "Danno alfa" + }, + "Ammo": { + "ht": "", + "at": "Munizioni" + }, + "Arm Dist": { + "ht": "", + "at": "Dist. innesco" + }, + "Arm Time": { + "ht": "", + "at": "Tempo innesco" + }, + "Armor HP": { + "ht": "", + "at": "PS corazza" + }, + "Armour": { + "ht": "", + "at": "Armatura" + }, + "Attackers": { + "ht": "", + "at": "Aggressori" + }, + "Auto": { + "ht": "", + "at": "Auto" + }, + "Backup": { + "ht": "", + "at": "Rinforzi" + }, + "Bandits": { + "ht": "", + "at": "Banditi" + }, + "Base Resource Signature": { + "ht": "", + "at": "Firma risorsa di base" + }, + "Beam": { + "ht": "", + "at": "Raggio" + }, + "Bio": { + "ht": "", + "at": "Bio" + }, + "Blast Radius": { + "ht": "", + "at": "Raggio esplosione" + }, + "Blueprint Reward": { + "ht": "", + "at": "Progetto in premio" + }, + "Bomb Slots": { + "ht": "", + "at": "Slot bombe" + }, + "Boost": { + "ht": "", + "at": "Boost" + }, + "Boss": { + "ht": "", + "at": "Boss" + }, + "Burst": { + "ht": "", + "at": "Raffica" + }, + "CQC": { + "ht": "", + "at": "CQC" + }, + "Cal Rate": { + "ht": "", + "at": "Vel. calibr." + }, + "Captain": { + "ht": "", + "at": "Capitano" + }, + "Chain": { + "ht": "", + "at": "Catena" + }, + "Charge": { + "ht": "", + "at": "Carica" + }, + "Civilians": { + "ht": "", + "at": "Civili" + }, + "Class": { + "ht": "", + "at": "Classe" + }, + "Combat": { + "ht": "", + "at": "Combattimento" + }, + "Complexity": { + "ht": "", + "at": "Complessità" + }, + "Component HP": { + "ht": "", + "at": "PS componente" + }, + "Cooldown": { + "ht": "", + "at": "Ricarica" + }, + "Coolers": { + "ht": "", + "at": "Refrigeratori" + }, + "Cooling Rate": { + "ht": "", + "at": "Raffreddamento" + }, + "Cost/Shot": { + "ht": "", + "at": "Costo/colpo" + }, + "Crew": { + "ht": "", + "at": "Equipaggio" + }, + "DPS": { + "ht": "", + "at": "DPS" + }, + "Damage": { + "ht": "", + "at": "Danno" + }, + "Damage-Map Rate": { + "ht": "", + "at": "Tasso mappa danni" + }, + "Damaged Delay": { + "ht": "", + "at": "Ritardo se danneggiato" + }, + "Defenders": { + "ht": "", + "at": "Difensori" + }, + "Deflect": { + "ht": "", + "at": "Deflessione" + }, + "Detection Mode": { + "ht": "", + "at": "Modalità rilevamento" + }, + "Detonation": { + "ht": "", + "at": "Detonazione" + }, + "Difficulty (1-7)": { + "ht": "", + "at": "Difficoltà (1-7)" + }, + "Distort": { + "ht": "", + "at": "Distors." + }, + "Dmg Mult": { + "ht": "", + "at": "Molt. danni" + }, + "Downed Delay": { + "ht": "", + "at": "Ritardo se abbattuto" + }, + "Drop": { + "ht": "", + "at": "Calo" + }, + "EM": { + "ht": "", + "at": "EM" + }, + "EM Signature": { + "ht": "", + "at": "Firma EM" + }, + "Effective Range": { + "ht": "", + "at": "Gittata efficace" + }, + "Energy": { + "ht": "", + "at": "Energia" + }, + "Engagement Type": { + "ht": "", + "at": "Tipo di scontro" + }, + "Escort Wings": { + "ht": "", + "at": "Stormi di scorta" + }, + "Escorts": { + "ht": "", + "at": "Scorte" + }, + "Extraction": { + "ht": "", + "at": "Estrazione" + }, + "FPS": { + "ht": "", + "at": "FPS" + }, + "FPS & Ship": { + "ht": "", + "at": "FPS e nave" + }, + "Failure": { + "ht": "", + "at": "Fallimento" + }, + "Failure Penalty": { + "ht": "", + "at": "Penalità fallimento" + }, + "Fire Modes": { + "ht": "", + "at": "Modalità di fuoco" + }, + "Fire Rate": { + "ht": "", + "at": "Cadenza" + }, + "Fracture": { + "ht": "", + "at": "Frattura" + }, + "Friendlies": { + "ht": "", + "at": "Alleati" + }, + "Fuel": { + "ht": "", + "at": "Carburante" + }, + "Fuel/Gm": { + "ht": "", + "at": "Carburante/Gm" + }, + "Full Dmg to": { + "ht": "", + "at": "Danno pieno fino a" + }, + "Grade": { + "ht": "", + "at": "Grado" + }, + "Grunts": { + "ht": "", + "at": "Scagnozzi" + }, + "Guaranteed": { + "ht": "", + "at": "Garantito" + }, + "Guards": { + "ht": "", + "at": "Guardie" + }, + "Guidance": { + "ht": "", + "at": "Guida" + }, + "Guns": { + "ht": "", + "at": "Cannoni" + }, + "HP Rate": { + "ht": "", + "at": "Tasso PS" + }, + "HP/Ammo": { + "ht": "", + "at": "PS/munizione" + }, + "Heat": { + "ht": "", + "at": "Calore" + }, + "Heist Target": { + "ht": "", + "at": "Obiettivo del colpo" + }, + "Hostages": { + "ht": "", + "at": "Ostaggi" + }, + "Hostile Allies": { + "ht": "", + "at": "Alleati ostili" + }, + "Hostile Wave": { + "ht": "", + "at": "Ondata ostile" + }, + "Hostiles": { + "ht": "", + "at": "Ostili" + }, + "IR": { + "ht": "", + "at": "IR" + }, + "IR Signature": { + "ht": "", + "at": "Firma IR" + }, + "Inert Filter": { + "ht": "", + "at": "Filtro inerte" + }, + "Insurance": { + "ht": "", + "at": "Assicurazione" + }, + "Interdiction Ships": { + "ht": "", + "at": "Navi d'interdizione" + }, + "Item Type": { + "ht": "", + "at": "Tipo di oggetto" + }, + "Juggernauts": { + "ht": "", + "at": "Juggernaut" + }, + "Jump Drives": { + "ht": "", + "at": "Motori di salto" + }, + "Knowledge": { + "ht": "", + "at": "Conoscenza" + }, + "Kopions": { + "ht": "", + "at": "Kopion" + }, + "Length": { + "ht": "", + "at": "Lunghezza" + }, + "Lifetime": { + "ht": "", + "at": "Durata" + }, + "Locations": { + "ht": "", + "at": "Luoghi" + }, + "Lock Range": { + "ht": "", + "at": "Portata aggancio" + }, + "Lock Time": { + "ht": "", + "at": "Tempo aggancio" + }, + "MRacks": { + "ht": "", + "at": "Lanciamissili" + }, + "Material Efficiency": { + "ht": "", + "at": "Efficienza materiali" + }, + "Maulers": { + "ht": "", + "at": "Maulers" + }, + "Max": { + "ht": "", + "at": "Max" + }, + "Max Distortion": { + "ht": "", + "at": "Distorsione max" + }, + "Max G-Force": { + "ht": "", + "at": "Forza G max" + }, + "Max HP": { + "ht": "", + "at": "PS max" + }, + "Max Lifetime": { + "ht": "", + "at": "Durata max" + }, + "Max Lock Range": { + "ht": "", + "at": "Portata aggancio max" + }, + "Min Detonate": { + "ht": "", + "at": "Detonazione min" + }, + "Min Dmg": { + "ht": "", + "at": "Danno min" + }, + "Min Lock Range": { + "ht": "", + "at": "Portata aggancio min" + }, + "Mission Type": { + "ht": "", + "at": "Tipo di missione" + }, + "Nine Tails": { + "ht": "", + "at": "Nine Tails" + }, + "Objectives": { + "ht": "", + "at": "Obiettivi" + }, + "Overheat Temp": { + "ht": "", + "at": "Temp. surriscaldamento" + }, + "Phys": { + "ht": "", + "at": "Fis." + }, + "Ping Cooldown": { + "ht": "", + "at": "Ricarica ping" + }, + "Pirates": { + "ht": "", + "at": "Pirati" + }, + "Pitch": { + "ht": "", + "at": "Beccheggio" + }, + "Polaris": { + "ht": "", + "at": "Polaris" + }, + "Power": { + "ht": "", + "at": "Energia" + }, + "Power Draw": { + "ht": "", + "at": "Consumo" + }, + "Power Output": { + "ht": "", + "at": "Potenza erogata" + }, + "Power Plants": { + "ht": "", + "at": "Generatori" + }, + "Private Security": { + "ht": "", + "at": "Sicurezza privata" + }, + "Probe": { + "ht": "", + "at": "Sonda" + }, + "Prospectors": { + "ht": "", + "at": "Prospector" + }, + "Protected": { + "ht": "", + "at": "Protetti" + }, + "Proximity Range": { + "ht": "", + "at": "Portata prossimità" + }, + "QD": { + "ht": "", + "at": "MQ" + }, + "QT Fuel Use": { + "ht": "", + "at": "Consumo QT" + }, + "QT Speed": { + "ht": "", + "at": "Velocità QT" + }, + "Quantum Drives": { + "ht": "", + "at": "Motori quantici" + }, + "Quantum Enforcement Devices": { + "ht": "", + "at": "Dispositivi di interdizione quantica" + }, + "Radars": { + "ht": "", + "at": "Radar" + }, + "Ramp": { + "ht": "", + "at": "Rampa" + }, + "Range": { + "ht": "", + "at": "Gittata" + }, + "Rank": { + "ht": "", + "at": "Grado" + }, + "Recharges Oxygen reserves of a suit.": { + "ht": "", + "at": "Ricarica le riserve di ossigeno di una tuta." + }, + "Recipient": { + "ht": "", + "at": "Destinatario" + }, + "Reduces concussion symptoms, normalizes weapon handling and movement speed.": { + "ht": "", + "at": "Riduce i sintomi da commozione, normalizza maneggevolezza delle armi e velocità di movimento." + }, + "Reduces injuries from radiation.": { + "ht": "", + "at": "Riduce le lesioni da radiazioni." + }, + "Reduces pain symptoms, normalizes movement ability.": { + "ht": "", + "at": "Riduce il dolore, normalizza la capacità di movimento." + }, + "Reduces vision and hearing symptoms, normalizes stamina.": { + "ht": "", + "at": "Riduce i disturbi di vista e udito, normalizza la resistenza." + }, + "Refuel Nozzles": { + "ht": "", + "at": "Ugelli di rifornimento" + }, + "Regen": { + "ht": "", + "at": "Rigen." + }, + "Reinforcements": { + "ht": "", + "at": "Rinforzi" + }, + "Required": { + "ht": "", + "at": "Richiesto" + }, + "Resource Signatures": { + "ht": "", + "at": "Firme delle risorse" + }, + "Restores health and stops bleeding. When used on another person recovers from incapacitated state.": { + "ht": "", + "at": "Ripristina la salute e ferma le emorragie. Usato su un'altra persona, la recupera dall'inabilità." + }, + "Revives an overdosed person (if not incapacitated), doubles decay rate of Blood Drug Level.": { + "ht": "", + "at": "Rianima una persona in overdose (se non inabile), raddoppia il calo del livello di droga nel sangue." + }, + "Risk": { + "ht": "", + "at": "Rischio" + }, + "Role": { + "ht": "", + "at": "Ruolo" + }, + "Roll": { + "ht": "", + "at": "Rollio" + }, + "SCM": { + "ht": "", + "at": "SCM" + }, + "Salvageable Ships": { + "ht": "", + "at": "Navi recuperabili" + }, + "Scanners": { + "ht": "", + "at": "Scanner" + }, + "Security Forces": { + "ht": "", + "at": "Forze di sicurezza" + }, + "Seeker": { + "ht": "", + "at": "Cercatore" + }, + "Semi-Auto": { + "ht": "", + "at": "Semiauto" + }, + "Sentries": { + "ht": "", + "at": "Sentinelle" + }, + "Shields": { + "ht": "", + "at": "Scudi" + }, + "Ship": { + "ht": "", + "at": "Nave" + }, + "Ships to Defend": { + "ht": "", + "at": "Navi da difendere" + }, + "Shotgun": { + "ht": "", + "at": "Fucile a pompa" + }, + "Size": { + "ht": "", + "at": "Taglia" + }, + "Snipers": { + "ht": "", + "at": "Cecchini" + }, + "Soldiers": { + "ht": "", + "at": "Soldati" + }, + "Spool": { + "ht": "", + "at": "Avvio" + }, + "Standard": { + "ht": "", + "at": "Standard" + }, + "Starter": { + "ht": "", + "at": "Iniziale" + }, + "Stun": { + "ht": "", + "at": "Stordim." + }, + "Targets": { + "ht": "", + "at": "Bersagli" + }, + "Technicians": { + "ht": "", + "at": "Tecnici" + }, + "Thermal": { + "ht": "", + "at": "Termico" + }, + "Tier": { + "ht": "", + "at": "Livello" + }, + "Tracking": { + "ht": "", + "at": "Tracciamento" + }, + "Tracking Range": { + "ht": "", + "at": "Portata tracciamento" + }, + "Turn Rate": { + "ht": "", + "at": "Velocità di virata" + }, + "Turrets": { + "ht": "", + "at": "Torrette" + }, + "Unique": { + "ht": "", + "at": "Unica" + }, + "Used To Craft": { + "ht": "", + "at": "Usato per creare" + }, + "Velocity": { + "ht": "", + "at": "Velocità" + }, + "Wear": { + "ht": "", + "at": "Usura" + }, + "Weight": { + "ht": "", + "at": "Peso" + }, + "Xeno Threat": { + "ht": "", + "at": "Xeno Threat" + }, + "Yaw": { + "ht": "", + "at": "Imbardata" + }, + "Yes": { + "ht": "", + "at": "Sì" + }, + "base": { + "ht": "", + "at": "base" + }, + "down": { + "ht": "", + "at": "discesa" + }, + "empty": { + "ht": "", + "at": "vuoto" + }, + "express": { + "ht": "", + "at": "espressa" + }, + "friendly": { + "ht": "", + "at": "amiche" + }, + "hostile": { + "ht": "", + "at": "ostili" + }, + "present": { + "ht": "", + "at": "presenti" + }, + "select variants": { + "ht": "", + "at": "alcune varianti" + }, + "up": { + "ht": "", + "at": "salita" + }, + "{count} items": { + "ht": "", + "at": "{count} oggetti" + }, + "{count} sets": { + "ht": "", + "at": "{count} set" + }, + "{count} types": { + "ht": "", + "at": "{count} tipi" + }, + "{item} Set": { + "ht": "", + "at": "Set {item}" + }, + "{pct}% chance": { + "ht": "", + "at": "{pct}% di probabilità" + }, + "{pct}% chance ({variants} only)": { + "ht": "", + "at": "{pct}% di probabilità (solo {variants})" + }, + "{type} Ammo": { + "ht": "", + "at": "Munizioni {type}" + } + } +} diff --git a/languages/italian/ui.json b/languages/italian/ui.json index 473aa3a2..4db103e4 100644 --- a/languages/italian/ui.json +++ b/languages/italian/ui.json @@ -2286,6 +2286,10 @@ "ht": "", "at": "Impossibile caricare la localizzazione {language} dalla fonte configurata, e non è stata trovata alcuna copia in cache. Viene mostrata la base inglese. Controlla l'URL o il file in Associa file lingua, poi riprova." }, + "language_updated_status": { + "ht": "", + "at": "È stata scaricata una traduzione {language} più recente. Ricaricamento in corso." + }, "language_generating_enhancements": { "ht": "", "at": "Generazione dei miglioramenti {language} da DataForge…" diff --git a/languages/japanese/HELP.md b/languages/japanese/HELP.md index 96519406..c4a156af 100644 --- a/languages/japanese/HELP.md +++ b/languages/japanese/HELP.md @@ -116,7 +116,8 @@ Star Citizen がアップデートされても、編集内容は `<データフ - **English**(デフォルト)は、あなた自身の `Data.p4k` から抽出された標準文字列を使用します。 - **その他の言語** は、その言語のコミュニティ翻訳された `global.ini` をダウンロードし、英語ベースの上に重ねます。したがって、翻訳がカバーしていない文字列は、欠落するのではなく英語にフォールバックします。ダウンロードは言語ごとにキャッシュされ、後で戻したときはキャッシュを再利用します。 -- **拡張は英語のままです。** ステータスブロック、タグ、ミッション詳細はゲームデータから生成され、翻訳された文章の上でも英語の形を保ちます。混在した行(たとえば、英語のステータスブロック内のフランス語のロール名)は想定内であり、バグではありません。 +- **拡張は選んだ言語で表示されます。** Smart Citizen が追加するステータス名、ミッション詳細、ジャーナルの行は、選んだ言語で書かれます。アイテム名は翻訳そのものから取られ、`[BP]` などのタグとミッションのセクション見出しはそのままです。 +- **翻訳は最新に保たれます。** Smart Citizen は起動するたびにコミュニティ翻訳の新しい版があるか確認し、あればそれで再読み込みします。ゲームのパッチ後の修正も、言語を切り替えずに届きます。 - **言語ファイルをマッピング**(Config タブ)を使うと、ある言語を別の `global.ini` に向けられます。URL(たとえばコミュニティ翻訳の自分のフォーク)か、**参照...** で選ぶ、すでにディスク上にあるファイルを指定できます。URL はダウンロードされてキャッシュされ、ローカルファイルはコピーされます。どちらの場合も、同梱のデフォルトより優先されます。コミュニティ翻訳を再配布できない言語(たとえば韓国語)では、ローカルファイルのマッピングが唯一の方法です。先にそのコミュニティのパッチをインストールし、**その `global.ini` を Star Citizen のインストール先以外の場所にコピー**してください(Smart Citizen がすでに適用しているコピーをマッピングすると、その結合済みの出力が次の「ソース」として再び読み込まれ、すべての拡張が二重になります)。その後、参照でそのコピーを選びます。 - **ロシア語と韓国語はゲームの同じ言語スロットを共有します。** ゲームにはロシア語のスロットがなく、キリル文字を表示できるのは韓国語フォントだけなので、ロシア語はゲームの韓国語として適用されます。一方を適用するとゲーム内のもう一方のファイルが置き換えられ、ゲーム内には最後に適用したものだけが表示されます。 - 一部のインターフェーステキストは、アプリの再起動後にのみ更新されます。テーブルの文字列はすぐに再読み込みされます。 diff --git a/languages/japanese/enhancements.json b/languages/japanese/enhancements.json new file mode 100644 index 00000000..bb1a2f64 --- /dev/null +++ b/languages/japanese/enhancements.json @@ -0,0 +1,833 @@ +{ + "_comment": "Translations of the text Smart Citizen adds to the game strings (stat labels, mission details, journal lines). Each key is the English text from languages/english/enhancements.json. 'ht' is a human translation and wins; 'at' is an AI draft. Keep each {placeholder} as it is.", + "strings": { + "--- EFFECT ---": { + "ht": "", + "at": "--- 効果 ---" + }, + "--- STATS ---": { + "ht": "", + "at": "--- ステータス ---" + }, + "Absolute Range": { + "ht": "", + "at": "最大射程" + }, + "Acceleration": { + "ht": "", + "at": "加速度" + }, + "Ace Pilot": { + "ht": "", + "at": "エースパイロット" + }, + "Ace Pilots": { + "ht": "", + "at": "エースパイロット" + }, + "Aim Assist Range": { + "ht": "", + "at": "エイムアシスト範囲" + }, + "Alpha Dmg": { + "ht": "", + "at": "単発ダメージ" + }, + "Ammo": { + "ht": "", + "at": "弾薬" + }, + "Arm Dist": { + "ht": "", + "at": "安全解除距離" + }, + "Arm Time": { + "ht": "", + "at": "安全解除時間" + }, + "Armor HP": { + "ht": "", + "at": "装甲HP" + }, + "Armour": { + "ht": "", + "at": "アーマー" + }, + "Attackers": { + "ht": "", + "at": "襲撃者" + }, + "Auto": { + "ht": "", + "at": "フルオート" + }, + "Backup": { + "ht": "", + "at": "増援" + }, + "Bandits": { + "ht": "", + "at": "賊" + }, + "Base Resource Signature": { + "ht": "", + "at": "基本リソースシグネチャ" + }, + "Beam": { + "ht": "", + "at": "ビーム" + }, + "Bio": { + "ht": "", + "at": "生物" + }, + "Blast Radius": { + "ht": "", + "at": "爆発半径" + }, + "Blueprint Reward": { + "ht": "", + "at": "設計図報酬" + }, + "Bomb Slots": { + "ht": "", + "at": "爆弾スロット" + }, + "Boost": { + "ht": "", + "at": "ブースト" + }, + "Boss": { + "ht": "", + "at": "ボス" + }, + "Burst": { + "ht": "", + "at": "バースト" + }, + "CQC": { + "ht": "", + "at": "近接戦" + }, + "Cal Rate": { + "ht": "", + "at": "較正速度" + }, + "Captain": { + "ht": "", + "at": "艦長" + }, + "Chain": { + "ht": "", + "at": "連続" + }, + "Charge": { + "ht": "", + "at": "チャージ" + }, + "Civilians": { + "ht": "", + "at": "民間人" + }, + "Class": { + "ht": "", + "at": "クラス" + }, + "Combat": { + "ht": "", + "at": "戦闘" + }, + "Complexity": { + "ht": "", + "at": "複雑さ" + }, + "Component HP": { + "ht": "", + "at": "コンポーネントHP" + }, + "Cooldown": { + "ht": "", + "at": "クールダウン" + }, + "Coolers": { + "ht": "", + "at": "クーラー" + }, + "Cooling Rate": { + "ht": "", + "at": "冷却速度" + }, + "Cost/Shot": { + "ht": "", + "at": "1発コスト" + }, + "Crew": { + "ht": "", + "at": "乗員" + }, + "DPS": { + "ht": "", + "at": "DPS" + }, + "Damage": { + "ht": "", + "at": "ダメージ" + }, + "Damage-Map Rate": { + "ht": "", + "at": "損傷マップ速度" + }, + "Damaged Delay": { + "ht": "", + "at": "損傷時遅延" + }, + "Defenders": { + "ht": "", + "at": "防衛者" + }, + "Deflect": { + "ht": "", + "at": "偏向" + }, + "Detection Mode": { + "ht": "", + "at": "探知モード" + }, + "Detonation": { + "ht": "", + "at": "起爆" + }, + "Difficulty (1-7)": { + "ht": "", + "at": "難易度 (1-7)" + }, + "Distort": { + "ht": "", + "at": "ディストーション" + }, + "Dmg Mult": { + "ht": "", + "at": "ダメージ倍率" + }, + "Downed Delay": { + "ht": "", + "at": "停止時遅延" + }, + "Drop": { + "ht": "", + "at": "減衰" + }, + "EM": { + "ht": "", + "at": "EM" + }, + "EM Signature": { + "ht": "", + "at": "EMシグネチャ" + }, + "Effective Range": { + "ht": "", + "at": "有効射程" + }, + "Energy": { + "ht": "", + "at": "エネルギー" + }, + "Engagement Type": { + "ht": "", + "at": "交戦タイプ" + }, + "Escort Wings": { + "ht": "", + "at": "護衛編隊" + }, + "Escorts": { + "ht": "", + "at": "護衛" + }, + "Extraction": { + "ht": "", + "at": "抽出" + }, + "FPS": { + "ht": "", + "at": "FPS" + }, + "FPS & Ship": { + "ht": "", + "at": "FPSと艦船" + }, + "Failure": { + "ht": "", + "at": "失敗" + }, + "Failure Penalty": { + "ht": "", + "at": "失敗ペナルティ" + }, + "Fire Modes": { + "ht": "", + "at": "射撃モード" + }, + "Fire Rate": { + "ht": "", + "at": "連射速度" + }, + "Fracture": { + "ht": "", + "at": "破砕" + }, + "Friendlies": { + "ht": "", + "at": "味方" + }, + "Fuel": { + "ht": "", + "at": "燃料" + }, + "Fuel/Gm": { + "ht": "", + "at": "燃料/Gm" + }, + "Full Dmg to": { + "ht": "", + "at": "最大ダメージ距離" + }, + "Grade": { + "ht": "", + "at": "グレード" + }, + "Grunts": { + "ht": "", + "at": "雑兵" + }, + "Guaranteed": { + "ht": "", + "at": "確定" + }, + "Guards": { + "ht": "", + "at": "警備兵" + }, + "Guidance": { + "ht": "", + "at": "誘導" + }, + "Guns": { + "ht": "", + "at": "ガン" + }, + "HP Rate": { + "ht": "", + "at": "HP速度" + }, + "HP/Ammo": { + "ht": "", + "at": "HP/弾薬" + }, + "Heat": { + "ht": "", + "at": "熱" + }, + "Heist Target": { + "ht": "", + "at": "強奪対象" + }, + "Hostages": { + "ht": "", + "at": "人質" + }, + "Hostile Allies": { + "ht": "", + "at": "敵の援軍" + }, + "Hostile Wave": { + "ht": "", + "at": "敵ウェーブ" + }, + "Hostiles": { + "ht": "", + "at": "敵" + }, + "IR": { + "ht": "", + "at": "IR" + }, + "IR Signature": { + "ht": "", + "at": "IRシグネチャ" + }, + "Inert Filter": { + "ht": "", + "at": "不活性フィルター" + }, + "Insurance": { + "ht": "", + "at": "保険" + }, + "Interdiction Ships": { + "ht": "", + "at": "妨害艦" + }, + "Item Type": { + "ht": "", + "at": "アイテムタイプ" + }, + "Juggernauts": { + "ht": "", + "at": "ジャガーノート" + }, + "Jump Drives": { + "ht": "", + "at": "ジャンプドライブ" + }, + "Knowledge": { + "ht": "", + "at": "知識" + }, + "Kopions": { + "ht": "", + "at": "コピオン" + }, + "Length": { + "ht": "", + "at": "全長" + }, + "Lifetime": { + "ht": "", + "at": "存続時間" + }, + "Locations": { + "ht": "", + "at": "場所" + }, + "Lock Range": { + "ht": "", + "at": "ロック範囲" + }, + "Lock Time": { + "ht": "", + "at": "ロック時間" + }, + "MRacks": { + "ht": "", + "at": "ミサイルラック" + }, + "Material Efficiency": { + "ht": "", + "at": "素材効率" + }, + "Maulers": { + "ht": "", + "at": "Maulers" + }, + "Max": { + "ht": "", + "at": "最大" + }, + "Max Distortion": { + "ht": "", + "at": "最大ディストーション" + }, + "Max G-Force": { + "ht": "", + "at": "最大G" + }, + "Max HP": { + "ht": "", + "at": "最大HP" + }, + "Max Lifetime": { + "ht": "", + "at": "最大寿命" + }, + "Max Lock Range": { + "ht": "", + "at": "最大ロック距離" + }, + "Min Detonate": { + "ht": "", + "at": "最小起爆距離" + }, + "Min Dmg": { + "ht": "", + "at": "最小ダメージ" + }, + "Min Lock Range": { + "ht": "", + "at": "最小ロック距離" + }, + "Mission Type": { + "ht": "", + "at": "ミッションタイプ" + }, + "Nine Tails": { + "ht": "", + "at": "Nine Tails" + }, + "Objectives": { + "ht": "", + "at": "目標" + }, + "Overheat Temp": { + "ht": "", + "at": "オーバーヒート温度" + }, + "Phys": { + "ht": "", + "at": "物理" + }, + "Ping Cooldown": { + "ht": "", + "at": "Pingクールダウン" + }, + "Pirates": { + "ht": "", + "at": "海賊" + }, + "Pitch": { + "ht": "", + "at": "ピッチ" + }, + "Polaris": { + "ht": "", + "at": "Polaris" + }, + "Power": { + "ht": "", + "at": "電源" + }, + "Power Draw": { + "ht": "", + "at": "消費電力" + }, + "Power Output": { + "ht": "", + "at": "発電量" + }, + "Power Plants": { + "ht": "", + "at": "パワープラント" + }, + "Private Security": { + "ht": "", + "at": "民間警備" + }, + "Probe": { + "ht": "", + "at": "プローブ" + }, + "Prospectors": { + "ht": "", + "at": "Prospector" + }, + "Protected": { + "ht": "", + "at": "護衛対象" + }, + "Proximity Range": { + "ht": "", + "at": "近接信管範囲" + }, + "QD": { + "ht": "", + "at": "QD" + }, + "QT Fuel Use": { + "ht": "", + "at": "QT燃料消費" + }, + "QT Speed": { + "ht": "", + "at": "QT速度" + }, + "Quantum Drives": { + "ht": "", + "at": "量子ドライブ" + }, + "Quantum Enforcement Devices": { + "ht": "", + "at": "量子妨害装置" + }, + "Radars": { + "ht": "", + "at": "レーダー" + }, + "Ramp": { + "ht": "", + "at": "立ち上がり" + }, + "Range": { + "ht": "", + "at": "射程" + }, + "Rank": { + "ht": "", + "at": "ランク" + }, + "Recharges Oxygen reserves of a suit.": { + "ht": "", + "at": "スーツの酸素残量を補充する。" + }, + "Recipient": { + "ht": "", + "at": "受取人" + }, + "Reduces concussion symptoms, normalizes weapon handling and movement speed.": { + "ht": "", + "at": "脳震盪の症状を和らげ、武器の扱いと移動速度を正常に戻す。" + }, + "Reduces injuries from radiation.": { + "ht": "", + "at": "放射線による負傷を軽減する。" + }, + "Reduces pain symptoms, normalizes movement ability.": { + "ht": "", + "at": "痛みの症状を和らげ、移動能力を正常に戻す。" + }, + "Reduces vision and hearing symptoms, normalizes stamina.": { + "ht": "", + "at": "視覚と聴覚の症状を和らげ、スタミナを正常に戻す。" + }, + "Refuel Nozzles": { + "ht": "", + "at": "給油ノズル" + }, + "Regen": { + "ht": "", + "at": "回復" + }, + "Reinforcements": { + "ht": "", + "at": "増援" + }, + "Required": { + "ht": "", + "at": "必要値" + }, + "Resource Signatures": { + "ht": "", + "at": "リソースシグネチャ" + }, + "Restores health and stops bleeding. When used on another person recovers from incapacitated state.": { + "ht": "", + "at": "体力を回復し出血を止める。他人に使うと行動不能状態から回復させる。" + }, + "Revives an overdosed person (if not incapacitated), doubles decay rate of Blood Drug Level.": { + "ht": "", + "at": "過剰摂取した人を蘇生する(行動不能でない場合)。血中薬物濃度の低下速度を2倍にする。" + }, + "Risk": { + "ht": "", + "at": "リスク" + }, + "Role": { + "ht": "", + "at": "役割" + }, + "Roll": { + "ht": "", + "at": "ロール" + }, + "SCM": { + "ht": "", + "at": "SCM" + }, + "Salvageable Ships": { + "ht": "", + "at": "サルベージ可能な艦船" + }, + "Scanners": { + "ht": "", + "at": "スキャナー" + }, + "Security Forces": { + "ht": "", + "at": "警備部隊" + }, + "Seeker": { + "ht": "", + "at": "シーカー" + }, + "Semi-Auto": { + "ht": "", + "at": "セミオート" + }, + "Sentries": { + "ht": "", + "at": "歩哨" + }, + "Shields": { + "ht": "", + "at": "シールド" + }, + "Ship": { + "ht": "", + "at": "艦船" + }, + "Ships to Defend": { + "ht": "", + "at": "防衛対象の艦船" + }, + "Shotgun": { + "ht": "", + "at": "ショットガン" + }, + "Size": { + "ht": "", + "at": "サイズ" + }, + "Snipers": { + "ht": "", + "at": "狙撃手" + }, + "Soldiers": { + "ht": "", + "at": "兵士" + }, + "Spool": { + "ht": "", + "at": "スプール" + }, + "Standard": { + "ht": "", + "at": "通常" + }, + "Starter": { + "ht": "", + "at": "初心者向け" + }, + "Stun": { + "ht": "", + "at": "スタン" + }, + "Targets": { + "ht": "", + "at": "標的" + }, + "Technicians": { + "ht": "", + "at": "技術者" + }, + "Thermal": { + "ht": "", + "at": "熱" + }, + "Tier": { + "ht": "", + "at": "段階" + }, + "Tracking": { + "ht": "", + "at": "追尾" + }, + "Tracking Range": { + "ht": "", + "at": "追尾範囲" + }, + "Turn Rate": { + "ht": "", + "at": "旋回速度" + }, + "Turrets": { + "ht": "", + "at": "タレット" + }, + "Unique": { + "ht": "", + "at": "一度限り" + }, + "Used To Craft": { + "ht": "", + "at": "クラフト用途" + }, + "Velocity": { + "ht": "", + "at": "弾速" + }, + "Wear": { + "ht": "", + "at": "摩耗" + }, + "Weight": { + "ht": "", + "at": "重量" + }, + "Xeno Threat": { + "ht": "", + "at": "Xeno Threat" + }, + "Yaw": { + "ht": "", + "at": "ヨー" + }, + "Yes": { + "ht": "", + "at": "あり" + }, + "base": { + "ht": "", + "at": "通常" + }, + "down": { + "ht": "", + "at": "下降" + }, + "empty": { + "ht": "", + "at": "空" + }, + "express": { + "ht": "", + "at": "特急" + }, + "friendly": { + "ht": "", + "at": "味方" + }, + "hostile": { + "ht": "", + "at": "敵対" + }, + "present": { + "ht": "", + "at": "あり" + }, + "select variants": { + "ht": "", + "at": "一部のバリエーション" + }, + "up": { + "ht": "", + "at": "上昇" + }, + "{count} items": { + "ht": "", + "at": "{count} アイテム" + }, + "{count} sets": { + "ht": "", + "at": "{count} セット" + }, + "{count} types": { + "ht": "", + "at": "{count} 種類" + }, + "{item} Set": { + "ht": "", + "at": "{item} セット" + }, + "{pct}% chance": { + "ht": "", + "at": "{pct}% の確率" + }, + "{pct}% chance ({variants} only)": { + "ht": "", + "at": "{pct}% の確率({variants} のみ)" + }, + "{type} Ammo": { + "ht": "", + "at": "{type} 弾薬" + } + } +} diff --git a/languages/japanese/ui.json b/languages/japanese/ui.json index 4c2ecea4..64220db8 100644 --- a/languages/japanese/ui.json +++ b/languages/japanese/ui.json @@ -2286,6 +2286,10 @@ "ht": "", "at": "設定されたソースから {language} のローカライズを読み込めず、キャッシュされたコピーも見つかりませんでした。代わりに英語のベースを表示します。「言語ファイルをマッピング」の URL またはファイルを確認してから、再試行してください。" }, + "language_updated_status": { + "ht": "", + "at": "新しい {language} の翻訳をダウンロードしました。再読み込みしています。" + }, "language_generating_enhancements": { "ht": "", "at": "DataForge から {language} の拡張を生成しています…" diff --git a/languages/korean/HELP.md b/languages/korean/HELP.md index bddff28d..aa9e462b 100644 --- a/languages/korean/HELP.md +++ b/languages/korean/HELP.md @@ -116,7 +116,8 @@ Star Citizen이 업데이트되면 편집 내용은 `<데이터 폴더>\<채널> - **영어**(기본값)는 본인의 `Data.p4k`에서 추출한 기본 텍스트를 사용합니다. - **다른 언어**는 해당 언어의 커뮤니티 번역 `global.ini`를 다운로드해 영어 기본 텍스트 위에 겹쳐 적용하므로, 번역이 다루지 않는 텍스트는 사라지지 않고 영어로 대체됩니다. 다운로드한 파일은 언어별로 캐시되며, 나중에 다시 전환할 때는 캐시를 재사용합니다. -- **강화는 영어로 유지됩니다.** 통계 블록, 태그, 임무 세부 정보는 게임 데이터에서 생성되며 번역된 본문 위에서 영어 형태를 유지합니다. 혼합된 줄(예: 영어 통계 블록 안의 다른 언어 역할 이름)이 나타날 수 있으며, 이는 버그가 아니라 예상된 동작입니다. +- **강화는 선택한 언어를 따릅니다.** Smart Citizen이 추가하는 능력치 이름, 임무 세부 정보, 일지 줄은 선택한 언어로 표시됩니다. 아이템 이름은 번역 자체에서 가져오며, `[BP]` 같은 태그와 임무 섹션 제목은 그대로입니다. +- **번역이 최신 상태로 유지됩니다.** Smart Citizen은 시작할 때마다 커뮤니티 번역의 새 버전이 있는지 확인하고, 있으면 그것으로 다시 불러옵니다. 게임 패치 후의 수정도 언어를 바꾸지 않고 받을 수 있습니다. - **언어 파일 매핑**(설정 탭)을 사용하면 한 언어를 다른 `global.ini`로 지정할 수 있습니다. URL(예: 커뮤니티 번역의 자체 포크)이나, **찾아보기...**로 고른 이미 디스크에 있는 파일을 지정할 수 있습니다. URL은 다운로드되어 캐시되고, 로컬 파일은 복사되어 들어옵니다. 어느 쪽이든 번들에 포함된 기본값보다 우선합니다. 한국어처럼 커뮤니티 번역을 재배포할 수 없는 언어는 로컬 파일 매핑이 유일한 방법입니다. 해당 커뮤니티의 패치를 먼저 설치한 다음, **Star Citizen 설치 폴더가 아닌 다른 위치에 `global.ini`를 복사**하세요(Smart Citizen이 이미 적용해 놓은 파일을 그대로 매핑하면, 다음 적용 시 그 출력을 소스로 다시 읽어들여 모든 강화 내용이 두 배로 늘어납니다). 그런 다음 찾아보기로 그 복사본을 선택하세요. - **러시아어와 한국어는 게임의 같은 언어 슬롯을 함께 사용합니다.** 게임에는 러시아어 슬롯이 없고 키릴 문자를 표시하는 글꼴은 한국어 글꼴뿐이어서, 러시아어는 게임의 한국어로 적용됩니다. 하나를 적용하면 게임에서 다른 하나의 파일이 바뀌며, 게임에는 마지막으로 적용한 언어만 표시됩니다. - 일부 인터페이스 텍스트는 앱을 다시 시작해야 업데이트됩니다. 테이블 텍스트는 즉시 다시 로드됩니다. diff --git a/languages/korean/enhancements.json b/languages/korean/enhancements.json new file mode 100644 index 00000000..ce97529c --- /dev/null +++ b/languages/korean/enhancements.json @@ -0,0 +1,833 @@ +{ + "_comment": "Translations of the text Smart Citizen adds to the game strings (stat labels, mission details, journal lines). Each key is the English text from languages/english/enhancements.json. 'ht' is a human translation and wins; 'at' is an AI draft. Keep each {placeholder} as it is.", + "strings": { + "--- EFFECT ---": { + "ht": "", + "at": "--- 효과 ---" + }, + "--- STATS ---": { + "ht": "", + "at": "--- 능력치 ---" + }, + "Absolute Range": { + "ht": "", + "at": "절대 사거리" + }, + "Acceleration": { + "ht": "", + "at": "가속도" + }, + "Ace Pilot": { + "ht": "", + "at": "에이스 조종사" + }, + "Ace Pilots": { + "ht": "", + "at": "에이스 조종사" + }, + "Aim Assist Range": { + "ht": "", + "at": "조준 보조 범위" + }, + "Alpha Dmg": { + "ht": "", + "at": "단발 피해" + }, + "Ammo": { + "ht": "", + "at": "탄약" + }, + "Arm Dist": { + "ht": "", + "at": "신관 작동 거리" + }, + "Arm Time": { + "ht": "", + "at": "신관 작동 시간" + }, + "Armor HP": { + "ht": "", + "at": "장갑 HP" + }, + "Armour": { + "ht": "", + "at": "방어구" + }, + "Attackers": { + "ht": "", + "at": "공격자" + }, + "Auto": { + "ht": "", + "at": "자동" + }, + "Backup": { + "ht": "", + "at": "지원군" + }, + "Bandits": { + "ht": "", + "at": "도적" + }, + "Base Resource Signature": { + "ht": "", + "at": "기본 자원 신호" + }, + "Beam": { + "ht": "", + "at": "빔" + }, + "Bio": { + "ht": "", + "at": "생화학" + }, + "Blast Radius": { + "ht": "", + "at": "폭발 반경" + }, + "Blueprint Reward": { + "ht": "", + "at": "설계도 보상" + }, + "Bomb Slots": { + "ht": "", + "at": "폭탄 슬롯" + }, + "Boost": { + "ht": "", + "at": "부스트" + }, + "Boss": { + "ht": "", + "at": "보스" + }, + "Burst": { + "ht": "", + "at": "점사" + }, + "CQC": { + "ht": "", + "at": "근접전" + }, + "Cal Rate": { + "ht": "", + "at": "보정 속도" + }, + "Captain": { + "ht": "", + "at": "함장" + }, + "Chain": { + "ht": "", + "at": "연계" + }, + "Charge": { + "ht": "", + "at": "충전" + }, + "Civilians": { + "ht": "", + "at": "민간인" + }, + "Class": { + "ht": "", + "at": "등급" + }, + "Combat": { + "ht": "", + "at": "전투" + }, + "Complexity": { + "ht": "", + "at": "복잡도" + }, + "Component HP": { + "ht": "", + "at": "부품 HP" + }, + "Cooldown": { + "ht": "", + "at": "재사용 대기" + }, + "Coolers": { + "ht": "", + "at": "냉각기" + }, + "Cooling Rate": { + "ht": "", + "at": "냉각 속도" + }, + "Cost/Shot": { + "ht": "", + "at": "발당 소모" + }, + "Crew": { + "ht": "", + "at": "승무원" + }, + "DPS": { + "ht": "", + "at": "DPS" + }, + "Damage": { + "ht": "", + "at": "피해" + }, + "Damage-Map Rate": { + "ht": "", + "at": "손상 맵 속도" + }, + "Damaged Delay": { + "ht": "", + "at": "손상 시 지연" + }, + "Defenders": { + "ht": "", + "at": "방어자" + }, + "Deflect": { + "ht": "", + "at": "편향" + }, + "Detection Mode": { + "ht": "", + "at": "탐지 모드" + }, + "Detonation": { + "ht": "", + "at": "기폭" + }, + "Difficulty (1-7)": { + "ht": "", + "at": "난이도 (1-7)" + }, + "Distort": { + "ht": "", + "at": "왜곡" + }, + "Dmg Mult": { + "ht": "", + "at": "피해 배율" + }, + "Downed Delay": { + "ht": "", + "at": "정지 시 지연" + }, + "Drop": { + "ht": "", + "at": "감소" + }, + "EM": { + "ht": "", + "at": "EM" + }, + "EM Signature": { + "ht": "", + "at": "EM 신호" + }, + "Effective Range": { + "ht": "", + "at": "유효 사거리" + }, + "Energy": { + "ht": "", + "at": "에너지" + }, + "Engagement Type": { + "ht": "", + "at": "교전 유형" + }, + "Escort Wings": { + "ht": "", + "at": "호위 편대" + }, + "Escorts": { + "ht": "", + "at": "호위" + }, + "Extraction": { + "ht": "", + "at": "추출" + }, + "FPS": { + "ht": "", + "at": "FPS" + }, + "FPS & Ship": { + "ht": "", + "at": "FPS 및 함선" + }, + "Failure": { + "ht": "", + "at": "실패" + }, + "Failure Penalty": { + "ht": "", + "at": "실패 패널티" + }, + "Fire Modes": { + "ht": "", + "at": "사격 모드" + }, + "Fire Rate": { + "ht": "", + "at": "연사 속도" + }, + "Fracture": { + "ht": "", + "at": "파쇄" + }, + "Friendlies": { + "ht": "", + "at": "아군" + }, + "Fuel": { + "ht": "", + "at": "연료" + }, + "Fuel/Gm": { + "ht": "", + "at": "연료/Gm" + }, + "Full Dmg to": { + "ht": "", + "at": "최대 피해 거리" + }, + "Grade": { + "ht": "", + "at": "등급" + }, + "Grunts": { + "ht": "", + "at": "졸개" + }, + "Guaranteed": { + "ht": "", + "at": "확정" + }, + "Guards": { + "ht": "", + "at": "경비병" + }, + "Guidance": { + "ht": "", + "at": "유도" + }, + "Guns": { + "ht": "", + "at": "기관포" + }, + "HP Rate": { + "ht": "", + "at": "HP 속도" + }, + "HP/Ammo": { + "ht": "", + "at": "HP/탄약" + }, + "Heat": { + "ht": "", + "at": "열" + }, + "Heist Target": { + "ht": "", + "at": "강탈 대상" + }, + "Hostages": { + "ht": "", + "at": "인질" + }, + "Hostile Allies": { + "ht": "", + "at": "적 지원군" + }, + "Hostile Wave": { + "ht": "", + "at": "적 웨이브" + }, + "Hostiles": { + "ht": "", + "at": "적" + }, + "IR": { + "ht": "", + "at": "IR" + }, + "IR Signature": { + "ht": "", + "at": "IR 신호" + }, + "Inert Filter": { + "ht": "", + "at": "불활성 필터" + }, + "Insurance": { + "ht": "", + "at": "보험" + }, + "Interdiction Ships": { + "ht": "", + "at": "차단 함선" + }, + "Item Type": { + "ht": "", + "at": "아이템 유형" + }, + "Juggernauts": { + "ht": "", + "at": "저거너트" + }, + "Jump Drives": { + "ht": "", + "at": "점프 드라이브" + }, + "Knowledge": { + "ht": "", + "at": "지식" + }, + "Kopions": { + "ht": "", + "at": "코피온" + }, + "Length": { + "ht": "", + "at": "길이" + }, + "Lifetime": { + "ht": "", + "at": "지속 시간" + }, + "Locations": { + "ht": "", + "at": "위치" + }, + "Lock Range": { + "ht": "", + "at": "락온 범위" + }, + "Lock Time": { + "ht": "", + "at": "락온 시간" + }, + "MRacks": { + "ht": "", + "at": "미사일 랙" + }, + "Material Efficiency": { + "ht": "", + "at": "재료 효율" + }, + "Maulers": { + "ht": "", + "at": "Maulers" + }, + "Max": { + "ht": "", + "at": "최대" + }, + "Max Distortion": { + "ht": "", + "at": "최대 왜곡" + }, + "Max G-Force": { + "ht": "", + "at": "최대 G" + }, + "Max HP": { + "ht": "", + "at": "최대 HP" + }, + "Max Lifetime": { + "ht": "", + "at": "최대 수명" + }, + "Max Lock Range": { + "ht": "", + "at": "최대 락온 거리" + }, + "Min Detonate": { + "ht": "", + "at": "최소 기폭 거리" + }, + "Min Dmg": { + "ht": "", + "at": "최소 피해" + }, + "Min Lock Range": { + "ht": "", + "at": "최소 락온 거리" + }, + "Mission Type": { + "ht": "", + "at": "임무 유형" + }, + "Nine Tails": { + "ht": "", + "at": "Nine Tails" + }, + "Objectives": { + "ht": "", + "at": "목표" + }, + "Overheat Temp": { + "ht": "", + "at": "과열 온도" + }, + "Phys": { + "ht": "", + "at": "물리" + }, + "Ping Cooldown": { + "ht": "", + "at": "핑 재사용 대기" + }, + "Pirates": { + "ht": "", + "at": "해적" + }, + "Pitch": { + "ht": "", + "at": "피치" + }, + "Polaris": { + "ht": "", + "at": "Polaris" + }, + "Power": { + "ht": "", + "at": "전원" + }, + "Power Draw": { + "ht": "", + "at": "전력 소모" + }, + "Power Output": { + "ht": "", + "at": "전력 출력" + }, + "Power Plants": { + "ht": "", + "at": "발전기" + }, + "Private Security": { + "ht": "", + "at": "민간 경비" + }, + "Probe": { + "ht": "", + "at": "탐사정" + }, + "Prospectors": { + "ht": "", + "at": "Prospector" + }, + "Protected": { + "ht": "", + "at": "보호 대상" + }, + "Proximity Range": { + "ht": "", + "at": "근접 신관 범위" + }, + "QD": { + "ht": "", + "at": "QD" + }, + "QT Fuel Use": { + "ht": "", + "at": "QT 연료 소모" + }, + "QT Speed": { + "ht": "", + "at": "QT 속도" + }, + "Quantum Drives": { + "ht": "", + "at": "양자 드라이브" + }, + "Quantum Enforcement Devices": { + "ht": "", + "at": "양자 차단 장치" + }, + "Radars": { + "ht": "", + "at": "레이더" + }, + "Ramp": { + "ht": "", + "at": "가동" + }, + "Range": { + "ht": "", + "at": "사거리" + }, + "Rank": { + "ht": "", + "at": "등급" + }, + "Recharges Oxygen reserves of a suit.": { + "ht": "", + "at": "슈트의 산소 비축량을 채운다." + }, + "Recipient": { + "ht": "", + "at": "수령인" + }, + "Reduces concussion symptoms, normalizes weapon handling and movement speed.": { + "ht": "", + "at": "뇌진탕 증상을 줄이고 무기 조작과 이동 속도를 정상으로 되돌린다." + }, + "Reduces injuries from radiation.": { + "ht": "", + "at": "방사선 부상을 줄인다." + }, + "Reduces pain symptoms, normalizes movement ability.": { + "ht": "", + "at": "통증 증상을 줄이고 이동 능력을 정상으로 되돌린다." + }, + "Reduces vision and hearing symptoms, normalizes stamina.": { + "ht": "", + "at": "시각과 청각 증상을 줄이고 지구력을 정상으로 되돌린다." + }, + "Refuel Nozzles": { + "ht": "", + "at": "급유 노즐" + }, + "Regen": { + "ht": "", + "at": "재생" + }, + "Reinforcements": { + "ht": "", + "at": "지원군" + }, + "Required": { + "ht": "", + "at": "필요" + }, + "Resource Signatures": { + "ht": "", + "at": "자원 신호" + }, + "Restores health and stops bleeding. When used on another person recovers from incapacitated state.": { + "ht": "", + "at": "체력을 회복하고 출혈을 멈춘다. 다른 사람에게 사용하면 무력화 상태에서 회복시킨다." + }, + "Revives an overdosed person (if not incapacitated), doubles decay rate of Blood Drug Level.": { + "ht": "", + "at": "약물 과다 복용자를 소생시킨다(무력화 상태가 아닐 때). 혈중 약물 농도 감소 속도를 두 배로 늘린다." + }, + "Risk": { + "ht": "", + "at": "위험" + }, + "Role": { + "ht": "", + "at": "역할" + }, + "Roll": { + "ht": "", + "at": "롤" + }, + "SCM": { + "ht": "", + "at": "SCM" + }, + "Salvageable Ships": { + "ht": "", + "at": "인양 가능한 함선" + }, + "Scanners": { + "ht": "", + "at": "스캐너" + }, + "Security Forces": { + "ht": "", + "at": "보안군" + }, + "Seeker": { + "ht": "", + "at": "탐색기" + }, + "Semi-Auto": { + "ht": "", + "at": "반자동" + }, + "Sentries": { + "ht": "", + "at": "보초" + }, + "Shields": { + "ht": "", + "at": "보호막" + }, + "Ship": { + "ht": "", + "at": "함선" + }, + "Ships to Defend": { + "ht": "", + "at": "방어할 함선" + }, + "Shotgun": { + "ht": "", + "at": "산탄" + }, + "Size": { + "ht": "", + "at": "크기" + }, + "Snipers": { + "ht": "", + "at": "저격수" + }, + "Soldiers": { + "ht": "", + "at": "병사" + }, + "Spool": { + "ht": "", + "at": "예열" + }, + "Standard": { + "ht": "", + "at": "일반" + }, + "Starter": { + "ht": "", + "at": "입문" + }, + "Stun": { + "ht": "", + "at": "기절" + }, + "Targets": { + "ht": "", + "at": "표적" + }, + "Technicians": { + "ht": "", + "at": "기술자" + }, + "Thermal": { + "ht": "", + "at": "열" + }, + "Tier": { + "ht": "", + "at": "단계" + }, + "Tracking": { + "ht": "", + "at": "추적" + }, + "Tracking Range": { + "ht": "", + "at": "추적 범위" + }, + "Turn Rate": { + "ht": "", + "at": "선회 속도" + }, + "Turrets": { + "ht": "", + "at": "포탑" + }, + "Unique": { + "ht": "", + "at": "1회 한정" + }, + "Used To Craft": { + "ht": "", + "at": "제작 용도" + }, + "Velocity": { + "ht": "", + "at": "속도" + }, + "Wear": { + "ht": "", + "at": "마모" + }, + "Weight": { + "ht": "", + "at": "무게" + }, + "Xeno Threat": { + "ht": "", + "at": "Xeno Threat" + }, + "Yaw": { + "ht": "", + "at": "요" + }, + "Yes": { + "ht": "", + "at": "예" + }, + "base": { + "ht": "", + "at": "기본" + }, + "down": { + "ht": "", + "at": "감속" + }, + "empty": { + "ht": "", + "at": "비어 있음" + }, + "express": { + "ht": "", + "at": "긴급" + }, + "friendly": { + "ht": "", + "at": "아군" + }, + "hostile": { + "ht": "", + "at": "적대" + }, + "present": { + "ht": "", + "at": "있음" + }, + "select variants": { + "ht": "", + "at": "일부 변형" + }, + "up": { + "ht": "", + "at": "가속" + }, + "{count} items": { + "ht": "", + "at": "아이템 {count}개" + }, + "{count} sets": { + "ht": "", + "at": "세트 {count}개" + }, + "{count} types": { + "ht": "", + "at": "{count}종" + }, + "{item} Set": { + "ht": "", + "at": "{item} 세트" + }, + "{pct}% chance": { + "ht": "", + "at": "{pct}% 확률" + }, + "{pct}% chance ({variants} only)": { + "ht": "", + "at": "{pct}% 확률({variants} 한정)" + }, + "{type} Ammo": { + "ht": "", + "at": "{type} 탄약" + } + } +} diff --git a/languages/korean/ui.json b/languages/korean/ui.json index 0e55b9ac..4664a81e 100644 --- a/languages/korean/ui.json +++ b/languages/korean/ui.json @@ -2286,6 +2286,10 @@ "ht": "", "at": "설정된 소스에서 {language} 현지화를 불러올 수 없었고, 캐시된 사본도 없습니다. 대신 영어 기본값을 표시합니다. 언어 파일 매핑의 URL 또는 파일을 확인한 후 다시 시도하세요." }, + "language_updated_status": { + "ht": "", + "at": "새 {language} 번역을 내려받았습니다. 다시 불러오는 중입니다." + }, "language_generating_enhancements": { "ht": "", "at": "DataForge에서 {language} 강화 생성 중…" diff --git a/languages/portuguese_br/HELP.md b/languages/portuguese_br/HELP.md index 0e7d4d69..ba96904c 100644 --- a/languages/portuguese_br/HELP.md +++ b/languages/portuguese_br/HELP.md @@ -118,7 +118,8 @@ Escolha um idioma no menu **Idioma** da aba **Config** (ao lado de Canal). A tro - **Inglês** (o padrão) usa as strings originais extraídas do seu próprio `Data.p4k`. - **Outros idiomas** baixam o `global.ini` traduzido pela comunidade para aquele idioma e o sobrepõem à base em inglês: qualquer string que a tradução não cobre cai de volta para o inglês em vez de sumir. O download fica em cache por idioma; voltar a um idioma já usado reaproveita o cache. -- **Os aprimoramentos continuam em inglês.** Blocos de estatísticas, tags e detalhes de missão são gerados a partir dos dados do jogo e mantêm a forma em inglês sobre a prosa traduzida. Uma linha mista (digamos, um nome de função em português dentro de um bloco de estatísticas em inglês) é esperada, não é um bug. +- **As melhorias seguem o seu idioma.** Os rótulos de estatísticas, os detalhes de missão e as linhas de diário que o Smart Citizen adiciona aparecem no idioma escolhido. Os nomes de itens vêm da própria tradução, e tags como `[BP]` e os títulos de seção das missões continuam como estão. +- **A tradução se mantém atualizada.** Sempre que o Smart Citizen inicia, ele verifica se há uma versão mais recente da tradução da comunidade e recarrega com ela, então uma correção feita após um patch do jogo chega até você sem trocar de idioma. - **Mapear Arquivo de Idioma** (aba Config) permite apontar um idioma para outro `global.ini`: uma URL (por exemplo o seu próprio fork de uma tradução da comunidade) ou, por **Procurar...**, um arquivo que você já tem no disco. Uma URL é baixada e guardada em cache, e um arquivo local é copiado. Nos dois casos ele vence o padrão incluído. Para um idioma cuja tradução da comunidade não pode ser redistribuída (por ex., o coreano), mapear um arquivo local é a única opção: instale primeiro o patch dessa comunidade, **copie o `global.ini` dele para um lugar fora da sua instalação do Star Citizen** (mapear a cópia que o Smart Citizen já aplica lá devolveria a própria saída mesclada como a próxima "fonte" e dobraria cada aprimoramento), e depois use Procurar para escolher essa cópia. - **Russo e coreano dividem o mesmo espaço de idioma do jogo.** O jogo não tem espaço para russo, e a fonte coreana é a única que exibe cirílico, então o russo é aplicado como o idioma coreano do jogo. Aplicar um substitui o arquivo do outro no jogo, e só o último aplicado aparece no jogo. - Alguns textos da interface só atualizam após reiniciar o app. As strings da tabela recarregam imediatamente. diff --git a/languages/portuguese_br/enhancements.json b/languages/portuguese_br/enhancements.json new file mode 100644 index 00000000..99fcf31e --- /dev/null +++ b/languages/portuguese_br/enhancements.json @@ -0,0 +1,833 @@ +{ + "_comment": "Translations of the text Smart Citizen adds to the game strings (stat labels, mission details, journal lines). Each key is the English text from languages/english/enhancements.json. 'ht' is a human translation and wins; 'at' is an AI draft. Keep each {placeholder} as it is.", + "strings": { + "--- EFFECT ---": { + "ht": "", + "at": "--- EFEITO ---" + }, + "--- STATS ---": { + "ht": "", + "at": "--- ESTATÍSTICAS ---" + }, + "Absolute Range": { + "ht": "", + "at": "Alcance absoluto" + }, + "Acceleration": { + "ht": "", + "at": "Aceleração" + }, + "Ace Pilot": { + "ht": "", + "at": "Piloto ás" + }, + "Ace Pilots": { + "ht": "", + "at": "Pilotos ases" + }, + "Aim Assist Range": { + "ht": "", + "at": "Alcance mira assist." + }, + "Alpha Dmg": { + "ht": "", + "at": "Dano alfa" + }, + "Ammo": { + "ht": "", + "at": "Munição" + }, + "Arm Dist": { + "ht": "", + "at": "Dist. armação" + }, + "Arm Time": { + "ht": "", + "at": "Tempo armação" + }, + "Armor HP": { + "ht": "", + "at": "PV blindagem" + }, + "Armour": { + "ht": "", + "at": "Armadura" + }, + "Attackers": { + "ht": "", + "at": "Atacantes" + }, + "Auto": { + "ht": "", + "at": "Auto" + }, + "Backup": { + "ht": "", + "at": "Reforços" + }, + "Bandits": { + "ht": "", + "at": "Bandidos" + }, + "Base Resource Signature": { + "ht": "", + "at": "Assinatura base do recurso" + }, + "Beam": { + "ht": "", + "at": "Feixe" + }, + "Bio": { + "ht": "", + "at": "Bio" + }, + "Blast Radius": { + "ht": "", + "at": "Raio de explosão" + }, + "Blueprint Reward": { + "ht": "", + "at": "Recompensa de projeto" + }, + "Bomb Slots": { + "ht": "", + "at": "Slots de bomba" + }, + "Boost": { + "ht": "", + "at": "Impulso" + }, + "Boss": { + "ht": "", + "at": "Chefe" + }, + "Burst": { + "ht": "", + "at": "Rajada" + }, + "CQC": { + "ht": "", + "at": "CQC" + }, + "Cal Rate": { + "ht": "", + "at": "Vel. calibr." + }, + "Captain": { + "ht": "", + "at": "Capitão" + }, + "Chain": { + "ht": "", + "at": "Cadeia" + }, + "Charge": { + "ht": "", + "at": "Carga" + }, + "Civilians": { + "ht": "", + "at": "Civis" + }, + "Class": { + "ht": "", + "at": "Classe" + }, + "Combat": { + "ht": "", + "at": "Combate" + }, + "Complexity": { + "ht": "", + "at": "Complexidade" + }, + "Component HP": { + "ht": "", + "at": "PV do componente" + }, + "Cooldown": { + "ht": "", + "at": "Recarga" + }, + "Coolers": { + "ht": "", + "at": "Resfriadores" + }, + "Cooling Rate": { + "ht": "", + "at": "Taxa de resfriamento" + }, + "Cost/Shot": { + "ht": "", + "at": "Custo/tiro" + }, + "Crew": { + "ht": "", + "at": "Tripulação" + }, + "DPS": { + "ht": "", + "at": "DPS" + }, + "Damage": { + "ht": "", + "at": "Dano" + }, + "Damage-Map Rate": { + "ht": "", + "at": "Taxa mapa de danos" + }, + "Damaged Delay": { + "ht": "", + "at": "Atraso se danificado" + }, + "Defenders": { + "ht": "", + "at": "Defensores" + }, + "Deflect": { + "ht": "", + "at": "Deflexão" + }, + "Detection Mode": { + "ht": "", + "at": "Modo de detecção" + }, + "Detonation": { + "ht": "", + "at": "Detonação" + }, + "Difficulty (1-7)": { + "ht": "", + "at": "Dificuldade (1-7)" + }, + "Distort": { + "ht": "", + "at": "Distorç." + }, + "Dmg Mult": { + "ht": "", + "at": "Mult. dano" + }, + "Downed Delay": { + "ht": "", + "at": "Atraso se abatido" + }, + "Drop": { + "ht": "", + "at": "Queda" + }, + "EM": { + "ht": "", + "at": "EM" + }, + "EM Signature": { + "ht": "", + "at": "Assinatura EM" + }, + "Effective Range": { + "ht": "", + "at": "Alcance efetivo" + }, + "Energy": { + "ht": "", + "at": "Energia" + }, + "Engagement Type": { + "ht": "", + "at": "Tipo de combate" + }, + "Escort Wings": { + "ht": "", + "at": "Esquadrilhas de escolta" + }, + "Escorts": { + "ht": "", + "at": "Escoltas" + }, + "Extraction": { + "ht": "", + "at": "Extração" + }, + "FPS": { + "ht": "", + "at": "FPS" + }, + "FPS & Ship": { + "ht": "", + "at": "FPS e nave" + }, + "Failure": { + "ht": "", + "at": "Falha" + }, + "Failure Penalty": { + "ht": "", + "at": "Penalidade por falha" + }, + "Fire Modes": { + "ht": "", + "at": "Modos de disparo" + }, + "Fire Rate": { + "ht": "", + "at": "Cadência" + }, + "Fracture": { + "ht": "", + "at": "Fratura" + }, + "Friendlies": { + "ht": "", + "at": "Aliados" + }, + "Fuel": { + "ht": "", + "at": "Combustível" + }, + "Fuel/Gm": { + "ht": "", + "at": "Combustível/Gm" + }, + "Full Dmg to": { + "ht": "", + "at": "Dano total até" + }, + "Grade": { + "ht": "", + "at": "Grau" + }, + "Grunts": { + "ht": "", + "at": "Capangas" + }, + "Guaranteed": { + "ht": "", + "at": "Garantido" + }, + "Guards": { + "ht": "", + "at": "Guardas" + }, + "Guidance": { + "ht": "", + "at": "Guiagem" + }, + "Guns": { + "ht": "", + "at": "Canhões" + }, + "HP Rate": { + "ht": "", + "at": "Taxa de PV" + }, + "HP/Ammo": { + "ht": "", + "at": "PV/munição" + }, + "Heat": { + "ht": "", + "at": "Calor" + }, + "Heist Target": { + "ht": "", + "at": "Alvo do assalto" + }, + "Hostages": { + "ht": "", + "at": "Reféns" + }, + "Hostile Allies": { + "ht": "", + "at": "Aliados hostis" + }, + "Hostile Wave": { + "ht": "", + "at": "Onda hostil" + }, + "Hostiles": { + "ht": "", + "at": "Hostis" + }, + "IR": { + "ht": "", + "at": "IV" + }, + "IR Signature": { + "ht": "", + "at": "Assinatura IV" + }, + "Inert Filter": { + "ht": "", + "at": "Filtro inerte" + }, + "Insurance": { + "ht": "", + "at": "Seguro" + }, + "Interdiction Ships": { + "ht": "", + "at": "Naves de interdição" + }, + "Item Type": { + "ht": "", + "at": "Tipo de item" + }, + "Juggernauts": { + "ht": "", + "at": "Juggernauts" + }, + "Jump Drives": { + "ht": "", + "at": "Motores de salto" + }, + "Knowledge": { + "ht": "", + "at": "Conhecimento" + }, + "Kopions": { + "ht": "", + "at": "Kopions" + }, + "Length": { + "ht": "", + "at": "Comprimento" + }, + "Lifetime": { + "ht": "", + "at": "Duração" + }, + "Locations": { + "ht": "", + "at": "Locais" + }, + "Lock Range": { + "ht": "", + "at": "Alcance de trava" + }, + "Lock Time": { + "ht": "", + "at": "Tempo de trava" + }, + "MRacks": { + "ht": "", + "at": "Lança-mísseis" + }, + "Material Efficiency": { + "ht": "", + "at": "Eficiência de material" + }, + "Maulers": { + "ht": "", + "at": "Maulers" + }, + "Max": { + "ht": "", + "at": "Máx." + }, + "Max Distortion": { + "ht": "", + "at": "Distorção máx." + }, + "Max G-Force": { + "ht": "", + "at": "Força G máx." + }, + "Max HP": { + "ht": "", + "at": "PV máx." + }, + "Max Lifetime": { + "ht": "", + "at": "Duração máx." + }, + "Max Lock Range": { + "ht": "", + "at": "Alcance trava máx." + }, + "Min Detonate": { + "ht": "", + "at": "Detonação mín." + }, + "Min Dmg": { + "ht": "", + "at": "Dano mín." + }, + "Min Lock Range": { + "ht": "", + "at": "Alcance trava mín." + }, + "Mission Type": { + "ht": "", + "at": "Tipo de missão" + }, + "Nine Tails": { + "ht": "", + "at": "Nine Tails" + }, + "Objectives": { + "ht": "", + "at": "Objetivos" + }, + "Overheat Temp": { + "ht": "", + "at": "Temp. superaquec." + }, + "Phys": { + "ht": "", + "at": "Fís." + }, + "Ping Cooldown": { + "ht": "", + "at": "Recarga do ping" + }, + "Pirates": { + "ht": "", + "at": "Piratas" + }, + "Pitch": { + "ht": "", + "at": "Arfagem" + }, + "Polaris": { + "ht": "", + "at": "Polaris" + }, + "Power": { + "ht": "", + "at": "Energia" + }, + "Power Draw": { + "ht": "", + "at": "Consumo" + }, + "Power Output": { + "ht": "", + "at": "Geração de energia" + }, + "Power Plants": { + "ht": "", + "at": "Geradores" + }, + "Private Security": { + "ht": "", + "at": "Segurança privada" + }, + "Probe": { + "ht": "", + "at": "Sonda" + }, + "Prospectors": { + "ht": "", + "at": "Prospectors" + }, + "Protected": { + "ht": "", + "at": "Protegidos" + }, + "Proximity Range": { + "ht": "", + "at": "Alcance de proximidade" + }, + "QD": { + "ht": "", + "at": "MQ" + }, + "QT Fuel Use": { + "ht": "", + "at": "Consumo QT" + }, + "QT Speed": { + "ht": "", + "at": "Velocidade QT" + }, + "Quantum Drives": { + "ht": "", + "at": "Motores quânticos" + }, + "Quantum Enforcement Devices": { + "ht": "", + "at": "Dispositivos de interdição quântica" + }, + "Radars": { + "ht": "", + "at": "Radares" + }, + "Ramp": { + "ht": "", + "at": "Rampa" + }, + "Range": { + "ht": "", + "at": "Alcance" + }, + "Rank": { + "ht": "", + "at": "Patente" + }, + "Recharges Oxygen reserves of a suit.": { + "ht": "", + "at": "Recarrega as reservas de oxigênio de um traje." + }, + "Recipient": { + "ht": "", + "at": "Destinatário" + }, + "Reduces concussion symptoms, normalizes weapon handling and movement speed.": { + "ht": "", + "at": "Reduz sintomas de concussão, normaliza o manuseio de armas e a velocidade de movimento." + }, + "Reduces injuries from radiation.": { + "ht": "", + "at": "Reduz lesões por radiação." + }, + "Reduces pain symptoms, normalizes movement ability.": { + "ht": "", + "at": "Reduz a dor, normaliza a capacidade de movimento." + }, + "Reduces vision and hearing symptoms, normalizes stamina.": { + "ht": "", + "at": "Reduz distúrbios de visão e audição, normaliza a resistência." + }, + "Refuel Nozzles": { + "ht": "", + "at": "Bicos de reabastecimento" + }, + "Regen": { + "ht": "", + "at": "Regen." + }, + "Reinforcements": { + "ht": "", + "at": "Reforços" + }, + "Required": { + "ht": "", + "at": "Necessário" + }, + "Resource Signatures": { + "ht": "", + "at": "Assinaturas de recursos" + }, + "Restores health and stops bleeding. When used on another person recovers from incapacitated state.": { + "ht": "", + "at": "Restaura a saúde e estanca sangramentos. Usado em outra pessoa, recupera-a da incapacitação." + }, + "Revives an overdosed person (if not incapacitated), doubles decay rate of Blood Drug Level.": { + "ht": "", + "at": "Reanima uma pessoa com overdose (se não incapacitada), dobra a queda do nível de droga no sangue." + }, + "Risk": { + "ht": "", + "at": "Risco" + }, + "Role": { + "ht": "", + "at": "Função" + }, + "Roll": { + "ht": "", + "at": "Rolagem" + }, + "SCM": { + "ht": "", + "at": "SCM" + }, + "Salvageable Ships": { + "ht": "", + "at": "Naves recuperáveis" + }, + "Scanners": { + "ht": "", + "at": "Scanners" + }, + "Security Forces": { + "ht": "", + "at": "Forças de segurança" + }, + "Seeker": { + "ht": "", + "at": "Buscador" + }, + "Semi-Auto": { + "ht": "", + "at": "Semiauto" + }, + "Sentries": { + "ht": "", + "at": "Sentinelas" + }, + "Shields": { + "ht": "", + "at": "Escudos" + }, + "Ship": { + "ht": "", + "at": "Nave" + }, + "Ships to Defend": { + "ht": "", + "at": "Naves a defender" + }, + "Shotgun": { + "ht": "", + "at": "Espingarda" + }, + "Size": { + "ht": "", + "at": "Tamanho" + }, + "Snipers": { + "ht": "", + "at": "Atiradores" + }, + "Soldiers": { + "ht": "", + "at": "Soldados" + }, + "Spool": { + "ht": "", + "at": "Aquecimento" + }, + "Standard": { + "ht": "", + "at": "Padrão" + }, + "Starter": { + "ht": "", + "at": "Inicial" + }, + "Stun": { + "ht": "", + "at": "Atord." + }, + "Targets": { + "ht": "", + "at": "Alvos" + }, + "Technicians": { + "ht": "", + "at": "Técnicos" + }, + "Thermal": { + "ht": "", + "at": "Térmico" + }, + "Tier": { + "ht": "", + "at": "Nível" + }, + "Tracking": { + "ht": "", + "at": "Rastreamento" + }, + "Tracking Range": { + "ht": "", + "at": "Alcance de rastreamento" + }, + "Turn Rate": { + "ht": "", + "at": "Vel. de curva" + }, + "Turrets": { + "ht": "", + "at": "Torretas" + }, + "Unique": { + "ht": "", + "at": "Única" + }, + "Used To Craft": { + "ht": "", + "at": "Usado para fabricar" + }, + "Velocity": { + "ht": "", + "at": "Velocidade" + }, + "Wear": { + "ht": "", + "at": "Desgaste" + }, + "Weight": { + "ht": "", + "at": "Peso" + }, + "Xeno Threat": { + "ht": "", + "at": "Xeno Threat" + }, + "Yaw": { + "ht": "", + "at": "Guinada" + }, + "Yes": { + "ht": "", + "at": "Sim" + }, + "base": { + "ht": "", + "at": "base" + }, + "down": { + "ht": "", + "at": "descida" + }, + "empty": { + "ht": "", + "at": "vazio" + }, + "express": { + "ht": "", + "at": "expresso" + }, + "friendly": { + "ht": "", + "at": "amigáveis" + }, + "hostile": { + "ht": "", + "at": "hostis" + }, + "present": { + "ht": "", + "at": "presentes" + }, + "select variants": { + "ht": "", + "at": "algumas variantes" + }, + "up": { + "ht": "", + "at": "subida" + }, + "{count} items": { + "ht": "", + "at": "{count} itens" + }, + "{count} sets": { + "ht": "", + "at": "{count} conjuntos" + }, + "{count} types": { + "ht": "", + "at": "{count} tipos" + }, + "{item} Set": { + "ht": "", + "at": "Conjunto {item}" + }, + "{pct}% chance": { + "ht": "", + "at": "{pct}% de chance" + }, + "{pct}% chance ({variants} only)": { + "ht": "", + "at": "{pct}% de chance (só {variants})" + }, + "{type} Ammo": { + "ht": "", + "at": "Munição {type}" + } + } +} diff --git a/languages/portuguese_br/ui.json b/languages/portuguese_br/ui.json index e1dabdc6..17ad822c 100644 --- a/languages/portuguese_br/ui.json +++ b/languages/portuguese_br/ui.json @@ -2286,6 +2286,10 @@ "ht": "", "at": "Não foi possível carregar a localização {language} a partir da fonte configurada, e nenhuma cópia em cache foi encontrada. Exibindo a base em inglês. Verifique a URL ou o arquivo em Mapear Arquivo de Idioma e tente novamente." }, + "language_updated_status": { + "ht": "", + "at": "Uma tradução {language} mais recente foi baixada. Recarregando com ela." + }, "language_generating_enhancements": { "ht": "", "at": "Gerando aprimoramentos {language} a partir do DataForge…" diff --git a/languages/russian/HELP.md b/languages/russian/HELP.md index da03e0a8..eab4d56b 100644 --- a/languages/russian/HELP.md +++ b/languages/russian/HELP.md @@ -116,7 +116,8 @@ Smart Citizen также наносит небольшой водяной зна - **English** (по умолчанию) использует стандартные строки, извлечённые из вашего `Data.p4k`. - **Другие языки** загружают переведённый сообществом `global.ini` для этого языка и накладывают его на английскую основу, поэтому любая строка, не покрытая переводом, возвращается к английскому варианту вместо отсутствия. Загрузка кэшируется по языкам; при повторном переключении используется кэш. -- **Улучшения остаются на английском.** Блоки характеристик, теги и детали миссий генерируются из игровых данных и сохраняют английскую форму поверх переведённого текста. Смешанная строка (например, название роли на французском внутри англоязычного блока характеристик) — ожидаемое поведение, а не ошибка. +- **Улучшения следуют вашему языку.** Названия характеристик, подробности миссий и строки журнала, которые добавляет Smart Citizen, выводятся на выбранном языке. Названия предметов берутся из самого перевода, а теги вроде `[BP]` и заголовки разделов миссий остаются как есть. +- **Перевод остаётся актуальным.** При каждом запуске Smart Citizen проверяет, нет ли более новой версии перевода сообщества, и перезагружается с ней, так что исправление после патча игры доходит до вас без смены языка. - **Сопоставить файл языка** (вкладка «Настройки») позволяет указать для языка другой `global.ini` — URL (например, ваш форк перевода сообщества) или, через **Обзор...**, файл, уже имеющийся на диске. URL загружается и кэшируется; локальный файл копируется. В обоих случаях он имеет приоритет над встроенным по умолчанию. Для языков, перевод которых не может быть распространён (например, корейский), сопоставление локального файла — единственный вариант — сначала установите патч этого сообщества, **скопируйте его `global.ini` в место, отличное от установки Star Citizen** (сопоставление копии, которую Smart Citizen уже применяет там, приведёт к обратной связи собственного объединённого результата в качестве следующего «источника» и удвоению каждого улучшения), затем выберите эту копию через «Обзор...». - **Русский и корейский используют один языковой слот игры.** В игре нет слота для русского языка, а корейский шрифт — единственный, который отображает кириллицу, поэтому русский применяется как корейский язык игры. Применение одного языка заменяет в игре файл другого, и в игре отображается только тот, который вы применили последним. - Некоторые тексты интерфейса обновляются только после перезапуска приложения. Строки таблицы перезагружаются немедленно. diff --git a/languages/russian/enhancements.json b/languages/russian/enhancements.json new file mode 100644 index 00000000..2266cf06 --- /dev/null +++ b/languages/russian/enhancements.json @@ -0,0 +1,833 @@ +{ + "_comment": "Translations of the text Smart Citizen adds to the game strings (stat labels, mission details, journal lines). Each key is the English text from languages/english/enhancements.json. 'ht' is a human translation and wins; 'at' is an AI draft. Keep each {placeholder} as it is.", + "strings": { + "--- EFFECT ---": { + "ht": "", + "at": "--- ЭФФЕКТ ---" + }, + "--- STATS ---": { + "ht": "", + "at": "--- ХАРАКТЕРИСТИКИ ---" + }, + "Absolute Range": { + "ht": "", + "at": "Предельная дальность" + }, + "Acceleration": { + "ht": "", + "at": "Ускорение" + }, + "Ace Pilot": { + "ht": "", + "at": "Ас" + }, + "Ace Pilots": { + "ht": "", + "at": "Асы" + }, + "Aim Assist Range": { + "ht": "", + "at": "Дальность помощи прицел." + }, + "Alpha Dmg": { + "ht": "", + "at": "Урон залпа" + }, + "Ammo": { + "ht": "", + "at": "Боезапас" + }, + "Arm Dist": { + "ht": "", + "at": "Дист. взвода" + }, + "Arm Time": { + "ht": "", + "at": "Время взвода" + }, + "Armor HP": { + "ht": "", + "at": "ОЗ брони" + }, + "Armour": { + "ht": "", + "at": "Броня" + }, + "Attackers": { + "ht": "", + "at": "Нападающие" + }, + "Auto": { + "ht": "", + "at": "Авто" + }, + "Backup": { + "ht": "", + "at": "Подкрепление" + }, + "Bandits": { + "ht": "", + "at": "Бандиты" + }, + "Base Resource Signature": { + "ht": "", + "at": "Базовая сигнатура ресурса" + }, + "Beam": { + "ht": "", + "at": "Луч" + }, + "Bio": { + "ht": "", + "at": "Био" + }, + "Blast Radius": { + "ht": "", + "at": "Радиус взрыва" + }, + "Blueprint Reward": { + "ht": "", + "at": "Чертёж в награду" + }, + "Bomb Slots": { + "ht": "", + "at": "Слоты бомб" + }, + "Boost": { + "ht": "", + "at": "Форсаж" + }, + "Boss": { + "ht": "", + "at": "Босс" + }, + "Burst": { + "ht": "", + "at": "Очередь" + }, + "CQC": { + "ht": "", + "at": "Ближний бой" + }, + "Cal Rate": { + "ht": "", + "at": "Скор. калибр." + }, + "Captain": { + "ht": "", + "at": "Капитан" + }, + "Chain": { + "ht": "", + "at": "Цепочка" + }, + "Charge": { + "ht": "", + "at": "Заряд" + }, + "Civilians": { + "ht": "", + "at": "Гражданские" + }, + "Class": { + "ht": "", + "at": "Класс" + }, + "Combat": { + "ht": "", + "at": "Бой" + }, + "Complexity": { + "ht": "", + "at": "Сложность" + }, + "Component HP": { + "ht": "", + "at": "ОЗ компонента" + }, + "Cooldown": { + "ht": "", + "at": "Перезарядка" + }, + "Coolers": { + "ht": "", + "at": "Охладители" + }, + "Cooling Rate": { + "ht": "", + "at": "Скорость охлаждения" + }, + "Cost/Shot": { + "ht": "", + "at": "Расход/выстрел" + }, + "Crew": { + "ht": "", + "at": "Экипаж" + }, + "DPS": { + "ht": "", + "at": "УВС" + }, + "Damage": { + "ht": "", + "at": "Урон" + }, + "Damage-Map Rate": { + "ht": "", + "at": "Скорость карты повреждений" + }, + "Damaged Delay": { + "ht": "", + "at": "Задержка при уроне" + }, + "Defenders": { + "ht": "", + "at": "Защитники" + }, + "Deflect": { + "ht": "", + "at": "Отражение" + }, + "Detection Mode": { + "ht": "", + "at": "Режим обнаружения" + }, + "Detonation": { + "ht": "", + "at": "Детонация" + }, + "Difficulty (1-7)": { + "ht": "", + "at": "Сложность (1-7)" + }, + "Distort": { + "ht": "", + "at": "Искаж." + }, + "Dmg Mult": { + "ht": "", + "at": "Множ. урона" + }, + "Downed Delay": { + "ht": "", + "at": "Задержка при отказе" + }, + "Drop": { + "ht": "", + "at": "Спад" + }, + "EM": { + "ht": "", + "at": "ЭМ" + }, + "EM Signature": { + "ht": "", + "at": "ЭМ-сигнатура" + }, + "Effective Range": { + "ht": "", + "at": "Эффективная дальность" + }, + "Energy": { + "ht": "", + "at": "Энергия" + }, + "Engagement Type": { + "ht": "", + "at": "Тип боя" + }, + "Escort Wings": { + "ht": "", + "at": "Звенья сопровождения" + }, + "Escorts": { + "ht": "", + "at": "Сопровождение" + }, + "Extraction": { + "ht": "", + "at": "Извлечение" + }, + "FPS": { + "ht": "", + "at": "Пеший бой" + }, + "FPS & Ship": { + "ht": "", + "at": "Пеший бой и корабль" + }, + "Failure": { + "ht": "", + "at": "Провал" + }, + "Failure Penalty": { + "ht": "", + "at": "Штраф за провал" + }, + "Fire Modes": { + "ht": "", + "at": "Режимы огня" + }, + "Fire Rate": { + "ht": "", + "at": "Скорострельность" + }, + "Fracture": { + "ht": "", + "at": "Раскол" + }, + "Friendlies": { + "ht": "", + "at": "Союзники" + }, + "Fuel": { + "ht": "", + "at": "Топливо" + }, + "Fuel/Gm": { + "ht": "", + "at": "Топливо/Гм" + }, + "Full Dmg to": { + "ht": "", + "at": "Полный урон до" + }, + "Grade": { + "ht": "", + "at": "Класс кач." + }, + "Grunts": { + "ht": "", + "at": "Рядовые" + }, + "Guaranteed": { + "ht": "", + "at": "Гарантирован" + }, + "Guards": { + "ht": "", + "at": "Охрана" + }, + "Guidance": { + "ht": "", + "at": "Наведение" + }, + "Guns": { + "ht": "", + "at": "Орудия" + }, + "HP Rate": { + "ht": "", + "at": "Скорость ОЗ" + }, + "HP/Ammo": { + "ht": "", + "at": "ОЗ/заряд" + }, + "Heat": { + "ht": "", + "at": "Нагрев" + }, + "Heist Target": { + "ht": "", + "at": "Цель ограбления" + }, + "Hostages": { + "ht": "", + "at": "Заложники" + }, + "Hostile Allies": { + "ht": "", + "at": "Враждебные союзники" + }, + "Hostile Wave": { + "ht": "", + "at": "Вражеская волна" + }, + "Hostiles": { + "ht": "", + "at": "Враги" + }, + "IR": { + "ht": "", + "at": "ИК" + }, + "IR Signature": { + "ht": "", + "at": "ИК-сигнатура" + }, + "Inert Filter": { + "ht": "", + "at": "Фильтр инертных" + }, + "Insurance": { + "ht": "", + "at": "Страховка" + }, + "Interdiction Ships": { + "ht": "", + "at": "Корабли перехвата" + }, + "Item Type": { + "ht": "", + "at": "Тип предмета" + }, + "Juggernauts": { + "ht": "", + "at": "Джаггернауты" + }, + "Jump Drives": { + "ht": "", + "at": "Прыжковые двигатели" + }, + "Knowledge": { + "ht": "", + "at": "Знания" + }, + "Kopions": { + "ht": "", + "at": "Копионы" + }, + "Length": { + "ht": "", + "at": "Длина" + }, + "Lifetime": { + "ht": "", + "at": "Время жизни" + }, + "Locations": { + "ht": "", + "at": "Места" + }, + "Lock Range": { + "ht": "", + "at": "Дальность захвата" + }, + "Lock Time": { + "ht": "", + "at": "Время захвата" + }, + "MRacks": { + "ht": "", + "at": "Ракетные пилоны" + }, + "Material Efficiency": { + "ht": "", + "at": "Эффективность материала" + }, + "Maulers": { + "ht": "", + "at": "Maulers" + }, + "Max": { + "ht": "", + "at": "Макс." + }, + "Max Distortion": { + "ht": "", + "at": "Макс. искажение" + }, + "Max G-Force": { + "ht": "", + "at": "Макс. перегрузка" + }, + "Max HP": { + "ht": "", + "at": "Макс. ОЗ" + }, + "Max Lifetime": { + "ht": "", + "at": "Макс. срок службы" + }, + "Max Lock Range": { + "ht": "", + "at": "Макс. дальн. захвата" + }, + "Min Detonate": { + "ht": "", + "at": "Мин. дист. подрыва" + }, + "Min Dmg": { + "ht": "", + "at": "Мин. урон" + }, + "Min Lock Range": { + "ht": "", + "at": "Мин. дальн. захвата" + }, + "Mission Type": { + "ht": "", + "at": "Тип миссии" + }, + "Nine Tails": { + "ht": "", + "at": "Nine Tails" + }, + "Objectives": { + "ht": "", + "at": "Цели" + }, + "Overheat Temp": { + "ht": "", + "at": "Темп. перегрева" + }, + "Phys": { + "ht": "", + "at": "Физ." + }, + "Ping Cooldown": { + "ht": "", + "at": "Перезарядка пинга" + }, + "Pirates": { + "ht": "", + "at": "Пираты" + }, + "Pitch": { + "ht": "", + "at": "Тангаж" + }, + "Polaris": { + "ht": "", + "at": "Polaris" + }, + "Power": { + "ht": "", + "at": "Энергия" + }, + "Power Draw": { + "ht": "", + "at": "Потребление" + }, + "Power Output": { + "ht": "", + "at": "Выработка энергии" + }, + "Power Plants": { + "ht": "", + "at": "Генераторы" + }, + "Private Security": { + "ht": "", + "at": "Частная охрана" + }, + "Probe": { + "ht": "", + "at": "Зонд" + }, + "Prospectors": { + "ht": "", + "at": "Prospectors" + }, + "Protected": { + "ht": "", + "at": "Охраняемые" + }, + "Proximity Range": { + "ht": "", + "at": "Дальность взрывателя" + }, + "QD": { + "ht": "", + "at": "КД" + }, + "QT Fuel Use": { + "ht": "", + "at": "Расход QT" + }, + "QT Speed": { + "ht": "", + "at": "Скорость QT" + }, + "Quantum Drives": { + "ht": "", + "at": "Квантовые двигатели" + }, + "Quantum Enforcement Devices": { + "ht": "", + "at": "Квантовые блокираторы" + }, + "Radars": { + "ht": "", + "at": "Радары" + }, + "Ramp": { + "ht": "", + "at": "Разгон" + }, + "Range": { + "ht": "", + "at": "Дальность" + }, + "Rank": { + "ht": "", + "at": "Ранг" + }, + "Recharges Oxygen reserves of a suit.": { + "ht": "", + "at": "Восполняет запас кислорода в скафандре." + }, + "Recipient": { + "ht": "", + "at": "Получатель" + }, + "Reduces concussion symptoms, normalizes weapon handling and movement speed.": { + "ht": "", + "at": "Снимает симптомы сотрясения, восстанавливает обращение с оружием и скорость движения." + }, + "Reduces injuries from radiation.": { + "ht": "", + "at": "Снижает лучевые поражения." + }, + "Reduces pain symptoms, normalizes movement ability.": { + "ht": "", + "at": "Снимает боль, восстанавливает подвижность." + }, + "Reduces vision and hearing symptoms, normalizes stamina.": { + "ht": "", + "at": "Снимает нарушения зрения и слуха, восстанавливает выносливость." + }, + "Refuel Nozzles": { + "ht": "", + "at": "Заправочные насадки" + }, + "Regen": { + "ht": "", + "at": "Регенерация" + }, + "Reinforcements": { + "ht": "", + "at": "Подкрепление" + }, + "Required": { + "ht": "", + "at": "Требуется" + }, + "Resource Signatures": { + "ht": "", + "at": "Сигнатуры ресурсов" + }, + "Restores health and stops bleeding. When used on another person recovers from incapacitated state.": { + "ht": "", + "at": "Восстанавливает здоровье и останавливает кровотечение. Применённое к другому человеку, выводит его из недееспособности." + }, + "Revives an overdosed person (if not incapacitated), doubles decay rate of Blood Drug Level.": { + "ht": "", + "at": "Оживляет человека с передозировкой (если он не недееспособен), вдвое ускоряет снижение уровня препарата в крови." + }, + "Risk": { + "ht": "", + "at": "Риск" + }, + "Role": { + "ht": "", + "at": "Роль" + }, + "Roll": { + "ht": "", + "at": "Крен" + }, + "SCM": { + "ht": "", + "at": "SCM" + }, + "Salvageable Ships": { + "ht": "", + "at": "Корабли на разбор" + }, + "Scanners": { + "ht": "", + "at": "Сканеры" + }, + "Security Forces": { + "ht": "", + "at": "Силы безопасности" + }, + "Seeker": { + "ht": "", + "at": "ГСН" + }, + "Semi-Auto": { + "ht": "", + "at": "Полуавтомат" + }, + "Sentries": { + "ht": "", + "at": "Часовые" + }, + "Shields": { + "ht": "", + "at": "Щиты" + }, + "Ship": { + "ht": "", + "at": "Корабль" + }, + "Ships to Defend": { + "ht": "", + "at": "Защищаемые корабли" + }, + "Shotgun": { + "ht": "", + "at": "Дробовик" + }, + "Size": { + "ht": "", + "at": "Размер" + }, + "Snipers": { + "ht": "", + "at": "Снайперы" + }, + "Soldiers": { + "ht": "", + "at": "Солдаты" + }, + "Spool": { + "ht": "", + "at": "Раскрутка" + }, + "Standard": { + "ht": "", + "at": "Обычная" + }, + "Starter": { + "ht": "", + "at": "Стартовая" + }, + "Stun": { + "ht": "", + "at": "Оглуш." + }, + "Targets": { + "ht": "", + "at": "Цели" + }, + "Technicians": { + "ht": "", + "at": "Техники" + }, + "Thermal": { + "ht": "", + "at": "Терм." + }, + "Tier": { + "ht": "", + "at": "Уровень" + }, + "Tracking": { + "ht": "", + "at": "Отслеживание" + }, + "Tracking Range": { + "ht": "", + "at": "Дальность сопровождения" + }, + "Turn Rate": { + "ht": "", + "at": "Скорость поворота" + }, + "Turrets": { + "ht": "", + "at": "Турели" + }, + "Unique": { + "ht": "", + "at": "Уникальная" + }, + "Used To Craft": { + "ht": "", + "at": "Используется для" + }, + "Velocity": { + "ht": "", + "at": "Скорость" + }, + "Wear": { + "ht": "", + "at": "Износ" + }, + "Weight": { + "ht": "", + "at": "Вес" + }, + "Xeno Threat": { + "ht": "", + "at": "Xeno Threat" + }, + "Yaw": { + "ht": "", + "at": "Рыскание" + }, + "Yes": { + "ht": "", + "at": "Да" + }, + "base": { + "ht": "", + "at": "базовая" + }, + "down": { + "ht": "", + "at": "спад" + }, + "empty": { + "ht": "", + "at": "пусто" + }, + "express": { + "ht": "", + "at": "экспресс" + }, + "friendly": { + "ht": "", + "at": "дружественные" + }, + "hostile": { + "ht": "", + "at": "враждебные" + }, + "present": { + "ht": "", + "at": "есть" + }, + "select variants": { + "ht": "", + "at": "отдельные варианты" + }, + "up": { + "ht": "", + "at": "разгон" + }, + "{count} items": { + "ht": "", + "at": "{count} шт." + }, + "{count} sets": { + "ht": "", + "at": "{count} комплектов" + }, + "{count} types": { + "ht": "", + "at": "{count} типов" + }, + "{item} Set": { + "ht": "", + "at": "Комплект {item}" + }, + "{pct}% chance": { + "ht": "", + "at": "шанс {pct}%" + }, + "{pct}% chance ({variants} only)": { + "ht": "", + "at": "шанс {pct}% (только {variants})" + }, + "{type} Ammo": { + "ht": "", + "at": "Боеприпасы {type}" + } + } +} diff --git a/languages/russian/ui.json b/languages/russian/ui.json index 3d7cebe3..476efb27 100644 --- a/languages/russian/ui.json +++ b/languages/russian/ui.json @@ -2286,6 +2286,10 @@ "ht": "", "at": "Не удалось загрузить локализацию {language} из настроенного источника, и кэшированная копия не найдена. Отображается английская база. Проверьте URL или файл в «Сопоставить файл языка» и попробуйте снова." }, + "language_updated_status": { + "ht": "", + "at": "Загружен более новый перевод ({language}). Перезагрузка с ним." + }, "language_generating_enhancements": { "ht": "", "at": "Генерация улучшений {language} из DataForge…" diff --git a/languages/spanish/HELP.md b/languages/spanish/HELP.md index 80325c0d..b8028717 100644 --- a/languages/spanish/HELP.md +++ b/languages/spanish/HELP.md @@ -118,7 +118,8 @@ Elige un idioma en el menú **Idioma** de la pestaña **Configuración** (junto - **Inglés** (el predeterminado) usa los textos originales extraídos de tu propio `Data.p4k`. - **Los demás idiomas** descargan el `global.ini` traducido por la comunidad para ese idioma y lo superponen a la base en inglés: cualquier texto que la traducción no cubra vuelve al inglés en lugar de desaparecer. La descarga se guarda en caché por idioma; volver a un idioma ya usado reutiliza la caché. -- **Las mejoras permanecen en inglés.** Los bloques de estadísticas, etiquetas y detalles de misión se generan a partir de los datos del juego y mantienen su forma en inglés sobre la prosa traducida. Una línea mixta (por ejemplo, un nombre de rol en español dentro de un bloque de estadísticas en inglés) es lo esperado, no un error. +- **Las mejoras siguen tu idioma.** Las etiquetas de estadísticas, los detalles de misión y las líneas de diario que añade Smart Citizen se muestran en el idioma elegido. Los nombres de objetos vienen de la propia traducción, y las etiquetas como `[BP]` y los títulos de sección de las misiones se quedan como están. +- **La traducción se mantiene al día.** Cada vez que Smart Citizen se inicia, comprueba si hay una versión más reciente de la traducción de la comunidad y recarga con ella, así una corrección tras un parche del juego te llega sin cambiar de idioma. - **Asignar archivo de idioma** (pestaña Configuración) permite apuntar un idioma a otro `global.ini`: una URL (por ejemplo tu propio fork de una traducción comunitaria) o, mediante **Examinar...**, un archivo que ya tengas en el disco. Una URL se descarga y se guarda en caché, y un archivo local se copia. En ambos casos gana sobre la predeterminada incluida. Para un idioma cuya traducción comunitaria no se puede redistribuir (p. ej. el coreano), asignar un archivo local es la única opción: instala primero el parche de esa comunidad, **copia su `global.ini` a un lugar que no sea tu instalación de Star Citizen** (asignar la copia que Smart Citizen ya aplica allí devolvería su propia salida combinada como la siguiente «fuente» y duplicaría cada mejora), y luego usa Examinar para elegir esa copia. - **El ruso y el coreano comparten una misma ranura de idioma del juego.** El juego no tiene ranura para el ruso y su fuente coreana es la única que muestra el cirílico, así que el ruso se aplica como el idioma coreano del juego. Aplicar uno reemplaza el archivo del otro en el juego, y solo el último aplicado aparece en el juego. - Algunos textos de la interfaz solo se actualizan tras reiniciar la aplicación. Los textos de la tabla se recargan de inmediato. diff --git a/languages/spanish/enhancements.json b/languages/spanish/enhancements.json new file mode 100644 index 00000000..82c2e5e5 --- /dev/null +++ b/languages/spanish/enhancements.json @@ -0,0 +1,833 @@ +{ + "_comment": "Translations of the text Smart Citizen adds to the game strings (stat labels, mission details, journal lines). Each key is the English text from languages/english/enhancements.json. 'ht' is a human translation and wins; 'at' is an AI draft. Keep each {placeholder} as it is.", + "strings": { + "--- EFFECT ---": { + "ht": "", + "at": "--- EFECTO ---" + }, + "--- STATS ---": { + "ht": "", + "at": "--- ESTADÍSTICAS ---" + }, + "Absolute Range": { + "ht": "", + "at": "Alcance absoluto" + }, + "Acceleration": { + "ht": "", + "at": "Aceleración" + }, + "Ace Pilot": { + "ht": "", + "at": "Piloto as" + }, + "Ace Pilots": { + "ht": "", + "at": "Pilotos ases" + }, + "Aim Assist Range": { + "ht": "", + "at": "Alcance asist. apuntado" + }, + "Alpha Dmg": { + "ht": "", + "at": "Daño alfa" + }, + "Ammo": { + "ht": "", + "at": "Munición" + }, + "Arm Dist": { + "ht": "", + "at": "Dist. armado" + }, + "Arm Time": { + "ht": "", + "at": "Tiempo armado" + }, + "Armor HP": { + "ht": "", + "at": "PV blindaje" + }, + "Armour": { + "ht": "", + "at": "Armadura" + }, + "Attackers": { + "ht": "", + "at": "Atacantes" + }, + "Auto": { + "ht": "", + "at": "Auto" + }, + "Backup": { + "ht": "", + "at": "Refuerzos" + }, + "Bandits": { + "ht": "", + "at": "Bandidos" + }, + "Base Resource Signature": { + "ht": "", + "at": "Firma de recurso base" + }, + "Beam": { + "ht": "", + "at": "Haz" + }, + "Bio": { + "ht": "", + "at": "Bio" + }, + "Blast Radius": { + "ht": "", + "at": "Radio de explosión" + }, + "Blueprint Reward": { + "ht": "", + "at": "Plano de recompensa" + }, + "Bomb Slots": { + "ht": "", + "at": "Ranuras de bombas" + }, + "Boost": { + "ht": "", + "at": "Impulso" + }, + "Boss": { + "ht": "", + "at": "Jefe" + }, + "Burst": { + "ht": "", + "at": "Ráfaga" + }, + "CQC": { + "ht": "", + "at": "CQC" + }, + "Cal Rate": { + "ht": "", + "at": "Vel. calibr." + }, + "Captain": { + "ht": "", + "at": "Capitán" + }, + "Chain": { + "ht": "", + "at": "Cadena" + }, + "Charge": { + "ht": "", + "at": "Carga" + }, + "Civilians": { + "ht": "", + "at": "Civiles" + }, + "Class": { + "ht": "", + "at": "Clase" + }, + "Combat": { + "ht": "", + "at": "Combate" + }, + "Complexity": { + "ht": "", + "at": "Complejidad" + }, + "Component HP": { + "ht": "", + "at": "PV componente" + }, + "Cooldown": { + "ht": "", + "at": "Enfriamiento" + }, + "Coolers": { + "ht": "", + "at": "Refrigeradores" + }, + "Cooling Rate": { + "ht": "", + "at": "Tasa de enfriamiento" + }, + "Cost/Shot": { + "ht": "", + "at": "Coste/disparo" + }, + "Crew": { + "ht": "", + "at": "Tripulación" + }, + "DPS": { + "ht": "", + "at": "DPS" + }, + "Damage": { + "ht": "", + "at": "Daño" + }, + "Damage-Map Rate": { + "ht": "", + "at": "Tasa mapa de daños" + }, + "Damaged Delay": { + "ht": "", + "at": "Retardo si dañado" + }, + "Defenders": { + "ht": "", + "at": "Defensores" + }, + "Deflect": { + "ht": "", + "at": "Desvío" + }, + "Detection Mode": { + "ht": "", + "at": "Modo de detección" + }, + "Detonation": { + "ht": "", + "at": "Detonación" + }, + "Difficulty (1-7)": { + "ht": "", + "at": "Dificultad (1-7)" + }, + "Distort": { + "ht": "", + "at": "Distors." + }, + "Dmg Mult": { + "ht": "", + "at": "Mult. daño" + }, + "Downed Delay": { + "ht": "", + "at": "Retardo si derribado" + }, + "Drop": { + "ht": "", + "at": "Caída" + }, + "EM": { + "ht": "", + "at": "EM" + }, + "EM Signature": { + "ht": "", + "at": "Firma EM" + }, + "Effective Range": { + "ht": "", + "at": "Alcance efectivo" + }, + "Energy": { + "ht": "", + "at": "Energía" + }, + "Engagement Type": { + "ht": "", + "at": "Tipo de combate" + }, + "Escort Wings": { + "ht": "", + "at": "Alas de escolta" + }, + "Escorts": { + "ht": "", + "at": "Escoltas" + }, + "Extraction": { + "ht": "", + "at": "Extracción" + }, + "FPS": { + "ht": "", + "at": "FPS" + }, + "FPS & Ship": { + "ht": "", + "at": "FPS y nave" + }, + "Failure": { + "ht": "", + "at": "Fracaso" + }, + "Failure Penalty": { + "ht": "", + "at": "Penalización por fracaso" + }, + "Fire Modes": { + "ht": "", + "at": "Modos de disparo" + }, + "Fire Rate": { + "ht": "", + "at": "Cadencia" + }, + "Fracture": { + "ht": "", + "at": "Fractura" + }, + "Friendlies": { + "ht": "", + "at": "Aliados" + }, + "Fuel": { + "ht": "", + "at": "Combustible" + }, + "Fuel/Gm": { + "ht": "", + "at": "Combustible/Gm" + }, + "Full Dmg to": { + "ht": "", + "at": "Daño completo hasta" + }, + "Grade": { + "ht": "", + "at": "Grado" + }, + "Grunts": { + "ht": "", + "at": "Secuaces" + }, + "Guaranteed": { + "ht": "", + "at": "Garantizado" + }, + "Guards": { + "ht": "", + "at": "Guardias" + }, + "Guidance": { + "ht": "", + "at": "Guiado" + }, + "Guns": { + "ht": "", + "at": "Cañones" + }, + "HP Rate": { + "ht": "", + "at": "Tasa PV" + }, + "HP/Ammo": { + "ht": "", + "at": "PV/munición" + }, + "Heat": { + "ht": "", + "at": "Calor" + }, + "Heist Target": { + "ht": "", + "at": "Objetivo del golpe" + }, + "Hostages": { + "ht": "", + "at": "Rehenes" + }, + "Hostile Allies": { + "ht": "", + "at": "Aliados hostiles" + }, + "Hostile Wave": { + "ht": "", + "at": "Oleada hostil" + }, + "Hostiles": { + "ht": "", + "at": "Hostiles" + }, + "IR": { + "ht": "", + "at": "IR" + }, + "IR Signature": { + "ht": "", + "at": "Firma IR" + }, + "Inert Filter": { + "ht": "", + "at": "Filtro inerte" + }, + "Insurance": { + "ht": "", + "at": "Seguro" + }, + "Interdiction Ships": { + "ht": "", + "at": "Naves de interdicción" + }, + "Item Type": { + "ht": "", + "at": "Tipo de objeto" + }, + "Juggernauts": { + "ht": "", + "at": "Juggernauts" + }, + "Jump Drives": { + "ht": "", + "at": "Motores de salto" + }, + "Knowledge": { + "ht": "", + "at": "Conocimiento" + }, + "Kopions": { + "ht": "", + "at": "Kopions" + }, + "Length": { + "ht": "", + "at": "Longitud" + }, + "Lifetime": { + "ht": "", + "at": "Duración" + }, + "Locations": { + "ht": "", + "at": "Ubicaciones" + }, + "Lock Range": { + "ht": "", + "at": "Alcance de fijación" + }, + "Lock Time": { + "ht": "", + "at": "Tiempo de fijación" + }, + "MRacks": { + "ht": "", + "at": "Lanzamisiles" + }, + "Material Efficiency": { + "ht": "", + "at": "Eficiencia de material" + }, + "Maulers": { + "ht": "", + "at": "Maulers" + }, + "Max": { + "ht": "", + "at": "Máx." + }, + "Max Distortion": { + "ht": "", + "at": "Distorsión máx." + }, + "Max G-Force": { + "ht": "", + "at": "Fuerza G máx." + }, + "Max HP": { + "ht": "", + "at": "PV máx." + }, + "Max Lifetime": { + "ht": "", + "at": "Duración máx." + }, + "Max Lock Range": { + "ht": "", + "at": "Alcance fijación máx." + }, + "Min Detonate": { + "ht": "", + "at": "Detonación mín." + }, + "Min Dmg": { + "ht": "", + "at": "Daño mín." + }, + "Min Lock Range": { + "ht": "", + "at": "Alcance fijación mín." + }, + "Mission Type": { + "ht": "", + "at": "Tipo de misión" + }, + "Nine Tails": { + "ht": "", + "at": "Nine Tails" + }, + "Objectives": { + "ht": "", + "at": "Objetivos" + }, + "Overheat Temp": { + "ht": "", + "at": "Temp. sobrecalent." + }, + "Phys": { + "ht": "", + "at": "Fís." + }, + "Ping Cooldown": { + "ht": "", + "at": "Enfriamiento de ping" + }, + "Pirates": { + "ht": "", + "at": "Piratas" + }, + "Pitch": { + "ht": "", + "at": "Cabeceo" + }, + "Polaris": { + "ht": "", + "at": "Polaris" + }, + "Power": { + "ht": "", + "at": "Energía" + }, + "Power Draw": { + "ht": "", + "at": "Consumo" + }, + "Power Output": { + "ht": "", + "at": "Producción de energía" + }, + "Power Plants": { + "ht": "", + "at": "Generadores" + }, + "Private Security": { + "ht": "", + "at": "Seguridad privada" + }, + "Probe": { + "ht": "", + "at": "Sonda" + }, + "Prospectors": { + "ht": "", + "at": "Prospectors" + }, + "Protected": { + "ht": "", + "at": "Protegidos" + }, + "Proximity Range": { + "ht": "", + "at": "Alcance de proximidad" + }, + "QD": { + "ht": "", + "at": "MC" + }, + "QT Fuel Use": { + "ht": "", + "at": "Consumo QT" + }, + "QT Speed": { + "ht": "", + "at": "Velocidad QT" + }, + "Quantum Drives": { + "ht": "", + "at": "Motores cuánticos" + }, + "Quantum Enforcement Devices": { + "ht": "", + "at": "Dispositivos de interdicción cuántica" + }, + "Radars": { + "ht": "", + "at": "Radares" + }, + "Ramp": { + "ht": "", + "at": "Rampa" + }, + "Range": { + "ht": "", + "at": "Alcance" + }, + "Rank": { + "ht": "", + "at": "Rango" + }, + "Recharges Oxygen reserves of a suit.": { + "ht": "", + "at": "Recarga las reservas de oxígeno de un traje." + }, + "Recipient": { + "ht": "", + "at": "Destinatario" + }, + "Reduces concussion symptoms, normalizes weapon handling and movement speed.": { + "ht": "", + "at": "Reduce los síntomas de conmoción, normaliza el manejo de armas y la velocidad de movimiento." + }, + "Reduces injuries from radiation.": { + "ht": "", + "at": "Reduce las lesiones por radiación." + }, + "Reduces pain symptoms, normalizes movement ability.": { + "ht": "", + "at": "Reduce el dolor, normaliza la capacidad de movimiento." + }, + "Reduces vision and hearing symptoms, normalizes stamina.": { + "ht": "", + "at": "Reduce los trastornos de visión y audición, normaliza la resistencia." + }, + "Refuel Nozzles": { + "ht": "", + "at": "Boquillas de repostaje" + }, + "Regen": { + "ht": "", + "at": "Regen." + }, + "Reinforcements": { + "ht": "", + "at": "Refuerzos" + }, + "Required": { + "ht": "", + "at": "Requerido" + }, + "Resource Signatures": { + "ht": "", + "at": "Firmas de recursos" + }, + "Restores health and stops bleeding. When used on another person recovers from incapacitated state.": { + "ht": "", + "at": "Restaura la salud y detiene las hemorragias. Usado en otra persona, la recupera de la incapacitación." + }, + "Revives an overdosed person (if not incapacitated), doubles decay rate of Blood Drug Level.": { + "ht": "", + "at": "Reanima a una persona con sobredosis (si no está incapacitada), duplica la bajada del nivel de droga en sangre." + }, + "Risk": { + "ht": "", + "at": "Riesgo" + }, + "Role": { + "ht": "", + "at": "Función" + }, + "Roll": { + "ht": "", + "at": "Alabeo" + }, + "SCM": { + "ht": "", + "at": "SCM" + }, + "Salvageable Ships": { + "ht": "", + "at": "Naves rescatables" + }, + "Scanners": { + "ht": "", + "at": "Escáneres" + }, + "Security Forces": { + "ht": "", + "at": "Fuerzas de seguridad" + }, + "Seeker": { + "ht": "", + "at": "Buscador" + }, + "Semi-Auto": { + "ht": "", + "at": "Semiauto" + }, + "Sentries": { + "ht": "", + "at": "Centinelas" + }, + "Shields": { + "ht": "", + "at": "Escudos" + }, + "Ship": { + "ht": "", + "at": "Nave" + }, + "Ships to Defend": { + "ht": "", + "at": "Naves a defender" + }, + "Shotgun": { + "ht": "", + "at": "Escopeta" + }, + "Size": { + "ht": "", + "at": "Tamaño" + }, + "Snipers": { + "ht": "", + "at": "Francotiradores" + }, + "Soldiers": { + "ht": "", + "at": "Soldados" + }, + "Spool": { + "ht": "", + "at": "Arranque" + }, + "Standard": { + "ht": "", + "at": "Estándar" + }, + "Starter": { + "ht": "", + "at": "Inicial" + }, + "Stun": { + "ht": "", + "at": "Aturd." + }, + "Targets": { + "ht": "", + "at": "Objetivos" + }, + "Technicians": { + "ht": "", + "at": "Técnicos" + }, + "Thermal": { + "ht": "", + "at": "Térmico" + }, + "Tier": { + "ht": "", + "at": "Nivel" + }, + "Tracking": { + "ht": "", + "at": "Seguimiento" + }, + "Tracking Range": { + "ht": "", + "at": "Alcance de seguimiento" + }, + "Turn Rate": { + "ht": "", + "at": "Vel. de giro" + }, + "Turrets": { + "ht": "", + "at": "Torretas" + }, + "Unique": { + "ht": "", + "at": "Única" + }, + "Used To Craft": { + "ht": "", + "at": "Se usa para fabricar" + }, + "Velocity": { + "ht": "", + "at": "Velocidad" + }, + "Wear": { + "ht": "", + "at": "Desgaste" + }, + "Weight": { + "ht": "", + "at": "Peso" + }, + "Xeno Threat": { + "ht": "", + "at": "Xeno Threat" + }, + "Yaw": { + "ht": "", + "at": "Guiñada" + }, + "Yes": { + "ht": "", + "at": "Sí" + }, + "base": { + "ht": "", + "at": "base" + }, + "down": { + "ht": "", + "at": "bajada" + }, + "empty": { + "ht": "", + "at": "vacío" + }, + "express": { + "ht": "", + "at": "exprés" + }, + "friendly": { + "ht": "", + "at": "amistosas" + }, + "hostile": { + "ht": "", + "at": "hostiles" + }, + "present": { + "ht": "", + "at": "presentes" + }, + "select variants": { + "ht": "", + "at": "algunas variantes" + }, + "up": { + "ht": "", + "at": "subida" + }, + "{count} items": { + "ht": "", + "at": "{count} objetos" + }, + "{count} sets": { + "ht": "", + "at": "{count} conjuntos" + }, + "{count} types": { + "ht": "", + "at": "{count} tipos" + }, + "{item} Set": { + "ht": "", + "at": "Conjunto {item}" + }, + "{pct}% chance": { + "ht": "", + "at": "{pct}% de probabilidad" + }, + "{pct}% chance ({variants} only)": { + "ht": "", + "at": "{pct}% de probabilidad (solo {variants})" + }, + "{type} Ammo": { + "ht": "", + "at": "Munición {type}" + } + } +} diff --git a/languages/spanish/ui.json b/languages/spanish/ui.json index b55809f2..a6186b1d 100644 --- a/languages/spanish/ui.json +++ b/languages/spanish/ui.json @@ -2286,6 +2286,10 @@ "ht": "No se pudo descargar la localización {language} y no se encontró ninguna copia en caché. Se mostrará la base inglesa. Revisa la URL en Asignar archivo de idioma y tu conexión, e inténtalo de nuevo.", "at": "" }, + "language_updated_status": { + "ht": "", + "at": "Se descargó una traducción {language} más reciente. Recargando con ella." + }, "language_generating_enhancements": { "ht": "Generando mejoras de {language} desde DataForge...", "at": "" diff --git a/languages/turkish/HELP.md b/languages/turkish/HELP.md index d8498866..7faec8d3 100644 --- a/languages/turkish/HELP.md +++ b/languages/turkish/HELP.md @@ -116,7 +116,8 @@ Star Citizen güncellendiğinde düzenlemeleriniz `\\user - **İngilizce** (varsayılan), kendi `Data.p4k` dosyanızdan çıkarılan orijinal metinleri kullanır. - **Diğer diller**, o dilin topluluk tarafından çevrilmiş `global.ini` dosyasını indirir ve İngilizce temelin üzerine katmanlar; böylece çevirinin kapsamadığı her metin kaybolmak yerine İngilizceye döner. İndirme dil başına önbelleğe alınır; daha sonra geri geçtiğinizde önbellek yeniden kullanılır. -- **Geliştirmeler İngilizce kalır.** İstatistik blokları, etiketler ve görev ayrıntıları oyun verilerinden üretilir ve çevrilmiş düzyazının üzerinde İngilizce biçimlerini korur. Karışık bir satır (örneğin İngilizce bir istatistik bloğu içinde Türkçe bir rol adı) beklenen bir durumdur, hata değildir. +- **Geliştirmeler dilinizi izler.** Smart Citizen'ın eklediği istatistik etiketleri, görev ayrıntıları ve günlük satırları seçtiğiniz dilde yazılır. Eşya adları çevirinin kendisinden gelir; `[BP]` gibi etiketler ve görev bölüm başlıkları olduğu gibi kalır. +- **Çeviri güncel kalır.** Smart Citizen her açılışta topluluk çevirisinin daha yeni bir sürümü olup olmadığına bakar ve varsa onunla yeniden yükler. Böylece bir oyun yamasından sonra yapılan düzeltme, dil değiştirmeden size ulaşır. - **Dil Dosyası Eşle** (Yapılandırma sekmesi), bir dili farklı bir `global.ini` dosyasına yönlendirmenizi sağlar — bir URL'ye (örneğin bir topluluk çevirisinin kendi çatalınıza) veya **Gözat...** ile diskinizde zaten bulunan bir dosyaya. URL indirilir ve önbelleğe alınır; yerel dosya ise içeri kopyalanır. Her iki durumda da paketle gelen varsayılana göre önceliklidir. Topluluk çevirisi yeniden dağıtılamayan bir dil için (ör. Korece) tek seçenek yerel dosya eşlemesidir — önce o topluluğun kendi yamasını kurun, **`global.ini` dosyasını Star Citizen kurulumunuzun dışında bir yere kopyalayın** (Smart Citizen'ın orada zaten uyguladığı kopyayı eşlemek, kendi birleştirilmiş çıktısını bir sonraki "kaynak" olarak geri besler ve her geliştirmeyi ikiye katlar), ardından Gözat ile o kopyayı seçin. - **Rusça ve Korece oyunun aynı dil yuvasını paylaşır.** Oyunda Rusça yuvası yoktur ve Kiril harflerini gösteren tek yazı tipi Korece yazı tipidir, bu yüzden Rusça oyunun Korece dili olarak uygulanır. Birini uygulamak oyundaki diğerinin dosyasını değiştirir ve oyunda yalnızca en son uyguladığınız görünür. - Bazı arayüz metinleri yalnızca uygulama yeniden başlatıldıktan sonra güncellenir. Tablo metinleri hemen yeniden yüklenir. diff --git a/languages/turkish/enhancements.json b/languages/turkish/enhancements.json new file mode 100644 index 00000000..6368b22f --- /dev/null +++ b/languages/turkish/enhancements.json @@ -0,0 +1,833 @@ +{ + "_comment": "Translations of the text Smart Citizen adds to the game strings (stat labels, mission details, journal lines). Each key is the English text from languages/english/enhancements.json. 'ht' is a human translation and wins; 'at' is an AI draft. Keep each {placeholder} as it is.", + "strings": { + "--- EFFECT ---": { + "ht": "", + "at": "--- ETKİ ---" + }, + "--- STATS ---": { + "ht": "", + "at": "--- İSTATİSTİKLER ---" + }, + "Absolute Range": { + "ht": "", + "at": "Mutlak menzil" + }, + "Acceleration": { + "ht": "", + "at": "İvme" + }, + "Ace Pilot": { + "ht": "", + "at": "As pilot" + }, + "Ace Pilots": { + "ht": "", + "at": "As pilotlar" + }, + "Aim Assist Range": { + "ht": "", + "at": "Nişan yardımı menzili" + }, + "Alpha Dmg": { + "ht": "", + "at": "Alfa hasar" + }, + "Ammo": { + "ht": "", + "at": "Mühimmat" + }, + "Arm Dist": { + "ht": "", + "at": "Kurma mesafesi" + }, + "Arm Time": { + "ht": "", + "at": "Kurma süresi" + }, + "Armor HP": { + "ht": "", + "at": "Zırh CP" + }, + "Armour": { + "ht": "", + "at": "Zırh" + }, + "Attackers": { + "ht": "", + "at": "Saldırganlar" + }, + "Auto": { + "ht": "", + "at": "Otomatik" + }, + "Backup": { + "ht": "", + "at": "Destek" + }, + "Bandits": { + "ht": "", + "at": "Haydutlar" + }, + "Base Resource Signature": { + "ht": "", + "at": "Temel kaynak imzası" + }, + "Beam": { + "ht": "", + "at": "Işın" + }, + "Bio": { + "ht": "", + "at": "Biyo" + }, + "Blast Radius": { + "ht": "", + "at": "Patlama yarıçapı" + }, + "Blueprint Reward": { + "ht": "", + "at": "Plan ödülü" + }, + "Bomb Slots": { + "ht": "", + "at": "Bomba yuvaları" + }, + "Boost": { + "ht": "", + "at": "Takviye" + }, + "Boss": { + "ht": "", + "at": "Patron" + }, + "Burst": { + "ht": "", + "at": "Seri atış" + }, + "CQC": { + "ht": "", + "at": "Yakın dövüş" + }, + "Cal Rate": { + "ht": "", + "at": "Kalibr. hızı" + }, + "Captain": { + "ht": "", + "at": "Kaptan" + }, + "Chain": { + "ht": "", + "at": "Zincir" + }, + "Charge": { + "ht": "", + "at": "Şarj" + }, + "Civilians": { + "ht": "", + "at": "Siviller" + }, + "Class": { + "ht": "", + "at": "Sınıf" + }, + "Combat": { + "ht": "", + "at": "Çatışma" + }, + "Complexity": { + "ht": "", + "at": "Karmaşıklık" + }, + "Component HP": { + "ht": "", + "at": "Bileşen CP" + }, + "Cooldown": { + "ht": "", + "at": "Bekleme" + }, + "Coolers": { + "ht": "", + "at": "Soğutucular" + }, + "Cooling Rate": { + "ht": "", + "at": "Soğutma hızı" + }, + "Cost/Shot": { + "ht": "", + "at": "Maliyet/atış" + }, + "Crew": { + "ht": "", + "at": "Mürettebat" + }, + "DPS": { + "ht": "", + "at": "SBH" + }, + "Damage": { + "ht": "", + "at": "Hasar" + }, + "Damage-Map Rate": { + "ht": "", + "at": "Hasar haritası hızı" + }, + "Damaged Delay": { + "ht": "", + "at": "Hasarlıyken gecikme" + }, + "Defenders": { + "ht": "", + "at": "Savunucular" + }, + "Deflect": { + "ht": "", + "at": "Saptırma" + }, + "Detection Mode": { + "ht": "", + "at": "Algılama modu" + }, + "Detonation": { + "ht": "", + "at": "Patlatma" + }, + "Difficulty (1-7)": { + "ht": "", + "at": "Zorluk (1-7)" + }, + "Distort": { + "ht": "", + "at": "Bozulma" + }, + "Dmg Mult": { + "ht": "", + "at": "Hasar çarpanı" + }, + "Downed Delay": { + "ht": "", + "at": "Düşünce gecikme" + }, + "Drop": { + "ht": "", + "at": "Düşüş" + }, + "EM": { + "ht": "", + "at": "EM" + }, + "EM Signature": { + "ht": "", + "at": "EM imzası" + }, + "Effective Range": { + "ht": "", + "at": "Etkili menzil" + }, + "Energy": { + "ht": "", + "at": "Enerji" + }, + "Engagement Type": { + "ht": "", + "at": "Çatışma türü" + }, + "Escort Wings": { + "ht": "", + "at": "Eskort filoları" + }, + "Escorts": { + "ht": "", + "at": "Eskortlar" + }, + "Extraction": { + "ht": "", + "at": "Çıkarma" + }, + "FPS": { + "ht": "", + "at": "FPS" + }, + "FPS & Ship": { + "ht": "", + "at": "FPS ve gemi" + }, + "Failure": { + "ht": "", + "at": "Başarısızlık" + }, + "Failure Penalty": { + "ht": "", + "at": "Başarısızlık cezası" + }, + "Fire Modes": { + "ht": "", + "at": "Atış modları" + }, + "Fire Rate": { + "ht": "", + "at": "Atış hızı" + }, + "Fracture": { + "ht": "", + "at": "Kırma" + }, + "Friendlies": { + "ht": "", + "at": "Dostlar" + }, + "Fuel": { + "ht": "", + "at": "Yakıt" + }, + "Fuel/Gm": { + "ht": "", + "at": "Yakıt/Gm" + }, + "Full Dmg to": { + "ht": "", + "at": "Tam hasar mesafesi" + }, + "Grade": { + "ht": "", + "at": "Derece" + }, + "Grunts": { + "ht": "", + "at": "Erler" + }, + "Guaranteed": { + "ht": "", + "at": "Garantili" + }, + "Guards": { + "ht": "", + "at": "Muhafızlar" + }, + "Guidance": { + "ht": "", + "at": "Güdüm" + }, + "Guns": { + "ht": "", + "at": "Toplar" + }, + "HP Rate": { + "ht": "", + "at": "CP hızı" + }, + "HP/Ammo": { + "ht": "", + "at": "CP/mühimmat" + }, + "Heat": { + "ht": "", + "at": "Isı" + }, + "Heist Target": { + "ht": "", + "at": "Soygun hedefi" + }, + "Hostages": { + "ht": "", + "at": "Rehineler" + }, + "Hostile Allies": { + "ht": "", + "at": "Düşman müttefikler" + }, + "Hostile Wave": { + "ht": "", + "at": "Düşman dalgası" + }, + "Hostiles": { + "ht": "", + "at": "Düşmanlar" + }, + "IR": { + "ht": "", + "at": "IR" + }, + "IR Signature": { + "ht": "", + "at": "IR imzası" + }, + "Inert Filter": { + "ht": "", + "at": "İnert filtre" + }, + "Insurance": { + "ht": "", + "at": "Sigorta" + }, + "Interdiction Ships": { + "ht": "", + "at": "Önleme gemileri" + }, + "Item Type": { + "ht": "", + "at": "Eşya türü" + }, + "Juggernauts": { + "ht": "", + "at": "Juggernautlar" + }, + "Jump Drives": { + "ht": "", + "at": "Atlama motorları" + }, + "Knowledge": { + "ht": "", + "at": "Bilgi" + }, + "Kopions": { + "ht": "", + "at": "Kopionlar" + }, + "Length": { + "ht": "", + "at": "Uzunluk" + }, + "Lifetime": { + "ht": "", + "at": "Ömür" + }, + "Locations": { + "ht": "", + "at": "Konumlar" + }, + "Lock Range": { + "ht": "", + "at": "Kilit menzili" + }, + "Lock Time": { + "ht": "", + "at": "Kilit süresi" + }, + "MRacks": { + "ht": "", + "at": "Füze rafları" + }, + "Material Efficiency": { + "ht": "", + "at": "Malzeme verimi" + }, + "Maulers": { + "ht": "", + "at": "Maulers" + }, + "Max": { + "ht": "", + "at": "Maks." + }, + "Max Distortion": { + "ht": "", + "at": "Maks. bozulma" + }, + "Max G-Force": { + "ht": "", + "at": "Maks. G kuvveti" + }, + "Max HP": { + "ht": "", + "at": "Maks. CP" + }, + "Max Lifetime": { + "ht": "", + "at": "Maks. ömür" + }, + "Max Lock Range": { + "ht": "", + "at": "Maks. kilit menzili" + }, + "Min Detonate": { + "ht": "", + "at": "Min. patlama" + }, + "Min Dmg": { + "ht": "", + "at": "Min. hasar" + }, + "Min Lock Range": { + "ht": "", + "at": "Min. kilit menzili" + }, + "Mission Type": { + "ht": "", + "at": "Görev türü" + }, + "Nine Tails": { + "ht": "", + "at": "Nine Tails" + }, + "Objectives": { + "ht": "", + "at": "Hedefler" + }, + "Overheat Temp": { + "ht": "", + "at": "Aşırı ısınma sıc." + }, + "Phys": { + "ht": "", + "at": "Fiz." + }, + "Ping Cooldown": { + "ht": "", + "at": "Ping bekleme" + }, + "Pirates": { + "ht": "", + "at": "Korsanlar" + }, + "Pitch": { + "ht": "", + "at": "Yunuslama" + }, + "Polaris": { + "ht": "", + "at": "Polaris" + }, + "Power": { + "ht": "", + "at": "Güç" + }, + "Power Draw": { + "ht": "", + "at": "Güç tüketimi" + }, + "Power Output": { + "ht": "", + "at": "Güç üretimi" + }, + "Power Plants": { + "ht": "", + "at": "Jeneratörler" + }, + "Private Security": { + "ht": "", + "at": "Özel güvenlik" + }, + "Probe": { + "ht": "", + "at": "Sonda" + }, + "Prospectors": { + "ht": "", + "at": "Prospectorlar" + }, + "Protected": { + "ht": "", + "at": "Korunanlar" + }, + "Proximity Range": { + "ht": "", + "at": "Yakınlık menzili" + }, + "QD": { + "ht": "", + "at": "KM" + }, + "QT Fuel Use": { + "ht": "", + "at": "QT yakıt tük." + }, + "QT Speed": { + "ht": "", + "at": "QT hızı" + }, + "Quantum Drives": { + "ht": "", + "at": "Kuantum motorları" + }, + "Quantum Enforcement Devices": { + "ht": "", + "at": "Kuantum önleme cihazları" + }, + "Radars": { + "ht": "", + "at": "Radarlar" + }, + "Ramp": { + "ht": "", + "at": "Rampa" + }, + "Range": { + "ht": "", + "at": "Menzil" + }, + "Rank": { + "ht": "", + "at": "Rütbe" + }, + "Recharges Oxygen reserves of a suit.": { + "ht": "", + "at": "Bir giysinin oksijen rezervlerini doldurur." + }, + "Recipient": { + "ht": "", + "at": "Alıcı" + }, + "Reduces concussion symptoms, normalizes weapon handling and movement speed.": { + "ht": "", + "at": "Sarsıntı belirtilerini azaltır, silah kullanımını ve hareket hızını normale döndürür." + }, + "Reduces injuries from radiation.": { + "ht": "", + "at": "Radyasyon yaralanmalarını azaltır." + }, + "Reduces pain symptoms, normalizes movement ability.": { + "ht": "", + "at": "Ağrı belirtilerini azaltır, hareket yeteneğini normale döndürür." + }, + "Reduces vision and hearing symptoms, normalizes stamina.": { + "ht": "", + "at": "Görme ve işitme belirtilerini azaltır, dayanıklılığı normale döndürür." + }, + "Refuel Nozzles": { + "ht": "", + "at": "Yakıt nozulları" + }, + "Regen": { + "ht": "", + "at": "Yenilenme" + }, + "Reinforcements": { + "ht": "", + "at": "Takviyeler" + }, + "Required": { + "ht": "", + "at": "Gerekli" + }, + "Resource Signatures": { + "ht": "", + "at": "Kaynak imzaları" + }, + "Restores health and stops bleeding. When used on another person recovers from incapacitated state.": { + "ht": "", + "at": "Sağlığı geri kazandırır ve kanamayı durdurur. Başka birine kullanıldığında onu etkisiz durumdan kurtarır." + }, + "Revives an overdosed person (if not incapacitated), doubles decay rate of Blood Drug Level.": { + "ht": "", + "at": "Aşırı doz almış birini canlandırır (etkisiz değilse), kandaki ilaç seviyesinin düşüşünü iki katına çıkarır." + }, + "Risk": { + "ht": "", + "at": "Risk" + }, + "Role": { + "ht": "", + "at": "Rol" + }, + "Roll": { + "ht": "", + "at": "Yuvarlanma" + }, + "SCM": { + "ht": "", + "at": "SCM" + }, + "Salvageable Ships": { + "ht": "", + "at": "Kurtarılabilir gemiler" + }, + "Scanners": { + "ht": "", + "at": "Tarayıcılar" + }, + "Security Forces": { + "ht": "", + "at": "Güvenlik güçleri" + }, + "Seeker": { + "ht": "", + "at": "Arayıcı" + }, + "Semi-Auto": { + "ht": "", + "at": "Yarı otomatik" + }, + "Sentries": { + "ht": "", + "at": "Nöbetçiler" + }, + "Shields": { + "ht": "", + "at": "Kalkanlar" + }, + "Ship": { + "ht": "", + "at": "Gemi" + }, + "Ships to Defend": { + "ht": "", + "at": "Korunacak gemiler" + }, + "Shotgun": { + "ht": "", + "at": "Pompalı" + }, + "Size": { + "ht": "", + "at": "Boyut" + }, + "Snipers": { + "ht": "", + "at": "Keskin nişancılar" + }, + "Soldiers": { + "ht": "", + "at": "Askerler" + }, + "Spool": { + "ht": "", + "at": "Hazırlanma" + }, + "Standard": { + "ht": "", + "at": "Standart" + }, + "Starter": { + "ht": "", + "at": "Başlangıç" + }, + "Stun": { + "ht": "", + "at": "Sersem." + }, + "Targets": { + "ht": "", + "at": "Hedefler" + }, + "Technicians": { + "ht": "", + "at": "Teknisyenler" + }, + "Thermal": { + "ht": "", + "at": "Termal" + }, + "Tier": { + "ht": "", + "at": "Kademe" + }, + "Tracking": { + "ht": "", + "at": "İzleme" + }, + "Tracking Range": { + "ht": "", + "at": "İzleme menzili" + }, + "Turn Rate": { + "ht": "", + "at": "Dönüş hızı" + }, + "Turrets": { + "ht": "", + "at": "Taretler" + }, + "Unique": { + "ht": "", + "at": "Tek seferlik" + }, + "Used To Craft": { + "ht": "", + "at": "Üretimde kullanılır" + }, + "Velocity": { + "ht": "", + "at": "Hız" + }, + "Wear": { + "ht": "", + "at": "Aşınma" + }, + "Weight": { + "ht": "", + "at": "Ağırlık" + }, + "Xeno Threat": { + "ht": "", + "at": "Xeno Threat" + }, + "Yaw": { + "ht": "", + "at": "Sapma" + }, + "Yes": { + "ht": "", + "at": "Evet" + }, + "base": { + "ht": "", + "at": "temel" + }, + "down": { + "ht": "", + "at": "iniş" + }, + "empty": { + "ht": "", + "at": "boş" + }, + "express": { + "ht": "", + "at": "ekspres" + }, + "friendly": { + "ht": "", + "at": "dost" + }, + "hostile": { + "ht": "", + "at": "düşman" + }, + "present": { + "ht": "", + "at": "var" + }, + "select variants": { + "ht": "", + "at": "bazı varyantlar" + }, + "up": { + "ht": "", + "at": "çıkış" + }, + "{count} items": { + "ht": "", + "at": "{count} eşya" + }, + "{count} sets": { + "ht": "", + "at": "{count} set" + }, + "{count} types": { + "ht": "", + "at": "{count} tür" + }, + "{item} Set": { + "ht": "", + "at": "{item} Seti" + }, + "{pct}% chance": { + "ht": "", + "at": "%{pct} şans" + }, + "{pct}% chance ({variants} only)": { + "ht": "", + "at": "%{pct} şans (yalnızca {variants})" + }, + "{type} Ammo": { + "ht": "", + "at": "{type} Mühimmatı" + } + } +} diff --git a/languages/turkish/ui.json b/languages/turkish/ui.json index b9e3f8f1..bfe7a541 100644 --- a/languages/turkish/ui.json +++ b/languages/turkish/ui.json @@ -2286,6 +2286,10 @@ "ht": "", "at": "{language} yerelleştirmesi yapılandırılan kaynaktan yüklenemedi ve önbelleğe alınmış bir kopya bulunamadı. Bunun yerine İngilizce temel gösteriliyor. Dil Dosyası Eşle'deki URL'yi veya dosyayı kontrol edip yeniden deneyin." }, + "language_updated_status": { + "ht": "", + "at": "Daha yeni bir {language} çevirisi indirildi. Onunla yeniden yükleniyor." + }, "language_generating_enhancements": { "ht": "", "at": "DataForge'dan {language} geliştirmeleri oluşturuluyor…" diff --git a/scripts/CLAUDE.md b/scripts/CLAUDE.md index 5b21aba8..1ad868fa 100644 --- a/scripts/CLAUDE.md +++ b/scripts/CLAUDE.md @@ -24,6 +24,8 @@ Standalone CLI scripts and the build pipeline. See the root `CLAUDE.md` for proj Closing Smart Citizen stops a running generation. `main()` takes `should_cancel` (the GUI worker passes `isInterruptionRequested`; None, the default, never stops, so the CLI is unchanged) and asks it between jobs: after the base.ini parse, after the English parse, after the XML path index, before each lookup and each generator, and once more just before the write phase, after the loc-string workarounds. When it returns True, `main()` raises `GenerationStopped`, a plain `Exception` like `pak_extractor.ExtractionCancelled` and not a `RuntimeError`, because a stop is not a failure. The worker matches it by class name, since it loads the script afresh for every run, so keep the name. No INI has been written at any of those points (lookup pickles may have been, each one whole through `atomic_writer`). There is deliberately no check inside the write phase: a run that reached it writes every INI, so a stop can never leave a set that is part old and part new, and the worker then certifies it as usual. The lookups and generators are checked one by one only on the serial path (`max_workers=1`, which the GUI always takes); the pool branches, used only by the CLI and tests, get just the check before the writes. A stop takes up to one job, and the uncached scitem lookup is the longest. `tests/test_generation_writes.py` locks the stop points. ### Mining-laser and handheld-salvage stat enhancements +`generate_enhancements_ini.py` writes the text it adds through `_t(english, **values)` (#579): the English text is the key into the selected language's `languages//enhancements.json` (`src/utils/enhancement_text.py`, imported through the `src` shim with a no-table fallback), so English output is byte for byte what it was and a text with no translation stays English. `main(language=)` sets the table (`_set_text_language`); the worker passes the language it generates, and a CLI run over `cache/lang//base.ini` reads the language from that path. Data keys stay English (fire-mode and damage dict keys, mission flags, spawn buckets, the breakdown keys tags read) and are translated only where they are written. `--- STATS ---` and `--- EFFECT ---` are read back inside the script, so they are swapped only in `write_ini` (`_localize_separators`). Left as they are on purpose: the four mission section headers and the Rep label (user settings, and `owned_items.py` finds the POTENTIAL BLUEPRINTS header by its text), tags, item names, raw XML values, units and log lines. The lookup pickles hold XML facts only, so no translated text reaches them. A new `_t()` text needs `python tests/test_enhancement_text.py --write` and an entry in every language's table, which `tests/test_enhancement_text.py` enforces. + `generate_enhancements_ini.py` exposes `enhancements_mining_laser` and `enhancements_salvage_tool` (new in 1.4.0) alongside the ship-weapon / FPS-weapon / component generators. The mining-laser generator reads ship-mounted mining heads under `ships/weapons/mining_laser_*.xml` and emits per-mode (Fracture / Extraction) beam stats plus `SEntityComponentMiningLaserParams` modifier overlays. The salvage generator reads `weapons/fps_weapons/grin_*salvage_repair*.xml` and emits per-mode (Repair / Salvage) rate / efficiency / ramp / energy / heat / wear. Both exclude data that needs a `globalParams` UUID resolved into a base entity (base mining-laser power/range, ship-mounted salvage equipment); the scope cut is documented at the function level and locked by `tests/test_mining_salvage_stats.py`. ### Medical consumables (CureLife pens) — a static, non-DataForge category diff --git a/scripts/generate_enhancements_ini.py b/scripts/generate_enhancements_ini.py index f3a2ff60..5890c949 100644 --- a/scripts/generate_enhancements_ini.py +++ b/scripts/generate_enhancements_ini.py @@ -158,6 +158,53 @@ def strip_raw_blueprint_filename_prefix(stem): # type: ignore[misc] DATAFORGE_RECORDS_SUBPATH = Path("raw") / "libs" / "foundry" / "records" DATAFORGE_LOOKUPS_SUBPATH = Path(".lookups") +# ── Translated generated text (#579) ────────────────────────────────────────── +# Every label, word and sentence this script adds goes through _t(), keyed by +# its English text. main() fills _TEXT from languages// +# enhancements.json for the language it generates (src/utils/ +# enhancement_text.py), so a German run writes "Max. TP" where an English run +# writes "Max HP". A text with no translation stays English, and an English +# run (or a CLI run, or a test that calls a generator directly) has an empty +# table and writes exactly what it wrote before. The app loads this script +# afresh for every run, so the table never outlives one. Only text made for +# the INIs goes through _t: log lines, cache keys and anything matched later +# (fire-mode and damage keys, mission flags, spawn buckets) stay English, and +# are looked up only where a line is written. +try: + from src.utils.enhancement_text import load_table as _load_text_table +except ImportError: # pragma: no cover — only triggers if src/ is removed + def _load_text_table(language): # type: ignore[misc] + return {} + +_TEXT: dict[str, str] = {} + + +def _t(text: str, **values) -> str: + """*text* in the language being generated, English when it has no + translation. ``{name}`` placeholders are filled from *values*.""" + out = _TEXT.get(text, text) + return out.format(**values) if values else out + + +def _set_text_language(language: "str | None") -> None: + """Load the table _t() reads for *language* (None or English: none).""" + _TEXT.clear() + _TEXT.update(_load_text_table(language)) + + +# The two section labels. Code reads the English separators back (the +# _SCItem sibling copy and the stats-prepend tests), so they stay English +# until write_ini, which swaps in the translated label as each line is +# written. +_SEPARATOR_LABELS = ("--- STATS ---", "--- EFFECT ---") + + +def _localize_separators(value: str) -> str: + for label in _SEPARATOR_LABELS: + if label in value and label in _TEXT: + value = value.replace(label, _TEXT[label]) + return value + # ── Paths ───────────────────────────────────────────────────────────────────── @@ -282,7 +329,7 @@ def write_ini(path: Path, entries: dict[str, str]) -> None: path.parent.mkdir(parents=True, exist_ok=True) buf = io.StringIO() for k, v in sorted(entries.items()): - buf.write(f"{k}={v}\n") + buf.write(f"{k}={_localize_separators(v) if _TEXT else v}\n") # In one step, so a cut-off run leaves the old INI whole. Same bytes as # path.write_text: UTF-8, no BOM, CRLF on Windows. atomic_write_text(path, buf.getvalue()) @@ -798,18 +845,18 @@ def _synthesize_description(root: ET.Element, xml_file: Path, key: str) -> str: attrs: list[str] = [] career = vpc.get("vehicleCareer", "") if career.startswith("@"): - attrs.append(f"Class: {career.lstrip('@')}") + attrs.append(f"{_t('Class')}: {career.lstrip('@')}") role = vpc.get("vehicleRole", "") if role.startswith("@"): - attrs.append(f"Role: {role.lstrip('@')}") + attrs.append(f"{_t('Role')}: {role.lstrip('@')}") crew = vpc.get("crewSize", "") if crew: - attrs.append(f"Crew: {crew}") + attrs.append(f"{_t('Crew')}: {crew}") bbox = _find(root, "maxBoundingBoxSize") if bbox is not None: length = bbox.get("y", "") if length: - attrs.append(f"Length: {length}m") + attrs.append(f"{_t('Length')}: {length}m") if attrs: parts.append(" | ".join(attrs)) @@ -818,14 +865,14 @@ def _synthesize_description(root: ET.Element, xml_file: Path, key: str) -> str: if icp is not None: item_type = icp.get("itemType", "") if item_type: - parts.append(f"Item Type: {item_type}") + parts.append(f"{_t('Item Type')}: {item_type}") # 4. Missile tracking signal type tp = _find(root, "targetingParams") if tp is not None: sig = tp.get("trackingSignalType", "") if sig: - parts.append(f"Tracking: {sig}") + parts.append(f"{_t('Tracking')}: {sig}") return "\n".join(parts) if parts else key.replace("_", " ") @@ -1737,7 +1784,7 @@ def _fire_modes(root: ET.Element, loc: dict | None = None) -> list[str]: if "WeaponActionFire" in el.tag: # Prefer a clean label from the raw name attribute raw_name = (el.get("name") or "").strip() - label = _FIRE_MODE_LABELS.get(raw_name.lower()) + label = _t(_FIRE_MODE_LABELS.get(raw_name.lower(), "")) if not label: # Try localized name, stripping brackets. Skip CIG sentinel # loc-keys (e.g. @LOC_PLACEHOLDER) — they resolve to literal @@ -1855,10 +1902,10 @@ def _resist_pct(idx: int) -> str | None: lines = [] if hp is not None or regen is not None: - lines.append(f"Max HP: {_fmt(hp)} | Regen: {_fmt(regen, ' HP/s')}") + lines.append(f"{_t('Max HP')}: {_fmt(hp)} | {_t('Regen')}: {_fmt(regen, ' HP/s')}") delays = [] - if downed is not None: delays.append(f"Downed Delay: {_fmt(downed, 's', 1)}") - if damaged is not None: delays.append(f"Damaged Delay: {_fmt(damaged, 's', 1)}") + if downed is not None: delays.append(f"{_t('Downed Delay')}: {_fmt(downed, 's', 1)}") + if damaged is not None: delays.append(f"{_t('Damaged Delay')}: {_fmt(damaged, 's', 1)}") if delays: lines.append(" | ".join(delays)) @@ -1866,20 +1913,20 @@ def _resist_pct(idx: int) -> str | None: energy_resist = _resist_pct(1) if phys_resist or energy_resist: parts = [] - if phys_resist: parts.append(f"Phys: {phys_resist}") - if energy_resist: parts.append(f"Energy: {energy_resist}") + if phys_resist: parts.append(f"{_t('Phys')}: {phys_resist}") + if energy_resist: parts.append(f"{_t('Energy')}: {energy_resist}") lines.append("Resist: " + " | ".join(parts)) if em_sig is not None or ir_sig is not None: parts = [] - if em_sig is not None: parts.append(f"EM: {_fmt(em_sig)}") - if ir_sig is not None: parts.append(f"IR: {_fmt(ir_sig)}") + if em_sig is not None: parts.append(f"{_t('EM')}: {_fmt(em_sig)}") + if ir_sig is not None: parts.append(f"{_t('IR')}: {_fmt(ir_sig)}") lines.append("Signatures: " + " | ".join(parts)) if pwr is not None: - lines.append(f"Power Draw: {_fmt(pwr, ' PU/s')}") + lines.append(f"{_t('Power Draw')}: {_fmt(pwr, ' PU/s')}") if comp_hp is not None: - lines.append(f"Component HP: {_fmt(comp_hp)}") + lines.append(f"{_t('Component HP')}: {_fmt(comp_hp)}") return "\\n".join(lines) @@ -1900,7 +1947,7 @@ def enhancements_missile(root: ET.Element) -> str: try: vel_val = float(velocity) if vel_val > 0: - lines.append(f"Velocity: {vel_val:,.0f} m/s") + lines.append(f"{_t('Velocity')}: {vel_val:,.0f} m/s") except (ValueError, TypeError): pass @@ -1909,7 +1956,7 @@ def enhancements_missile(root: ET.Element) -> str: try: life_val = float(lifetime) if life_val > 0: - lines.append(f"Lifetime: {life_val:.2f}s") + lines.append(f"{_t('Lifetime')}: {life_val:.2f}s") except (ValueError, TypeError): pass @@ -1917,12 +1964,12 @@ def enhancements_missile(root: ET.Element) -> str: if "guidance" in el.tag.lower() or "tracking" in el.tag.lower(): guidance_type = el.get("guidanceType") or el.get("type") or el.tag.replace("Guidance", "").replace("Tracking", "") if guidance_type and "none" not in guidance_type.lower(): - lines.append(f"Guidance: {guidance_type}") + lines.append(f"{_t('Guidance')}: {guidance_type}") # Seeker type (passive vs active) seeker_type = el.get("seekerType") or el.get("seekerMode") if seeker_type and "none" not in seeker_type.lower(): - lines.append(f"Seeker: {seeker_type}") + lines.append(f"{_t('Seeker')}: {seeker_type}") # Lock-on time (how long to acquire lock) lock_time = el.get("lockTime") or el.get("lockOnTime") or el.get("lockAcquisitionTime") @@ -1930,7 +1977,7 @@ def enhancements_missile(root: ET.Element) -> str: try: time_val = float(lock_time) if time_val > 0: - lines.append(f"Lock Time: {time_val:.2f}s") + lines.append(f"{_t('Lock Time')}: {time_val:.2f}s") except (ValueError, TypeError): pass @@ -1940,7 +1987,7 @@ def enhancements_missile(root: ET.Element) -> str: try: min_val = float(min_lock) / 1000 # Convert to km if min_val > 0: - lines.append(f"Min Lock Range: {min_val:,.1f} km") + lines.append(f"{_t('Min Lock Range')}: {min_val:,.1f} km") except (ValueError, TypeError): pass @@ -1950,7 +1997,7 @@ def enhancements_missile(root: ET.Element) -> str: try: max_val = float(max_lock) / 1000 # Convert to km if max_val > 0: - lines.append(f"Max Lock Range: {max_val:,.1f} km") + lines.append(f"{_t('Max Lock Range')}: {max_val:,.1f} km") except (ValueError, TypeError): pass @@ -1960,7 +2007,7 @@ def enhancements_missile(root: ET.Element) -> str: try: track_val = float(track_range) / 1000 # Convert to km if track_val > 0: - lines.append(f"Tracking Range: {track_val:,.1f} km") + lines.append(f"{_t('Tracking Range')}: {track_val:,.1f} km") except (ValueError, TypeError): pass @@ -1970,7 +2017,7 @@ def enhancements_missile(root: ET.Element) -> str: try: prox_val = float(prox_range) if prox_val > 0: - lines.append(f"Proximity Range: {prox_val:,.0f} m") + lines.append(f"{_t('Proximity Range')}: {prox_val:,.0f} m") except (ValueError, TypeError): pass @@ -1980,7 +2027,7 @@ def enhancements_missile(root: ET.Element) -> str: try: g_val = float(max_g) if g_val > 0: - lines.append(f"Max G-Force: {g_val:.1f}G") + lines.append(f"{_t('Max G-Force')}: {g_val:.1f}G") except (ValueError, TypeError): pass @@ -1989,14 +2036,14 @@ def enhancements_missile(root: ET.Element) -> str: try: turn_val = float(turn_rate) if turn_val > 0: - lines.append(f"Turn Rate: {turn_val:.1f}°/s") + lines.append(f"{_t('Turn Rate')}: {turn_val:.1f}°/s") except (ValueError, TypeError): pass # Detonation mode detonation = el.get("detonationMode") or el.get("fuseMode") or el.get("detonationType") if detonation and "none" not in detonation.lower(): - lines.append(f"Detonation: {detonation}") + lines.append(f"{_t('Detonation')}: {detonation}") # Acceleration / Thrust if "propulsion" in el.tag.lower() or "thruster" in el.tag.lower() or "engine" in el.tag.lower(): @@ -2005,7 +2052,7 @@ def enhancements_missile(root: ET.Element) -> str: try: accel_val = float(accel) if accel_val > 0: - lines.append(f"Acceleration: {accel_val:,.1f} m/s²") + lines.append(f"{_t('Acceleration')}: {accel_val:,.1f} m/s²") except (ValueError, TypeError): pass @@ -2016,7 +2063,7 @@ def enhancements_missile(root: ET.Element) -> str: try: fuel_val = float(fuel_amount) if fuel_val > 0: - lines.append(f"Fuel: {fuel_val:.1f}s") + lines.append(f"{_t('Fuel')}: {fuel_val:.1f}s") except (ValueError, TypeError): pass except Exception: @@ -2041,11 +2088,11 @@ def _fmt_range_m(v: float) -> str: return f"{v / 1000:,.1f} km" if v >= 1000 else f"{v:,.0f} m" if lmn is not None and lmn > 0 and lmx is not None and lmx > 0: - lines.append(f"Lock Range: {_fmt_range_m(lmn)} – {_fmt_range_m(lmx)}") + lines.append(f"{_t('Lock Range')}: {_fmt_range_m(lmn)} – {_fmt_range_m(lmx)}") elif lmn is not None and lmn > 0: - lines.append(f"Min Lock Range: {_fmt_range_m(lmn)}") + lines.append(f"{_t('Min Lock Range')}: {_fmt_range_m(lmn)}") elif lmx is not None and lmx > 0: - lines.append(f"Max Lock Range: {_fmt_range_m(lmx)}") + lines.append(f"{_t('Max Lock Range')}: {_fmt_range_m(lmx)}") # Arming — `armTime` (seconds before warhead arms) and # `explosionSafetyDistance` (meters within which the missile won't @@ -2072,12 +2119,12 @@ def _fmt_range_m(v: float) -> str: arm_parts = [] if arm_t and arm_t > 0: - arm_parts.append(f"Arm Time: {arm_t:.1f}s") + arm_parts.append(f"{_t('Arm Time')}: {arm_t:.1f}s") if arm_t and arm_t > 0 and speed and speed > 0: arm_dist = arm_t * speed - arm_parts.append(f"Arm Dist: {_fmt_range_m(arm_dist)}") + arm_parts.append(f"{_t('Arm Dist')}: {_fmt_range_m(arm_dist)}") if safety and safety > 0: - arm_parts.append(f"Min Detonate: {safety:,.0f} m") + arm_parts.append(f"{_t('Min Detonate')}: {safety:,.0f} m") if arm_parts: lines.append(" | ".join(arm_parts)) @@ -2088,10 +2135,10 @@ def _fmt_range_m(v: float) -> str: if total_dmg and total_dmg > 0: type_str = "" if breakdown and len(breakdown) == 1: - type_str = f" ({list(breakdown.keys())[0]})" + type_str = f" ({_t(list(breakdown.keys())[0])})" elif breakdown and len(breakdown) > 1: - type_str = " (" + " / ".join(f"{lbl}: {v:.1f}" for lbl, v in breakdown.items()) + ")" - lines.append(f"Damage: {_fmt(total_dmg, '', 1)}{type_str}") + type_str = " (" + " / ".join(f"{_t(lbl)}: {v:.1f}" for lbl, v in breakdown.items()) + ")" + lines.append(f"{_t('Damage')}: {_fmt(total_dmg, '', 1)}{type_str}") # Blast radius (warhead explosion radius) blast = _attr(root, "ExplosionParams", "maxRadius") @@ -2105,7 +2152,7 @@ def _fmt_range_m(v: float) -> str: try: blast_val = float(blast) if blast_val > 0: - lines.append(f"Blast Radius: {blast_val:,.0f} m") + lines.append(f"{_t('Blast Radius')}: {blast_val:,.0f} m") except (ValueError, TypeError): pass @@ -2115,7 +2162,7 @@ def _fmt_range_m(v: float) -> str: try: eff_val = float(eff_range) / 1000 # Convert to km if eff_val > 0: - lines.append(f"Effective Range: {eff_val:,.1f} km") + lines.append(f"{_t('Effective Range')}: {eff_val:,.1f} km") except (ValueError, TypeError): pass @@ -2125,7 +2172,7 @@ def _fmt_range_m(v: float) -> str: try: em_val = float(em_sig) if em_val > 0: - lines.append(f"EM Signature: {em_val:,.0f}") + lines.append(f"{_t('EM Signature')}: {em_val:,.0f}") except (ValueError, TypeError): pass @@ -2134,14 +2181,14 @@ def _fmt_range_m(v: float) -> str: try: ir_val = float(ir_sig) if ir_val > 0: - lines.append(f"IR Signature: {ir_val:,.0f}") + lines.append(f"{_t('IR Signature')}: {ir_val:,.0f}") except (ValueError, TypeError): pass # Component HP comp_hp = _attr(root, "SHealthComponentParams", "Health") if comp_hp is not None: - lines.append(f"Component HP: {_fmt(comp_hp)}") + lines.append(f"{_t('Component HP')}: {_fmt(comp_hp)}") except Exception: pass @@ -2173,13 +2220,13 @@ def enhancements_bomb_rack(root: ET.Element) -> str: lines = [] if size: - lines.append(f"Size: S{size}") + lines.append(f"{_t('Size')}: S{size}") if grade: - lines.append(f"Grade: {grade}") + lines.append(f"{_t('Grade')}: {grade}") if slot_count > 0: - lines.append(f"Bomb Slots: {slot_count}") + lines.append(f"{_t('Bomb Slots')}: {slot_count}") if comp_hp: - lines.append(f"Component HP: {_fmt(comp_hp)}") + lines.append(f"{_t('Component HP')}: {_fmt(comp_hp)}") return "\\n".join(lines) if lines else "" @@ -2210,7 +2257,7 @@ def enhancements_radar(root: ET.Element) -> str: except (TypeError, ValueError): min_v = max_v = None if min_v is not None and max_v is not None and max_v > 0: - lines.append(f"Aim Assist Range: {min_v:,.0f}–{max_v:,.0f} m") + lines.append(f"{_t('Aim Assist Range')}: {min_v:,.0f}–{max_v:,.0f} m") break # Ping cooldown (seconds between active radar pings). @@ -2219,7 +2266,7 @@ def enhancements_radar(root: ET.Element) -> str: if cd: try: cd_v = float(cd) - lines.append(f"Ping Cooldown: {cd_v:.1f}s") + lines.append(f"{_t('Ping Cooldown')}: {cd_v:.1f}s") except (TypeError, ValueError): pass break @@ -2241,17 +2288,17 @@ def enhancements_radar(root: ET.Element) -> str: if active_capable: modes.append("Active") if modes: - lines.append(f"Detection Mode: {' / '.join(modes)}") + lines.append(f"{_t('Detection Mode')}: {' / '.join(modes)}") # Power consumption. pwr = _find_resource(root, "Power") if pwr is not None: - lines.append(f"Power Draw: {_fmt(pwr, ' PU/s')}") + lines.append(f"{_t('Power Draw')}: {_fmt(pwr, ' PU/s')}") # Component health. comp_hp = _attr(root, "SHealthComponentParams", "Health") if comp_hp is not None: - lines.append(f"Component HP: {_fmt(comp_hp)}") + lines.append(f"{_t('Component HP')}: {_fmt(comp_hp)}") return "\\n".join(lines) if lines else "" @@ -2266,22 +2313,22 @@ def enhancements_cooler(root: ET.Element) -> str: lines = [] if cooling is not None: - lines.append(f"Cooling Rate: {_fmt(cooling, ' CR/s')}") + lines.append(f"{_t('Cooling Rate')}: {_fmt(cooling, ' CR/s')}") if pwr is not None: - lines.append(f"Power Draw: {_fmt(pwr, ' PU/s')}") + lines.append(f"{_t('Power Draw')}: {_fmt(pwr, ' PU/s')}") if comp_hp is not None: - lines.append(f"Component HP: {_fmt(comp_hp)}") + lines.append(f"{_t('Component HP')}: {_fmt(comp_hp)}") if em_sig is not None or ir_sig is not None: parts = [] - if em_sig is not None: parts.append(f"EM: {_fmt(em_sig)}") - if ir_sig is not None: parts.append(f"IR: {_fmt(ir_sig)}") + if em_sig is not None: parts.append(f"{_t('EM')}: {_fmt(em_sig)}") + if ir_sig is not None: parts.append(f"{_t('IR')}: {_fmt(ir_sig)}") lines.append("Signatures: " + " | ".join(parts)) if overheat is not None: try: if float(overheat) < _OVERHEAT_PLACEHOLDER: - lines.append(f"Overheat Temp: {_fmt(overheat, 'K')}") + lines.append(f"{_t('Overheat Temp')}: {_fmt(overheat, 'K')}") except (ValueError, TypeError): - lines.append(f"Overheat Temp: {_fmt(overheat, 'K')}") + lines.append(f"{_t('Overheat Temp')}: {_fmt(overheat, 'K')}") return "\\n".join(lines) @@ -2295,22 +2342,22 @@ def enhancements_powerplant(root: ET.Element) -> str: lines = [] if gen is not None: - lines.append(f"Power Output: {_fmt(gen, ' PU/s')}") + lines.append(f"{_t('Power Output')}: {_fmt(gen, ' PU/s')}") if comp_hp is not None: - lines.append(f"Component HP: {_fmt(comp_hp)}") + lines.append(f"{_t('Component HP')}: {_fmt(comp_hp)}") if em_sig is not None or ir_sig is not None: parts = [] - if em_sig is not None: parts.append(f"EM: {_fmt(em_sig)}") - if ir_sig is not None: parts.append(f"IR: {_fmt(ir_sig)}") + if em_sig is not None: parts.append(f"{_t('EM')}: {_fmt(em_sig)}") + if ir_sig is not None: parts.append(f"{_t('IR')}: {_fmt(ir_sig)}") lines.append("Signatures: " + " | ".join(parts)) if overheat is not None: try: if float(overheat) < _OVERHEAT_PLACEHOLDER: - lines.append(f"Overheat Temp: {_fmt(overheat, 'K')}") + lines.append(f"{_t('Overheat Temp')}: {_fmt(overheat, 'K')}") except (ValueError, TypeError): - lines.append(f"Overheat Temp: {_fmt(overheat, 'K')}") + lines.append(f"{_t('Overheat Temp')}: {_fmt(overheat, 'K')}") if distort is not None: - lines.append(f"Max Distortion: {_fmt(distort)}") + lines.append(f"{_t('Max Distortion')}: {_fmt(distort)}") return "\\n".join(lines) @@ -2353,37 +2400,37 @@ def enhancements_quantum_drive(root: ET.Element) -> str: # Tenths, as Cooldown below: spool times are 4.4, 4.8, 5.3, 8.5... and # whole seconds showed 4.8 and 5.3 both as "5s" (#485). spool_str = _fmt(spool, "s", 1) if spool else "?" - lines.append(f"QT Speed: {speed_mm:,.0f} Mm/s | Spool: {spool_str}") + lines.append(f"{_t('QT Speed')}: {speed_mm:,.0f} Mm/s | {_t('Spool')}: {spool_str}") if cooldown is not None: - lines.append(f"Cooldown: {_fmt(cooldown, 's', 1)}") + lines.append(f"{_t('Cooldown')}: {_fmt(cooldown, 's', 1)}") if fuel_req is not None: - lines.append(f"Fuel/Gm: {float(fuel_req):.4f}") + lines.append(f"{_t('Fuel/Gm')}: {float(fuel_req):.4f}") if qt_fuel is not None: - lines.append(f"QT Fuel Use: {_fmt(qt_fuel)} μ/s") + lines.append(f"{_t('QT Fuel Use')}: {_fmt(qt_fuel)} μ/s") if accel1 is not None or accel2 is not None: parts = [] if accel1: parts.append(f"S1: {_fmt(accel1)}") if accel2: parts.append(f"S2: {_fmt(accel2)}") lines.append("Accel: " + " | ".join(parts)) if cal_rate is not None: - lines.append(f"Cal Rate: {_fmt(cal_rate)} | Required: {_fmt(cal_min)}–{_fmt(cal_max)}") + lines.append(f"{_t('Cal Rate')}: {_fmt(cal_rate)} | {_t('Required')}: {_fmt(cal_min)}–{_fmt(cal_max)}") if pwr is not None: - lines.append(f"Power Draw: {_fmt(pwr, ' PU/s')}") + lines.append(f"{_t('Power Draw')}: {_fmt(pwr, ' PU/s')}") if comp_hp is not None: - lines.append(f"Component HP: {_fmt(comp_hp)}") + lines.append(f"{_t('Component HP')}: {_fmt(comp_hp)}") if em_sig is not None or ir_sig is not None: parts = [] - if em_sig is not None: parts.append(f"EM: {_fmt(em_sig)}") - if ir_sig is not None: parts.append(f"IR: {_fmt(ir_sig)}") + if em_sig is not None: parts.append(f"{_t('EM')}: {_fmt(em_sig)}") + if ir_sig is not None: parts.append(f"{_t('IR')}: {_fmt(ir_sig)}") lines.append("Signatures: " + " | ".join(parts)) if overheat is not None: try: if float(overheat) < _OVERHEAT_PLACEHOLDER: - lines.append(f"Overheat Temp: {_fmt(overheat, 'K')}") + lines.append(f"{_t('Overheat Temp')}: {_fmt(overheat, 'K')}") except (ValueError, TypeError): - lines.append(f"Overheat Temp: {_fmt(overheat, 'K')}") + lines.append(f"{_t('Overheat Temp')}: {_fmt(overheat, 'K')}") if distort is not None: - lines.append(f"Max Distortion: {_fmt(distort)}") + lines.append(f"{_t('Max Distortion')}: {_fmt(distort)}") return "\\n".join(lines) @@ -2426,7 +2473,7 @@ def enhancements_mining_laser(root: ET.Element) -> str: # Mode label from mannequinTag (laser/tractor) → human label. mannequin = fa.find("mannequinTag") mtag = mannequin.get("tag") if mannequin is not None else "" - mode = {"laser": "Fracture", "tractor": "Extraction"}.get(mtag, f"Beam {idx}") + mode = {"laser": _t("Fracture"), "tractor": _t("Extraction")}.get(mtag) or f"{_t('Beam')} {idx}" dps_el = fa.find("damagePerSecond/DamageInfo") dps = dps_el.get("DamageEnergy") if dps_el is not None else None @@ -2446,23 +2493,23 @@ def enhancements_mining_laser(root: ET.Element) -> str: continue parts: list[str] = [] if dps not in (None, "0", "0.0"): - parts.append(f"DPS: {_fmt(dps)}") + parts.append(f"{_t('DPS')}: {_fmt(dps)}") if full_r not in (None, "0", "0.0") or zero_r not in (None, "0", "0.0"): # En dash, not the arrow "→" this used to use — the in-game # Vehicle Loadout Manager's item-description font has no glyph # for it and renders a fallback box character instead (reported # on GitHub). The en dash is already used for Energy just below # and reads fine there, so it's a safe, tested-working choice. - parts.append(f"Range: {_fmt(full_r, 'm')}–{_fmt(zero_r, 'm')}") + parts.append(f"{_t('Range')}: {_fmt(full_r, 'm')}–{_fmt(zero_r, 'm')}") if e_max not in (None, "0", "0.0"): if e_min and e_min != e_max and e_min not in ("0", "0.0"): - parts.append(f"Energy: {_fmt(e_min)}–{_fmt(e_max)} PU/s") + parts.append(f"{_t('Energy')}: {_fmt(e_min)}–{_fmt(e_max)} PU/s") else: - parts.append(f"Energy: {_fmt(e_max)} PU/s") + parts.append(f"{_t('Energy')}: {_fmt(e_max)} PU/s") if heat_s not in (None, "0", "0.0"): - parts.append(f"Heat: {_fmt(heat_s)}/s") + parts.append(f"{_t('Heat')}: {_fmt(heat_s)}/s") if wear_s not in (None, "0", "0.0"): - parts.append(f"Wear: {wear_s}/s") + parts.append(f"{_t('Wear')}: {wear_s}/s") if parts: # Plain label, not -wrapped — matches every other component # extractor (enhancements_shield etc.) and avoids the Vehicle @@ -2495,7 +2542,7 @@ def enhancements_mining_laser(root: ET.Element) -> str: fval = filter_fm.get("value") if fval and fval not in ("0", "0.0"): sign = "+" if float(fval) > 0 else "" - mod_parts.append(f"Inert Filter: {sign}{fval}%") + mod_parts.append(f"{_t('Inert Filter')}: {sign}{fval}%") if mod_parts: lines.append("Modifiers: " + " | ".join(mod_parts)) @@ -2503,18 +2550,18 @@ def enhancements_mining_laser(root: ET.Element) -> str: # signatures if they happen to be present on a ship-mountable laser. comp_hp = _attr(root, "SHealthComponentParams", "Health") if comp_hp is not None: - lines.append(f"Component HP: {_fmt(comp_hp)}") + lines.append(f"{_t('Component HP')}: {_fmt(comp_hp)}") distort = _attr(root, "SDistortionParams", "Maximum") if distort is not None and distort not in ("0", "0.0"): - lines.append(f"Max Distortion: {_fmt(distort)}") + lines.append(f"{_t('Max Distortion')}: {_fmt(distort)}") em_sig = _attr(root, "EMSignature", "nominalSignature") ir_sig = _attr(root, "IRSignature", "nominalSignature") if em_sig is not None or ir_sig is not None: sig_parts: list[str] = [] if em_sig is not None and em_sig not in ("0", "0.0"): - sig_parts.append(f"EM: {_fmt(em_sig)}") + sig_parts.append(f"{_t('EM')}: {_fmt(em_sig)}") if ir_sig is not None and ir_sig not in ("0", "0.0"): - sig_parts.append(f"IR: {_fmt(ir_sig)}") + sig_parts.append(f"{_t('IR')}: {_fmt(ir_sig)}") if sig_parts: lines.append("Signatures: " + " | ".join(sig_parts)) @@ -2557,30 +2604,30 @@ def enhancements_salvage_tool(root: ET.Element) -> str: parts: list[str] = [] if hp_rate not in (None, "0", "0.0"): - parts.append(f"HP Rate: {_fmt(hp_rate)}/s") + parts.append(f"{_t('HP Rate')}: {_fmt(hp_rate)}/s") if dmg_rate not in (None, "0", "0.0"): - parts.append(f"Damage-Map Rate: {_fmt(dmg_rate)}/s") + parts.append(f"{_t('Damage-Map Rate')}: {_fmt(dmg_rate)}/s") if eff not in (None, "1", "1.0"): # 1.0 is the default no-op — only emit when CIG actually tunes # below unity (Renovar Salvage mode runs at 0.7 efficiency). - parts.append(f"Material Efficiency: {_fmt(eff, '', 2)}") + parts.append(f"{_t('Material Efficiency')}: {_fmt(eff, '', 2)}") if h2a not in (None, "0", "0.0"): - parts.append(f"HP/Ammo: {_fmt(h2a, '', 2)}") + parts.append(f"{_t('HP/Ammo')}: {_fmt(h2a, '', 2)}") if ramp_up not in (None, "0", "0.0") or ramp_dn not in (None, "0", "0.0"): # Plain "up"/"down" words, not the "↑"/"↓" arrows this used to # use — same missing-glyph issue as the mining-laser Range line # (see the note there): the in-game item-description font has # no glyph for them and shows a fallback box character instead. - parts.append(f"Ramp: {_fmt(ramp_up, 's', 1)} up, {_fmt(ramp_dn, 's', 1)} down") + parts.append(f"{_t('Ramp')}: {_fmt(ramp_up, 's', 1)} {_t('up')}, {_fmt(ramp_dn, 's', 1)} {_t('down')}") if e_max not in (None, "0", "0.0"): if e_min and e_min != e_max and e_min not in ("0", "0.0"): - parts.append(f"Energy: {_fmt(e_min)}–{_fmt(e_max)} PU/s") + parts.append(f"{_t('Energy')}: {_fmt(e_min)}–{_fmt(e_max)} PU/s") else: - parts.append(f"Energy: {_fmt(e_max)} PU/s") + parts.append(f"{_t('Energy')}: {_fmt(e_max)} PU/s") if heat_s not in (None, "0", "0.0"): - parts.append(f"Heat: {_fmt(heat_s)}/s") + parts.append(f"{_t('Heat')}: {_fmt(heat_s)}/s") if wear_s not in (None, "0", "0.0"): - parts.append(f"Wear: {wear_s}/s") + parts.append(f"{_t('Wear')}: {wear_s}/s") if parts: # Plain label — see the matching note in enhancements_mining_laser. lines.append(f"{mode}: " + " | ".join(parts)) @@ -2588,10 +2635,10 @@ def enhancements_salvage_tool(root: ET.Element) -> str: # Structural stats (durability / wear) — same pattern as mining lasers. comp_hp = _attr(root, "SHealthComponentParams", "Health") if comp_hp is not None and comp_hp not in ("0", "0.0"): - lines.append(f"Component HP: {_fmt(comp_hp)}") + lines.append(f"{_t('Component HP')}: {_fmt(comp_hp)}") wear_max = _attr(root, "SWearAccumulatorParams", "MaxLifetimeHours") if wear_max is not None and wear_max not in ("0", "0.0"): - lines.append(f"Max Lifetime: {_fmt(wear_max, 'h', 1)}") + lines.append(f"{_t('Max Lifetime')}: {_fmt(wear_max, 'h', 1)}") return "\\n".join(lines) if lines else "" @@ -3014,8 +3061,10 @@ def _format_spawn_lines(breakdown: SpawnBreakdown) -> list[str]: items = breakdown.get(bucket) or {} if not items: continue - parts = [f"{lbl} x{cnt}" for lbl, cnt in sorted(items.items())] - lines.append(f"{header}: {', '.join(parts)}") + # Sorted by the English label, so the order is the same in every + # language and only the words change. + parts = [f"{_t(lbl)} x{cnt}" for lbl, cnt in sorted(items.items())] + lines.append(f"{_t(header)}: {', '.join(parts)}") return lines @@ -3081,11 +3130,11 @@ def _extract_turret_info(root: ET.Element) -> str | None: if turret_count == 0 and explicit_hostility is None: return None - count_str = str(turret_count) if turret_count > 0 else "present" + count_str = str(turret_count) if turret_count > 0 else _t("present") if explicit_hostility is False: - return f"{count_str} (friendly)" - return f"{count_str} (hostile)" + return f"{count_str} ({_t('friendly')})" + return f"{count_str} ({_t('hostile')})" def _parse_difficulty_rating(value: str) -> int: @@ -3119,13 +3168,13 @@ def _extract_difficulty(element: ET.Element) -> str: if any([combat, complexity, risk, knowledge]): parts = [] if combat: - parts.append(f"Combat {combat}/7") + parts.append(f"{_t('Combat')} {combat}/7") if complexity: - parts.append(f"Complexity {complexity}/7") + parts.append(f"{_t('Complexity')} {complexity}/7") if risk: - parts.append(f"Risk {risk}/7") + parts.append(f"{_t('Risk')} {risk}/7") if knowledge: - parts.append(f"Knowledge {knowledge}/7") + parts.append(f"{_t('Knowledge')} {knowledge}/7") return " | ".join(parts) # Fallback: simple missionDifficulty attribute (pu_missions) @@ -3209,15 +3258,15 @@ def _show(f: str) -> bool: try: loc_key = _mission_loc_key(root) or _loc_key(root) - lines.append(f"Engagement Type: {_classify_mission_engagement(loc_key)}") + lines.append(f"{_t('Engagement Type')}: {_t(_classify_mission_engagement(loc_key))}") flags = _extract_mission_flags(root) if _show("mission_type"): - lines.append(f"Mission Type: {', '.join(flags) if flags else 'Standard'}") + lines.append(f"{_t('Mission Type')}: {', '.join(_t(f) for f in flags) if flags else _t('Standard')}") difficulty = _extract_difficulty(root) if difficulty and _show("difficulty"): - lines.append(f"Difficulty (1-7): {difficulty}") + lines.append(f"{_t('Difficulty (1-7)')}: {difficulty}") total_rep_xp = _extract_mission_xp(root, reputation_lookup) if total_rep_xp > 0 and _show("reputation"): @@ -3247,7 +3296,7 @@ def _show(f: str) -> bool: # adjacently in the MISSION DETAILS block. turret_info = _extract_turret_info(root) if turret_info: - lines.append(f"Turrets: {turret_info}") + lines.append(f"{_t('Turrets')}: {turret_info}") except Exception: pass @@ -3320,10 +3369,10 @@ def _pool_rank_label(pool_name: str) -> str: return "" m = _POOL_RANK_RANGE_RE.search(pool_name) if m: - return f"Rank {m.group(1)}–{m.group(2)}" # en-dash + return f"{_t('Rank')} {m.group(1)}–{m.group(2)}" # en-dash m = _POOL_RANK_SINGLE_RE.search(pool_name) if m: - return f"Rank {m.group(1)}" + return f"{_t('Rank')} {m.group(1)}" return "" @@ -3574,7 +3623,7 @@ def _bullets(names) -> str: for header, fp in header_entries: if header_counts[header] > 1: representative = fp[0] if fp else "Unknown" - header = f"{header}, {representative} Set" + header = f"{header}, " + _t("{item} Set", item=representative) named_entries.append((header, fp)) # Pass 2: safety net for the rare case where two colliding sets happen @@ -3950,7 +3999,7 @@ def _format_rs_details_lines(ores: list[str], loc: dict) -> list[str]: lines.append(f"{label}: {' - '.join(str(v) for v in steps)}") if not lines: return [] - return ["Resource Signatures:"] + lines + return [f"{_t('Resource Signatures')}:"] + lines def _build_mineable_rs_name_overrides(loc: dict) -> dict[str, str]: @@ -4881,7 +4930,7 @@ def _humanize_craft_category(cat: str) -> str: return cat label = _CRAFT_CATEGORY_LABELS.get(parts[-1].lower()) if label: - return label + return _t(label) if len(parts) >= 2: label = _CRAFT_CATEGORY_LABELS.get("/".join(parts[-2:]).lower()) if label: @@ -4993,8 +5042,10 @@ def _condense_crafted_items(items_list: list[tuple[str, str]]) -> list[str]: names = sorted(set(by_cat[cat])) parts = cat.split("/") if "ammo" in cat: - ammo_type = parts[-1].title() if len(parts) > 2 else "Ammo" - lines.append(f"{ammo_type} Ammo") + if len(parts) > 2: + lines.append(_t("{type} Ammo", type=parts[-1].title())) + else: + lines.append(_t("{type} Ammo", type=_t("Ammo"))) continue if "weapons" in cat: base_names = set() @@ -5006,11 +5057,11 @@ def _condense_crafted_items(items_list: list[tuple[str, str]]) -> list[str]: lines.append(", ".join(sorted(base_names))) else: weapon_type = parts[-1].title() - lines.append(f"{weapon_type}s ({len(base_names)} types)") + lines.append(f"{weapon_type}s (" + _t("{count} types", count=len(base_names)) + ")") continue if "armour" in cat: weight = parts[-1].title() if len(parts) > 2 else "" - armour_type = parts[-2].title() if len(parts) > 2 else "Armour" + armour_type = parts[-2].title() if len(parts) > 2 else _t("Armour") set_names = set() for n in names: m2 = re.match(r'^([\w-]+(?:\s[\w-]+)?)\s+(?:Arms|Core|Legs|Helmet|Backpack|Suit|Armor)', n) @@ -5021,7 +5072,7 @@ def _condense_crafted_items(items_list: list[tuple[str, str]]) -> list[str]: if len(set_names) <= 3: label = ", ".join(sorted(set_names)) else: - label = f"{len(set_names)} sets" + label = _t("{count} sets", count=len(set_names)) if weight and armour_type != weight: lines.append(f"{label} ({weight} {armour_type})") else: @@ -5032,9 +5083,9 @@ def _condense_crafted_items(items_list: list[tuple[str, str]]) -> list[str]: qd_count += len(names) qd_sizes.append(int(qd.group(1))) continue - lines.append(f"{_humanize_craft_category(cat)}: {len(names)} items") + lines.append(f"{_humanize_craft_category(cat)}: " + _t("{count} items", count=len(names))) if qd_count: - lines.append(f"Quantum Drives: {qd_count} items ({_qd_size_range(qd_sizes)})") + lines.append(f"{_t('Quantum Drives')}: " + _t("{count} items", count=qd_count) + f" ({_qd_size_range(qd_sizes)})") lines.sort(key=str.lower) return lines @@ -5355,7 +5406,7 @@ def scan_crafting_blueprints( sections = [] loc_list = _lookup_commodity_locations(mineral_locations, base_name, commodity) if loc_list: - loc_block = (f"<{header_em_tag}>Locations:\\n" + loc_block = (f"<{header_em_tag}>{_t('Locations')}:\\n" + "\\n".join(f"- {loc_}" for loc_ in loc_list)) sections.append(loc_block) sections.append(enhancements_block) @@ -5452,13 +5503,13 @@ def scan_crafting_blueprints( ore_key = _MINING_COMPENDIUM_ORE_ALIASES.get(name.lower(), name.lower()) rs_value = MINEABLE_RS_VALUES.get(ore_key) if rs_value is not None: - block += [f"Base Resource Signature: {rs_value}", ""] + block += [f"{_t('Base Resource Signature')}: {rs_value}", ""] rs_ores_tagged += 1 - block += ["Locations:"] + block += [f"{_t('Locations')}:"] block += [f"- {loc_}" for loc_ in locations] craft = mineral_crafting.get(name.lower()) if craft: - block += ["", "Used To Craft:"] + block += ["", f"{_t('Used To Craft')}:"] block += [f"- {item}" for item in craft] augmented_lines.append("\\n".join(block)) else: @@ -5603,31 +5654,31 @@ def enhancements_weapon(root: ET.Element, ammo_lookup: dict[str, ET.Element], lines = [] if weight is not None and weight > 0: - lines.append(f"Weight: {weight:.1f} kg") + lines.append(f"{_t('Weight')}: {weight:.1f} kg") if fr: - lines.append(f"Fire Rate: {_fmt(fr, ' RPM')}") + lines.append(f"{_t('Fire Rate')}: {_fmt(fr, ' RPM')}") if modes: - lines.append(f"Fire Modes: {' / '.join(modes)}") + lines.append(f"{_t('Fire Modes')}: {' / '.join(modes)}") # Damage line with per-type breakdown if total_dmg is not None and total_dmg > 0: type_str = "" if breakdown and len(breakdown) == 1: - type_str = f" ({list(breakdown.keys())[0]})" + type_str = f" ({_t(list(breakdown.keys())[0])})" elif breakdown and len(breakdown) > 1: - type_str = " (" + " / ".join(f"{lbl}: {v:.1f}" for lbl, v in breakdown.items()) + ")" + type_str = " (" + " / ".join(f"{_t(lbl)}: {v:.1f}" for lbl, v in breakdown.items()) + ")" pellet_str = f" x{pellet_count}" if pellet_count > 1 else "" - dmg_part = f"Alpha Dmg: {_fmt(total_dmg, '', 1)}{pellet_str}{type_str}" - dps_part = f"DPS: {_fmt(dps, '', 1)}" if dps else "" + dmg_part = f"{_t('Alpha Dmg')}: {_fmt(total_dmg, '', 1)}{pellet_str}{type_str}" + dps_part = f"{_t('DPS')}: {_fmt(dps, '', 1)}" if dps else "" lines.append(" | ".join(p for p in [dmg_part, dps_part] if p)) if capacity: - lines.append(f"Ammo: {_fmt(capacity)}") + lines.append(f"{_t('Ammo')}: {_fmt(capacity)}") if regen_rate or regen_cooldown: parts = [] - if regen_rate: parts.append(f"Regen: {_fmt(regen_rate)}/s") - if regen_cooldown: parts.append(f"Cooldown: {_fmt(regen_cooldown, 's', 1)}") - if regen_cost: parts.append(f"Cost/Shot: {_fmt(regen_cost)}") + if regen_rate: parts.append(f"{_t('Regen')}: {_fmt(regen_rate)}/s") + if regen_cooldown: parts.append(f"{_t('Cooldown')}: {_fmt(regen_cooldown, 's', 1)}") + if regen_cost: parts.append(f"{_t('Cost/Shot')}: {_fmt(regen_cost)}") lines.append(" | ".join(parts)) if proj_speed is not None: try: @@ -5639,31 +5690,31 @@ def enhancements_weapon(root: ET.Element, ammo_lookup: dict[str, ET.Element], # range); ship weapons keep "Range" since the field has been # stable there for releases. magazine_lookup is the FPS # discriminator — only the FPS callsite passes it. - range_label = "Absolute Range" if magazine_lookup is not None else "Range" + range_label = _t("Absolute Range") if magazine_lookup is not None else _t("Range") if rng_m >= 1000: - lines.append(f"Velocity: {_fmt(proj_speed, ' m/s')} | {range_label}: {rng_m / 1000:,.1f} km") + lines.append(f"{_t('Velocity')}: {_fmt(proj_speed, ' m/s')} | {range_label}: {rng_m / 1000:,.1f} km") else: - lines.append(f"Velocity: {_fmt(proj_speed, ' m/s')} | {range_label}: {rng_m:,.0f} m") + lines.append(f"{_t('Velocity')}: {_fmt(proj_speed, ' m/s')} | {range_label}: {rng_m:,.0f} m") except (TypeError, ValueError): pass # Damage drop-off if dmg_drop_min_dist is not None and dmg_drop_min_dist > 0: - drop_parts = [f"Full Dmg to: {dmg_drop_min_dist:.0f} m"] + drop_parts = [f"{_t('Full Dmg to')}: {dmg_drop_min_dist:.0f} m"] if dmg_drop_per_m is not None and dmg_drop_per_m > 0: - drop_parts.append(f"Drop: -{dmg_drop_per_m:.2f}/m") + drop_parts.append(f"{_t('Drop')}: -{dmg_drop_per_m:.2f}/m") if dmg_drop_min is not None and dmg_drop_min > 0: - drop_parts.append(f"Min Dmg: {dmg_drop_min:.1f}") + drop_parts.append(f"{_t('Min Dmg')}: {dmg_drop_min:.1f}") lines.append(" | ".join(drop_parts)) if pwr: - lines.append(f"Power Draw: {_fmt(pwr, ' PU/s')}") + lines.append(f"{_t('Power Draw')}: {_fmt(pwr, ' PU/s')}") if comp_hp is not None: - lines.append(f"Component HP: {_fmt(comp_hp)}") + lines.append(f"{_t('Component HP')}: {_fmt(comp_hp)}") if em_sig is not None or ir_sig is not None: parts = [] - if em_sig is not None: parts.append(f"EM: {_fmt(em_sig)}") - if ir_sig is not None: parts.append(f"IR: {_fmt(ir_sig)}") + if em_sig is not None: parts.append(f"{_t('EM')}: {_fmt(em_sig)}") + if ir_sig is not None: parts.append(f"{_t('IR')}: {_fmt(ir_sig)}") lines.append("Signatures: " + " | ".join(parts)) # Overheat temp is meaningful for ship weapons but not surfaced in-game # for FPS weapons; skip it on the FPS path (magazine_lookup is the FPS @@ -5671,9 +5722,9 @@ def enhancements_weapon(root: ET.Element, ammo_lookup: dict[str, ET.Element], if overheat is not None and magazine_lookup is None: try: if float(overheat) < _OVERHEAT_PLACEHOLDER: - lines.append(f"Overheat Temp: {_fmt(overheat, 'K')}") + lines.append(f"{_t('Overheat Temp')}: {_fmt(overheat, 'K')}") except (ValueError, TypeError): - lines.append(f"Overheat Temp: {_fmt(overheat, 'K')}") + lines.append(f"{_t('Overheat Temp')}: {_fmt(overheat, 'K')}") return "\\n".join(lines) @@ -5757,7 +5808,7 @@ def summarize_slots(slots: list[tuple[str, bool]]) -> str: counts[key] = counts.get(key, 0) + 1 parts = [] for (sz, filled), cnt in sorted(counts.items()): - suffix = "" if filled else " (empty)" + suffix = "" if filled else f" ({_t('empty')})" if sz == "?": # Unknown size: show just count (e.g. turrets with no size info) parts.append(str(cnt)) @@ -5778,21 +5829,21 @@ def summarize_items(sizes: list[str]) -> str: weapon_parts = [] if guns: - weapon_parts.append(f"Guns: {summarize_slots(guns)}") + weapon_parts.append(f"{_t('Guns')}: {summarize_slots(guns)}") if turrets: - weapon_parts.append(f"Turrets: {summarize_slots(turrets)}") + weapon_parts.append(f"{_t('Turrets')}: {summarize_slots(turrets)}") if mracks: - weapon_parts.append(f"MRacks: {summarize_slots(mracks)}") + weapon_parts.append(f"{_t('MRacks')}: {summarize_slots(mracks)}") core_parts = [] if shields: - core_parts.append(f"Shields: {summarize_items(shields)}") + core_parts.append(f"{_t('Shields')}: {summarize_items(shields)}") if coolers: - core_parts.append(f"Coolers: {summarize_items(coolers)}") + core_parts.append(f"{_t('Coolers')}: {summarize_items(coolers)}") if powers: - core_parts.append(f"Power: {summarize_items(powers)}") + core_parts.append(f"{_t('Power')}: {summarize_items(powers)}") if qd: - core_parts.append(f"QD: {summarize_items(qd)}") + core_parts.append(f"{_t('QD')}: {summarize_items(qd)}") return " | ".join(weapon_parts), " | ".join(core_parts) @@ -5915,13 +5966,13 @@ def _armor_stats_block(armor_stats: tuple) -> str: lines: list[str] = [] if health is not None: - lines.append(f"Armor HP: {_fmt(health)}") + lines.append(f"{_t('Armor HP')}: {_fmt(health)}") if multipliers is not None: p, e, d, t = multipliers if any(v is not None for v in (p, e, d, t)): lines.append( - f"Dmg Mult: P {_fmt(p, 'x', 2)} | E {_fmt(e, 'x', 2)}" + f"{_t('Dmg Mult')}: P {_fmt(p, 'x', 2)} | E {_fmt(e, 'x', 2)}" f" | D {_fmt(d, 'x', 2)} | T {_fmt(t, 'x', 2)}" ) @@ -5929,7 +5980,7 @@ def _armor_stats_block(armor_stats: tuple) -> str: p, e, d, t = deflection if any(v is not None for v in (p, e, d, t)): lines.append( - f"Deflect: P {_fmt(p)} | E {_fmt(e)} | D {_fmt(d)} | T {_fmt(t)}" + f"{_t('Deflect')}: P {_fmt(p)} | E {_fmt(e)} | D {_fmt(d)} | T {_fmt(t)}" ) return "\\n".join(lines) @@ -6040,19 +6091,19 @@ def enhancements_ship_dataforge( lines = [] if scm is not None or max_spd is not None: - lines.append(f"SCM: {_fmt(scm, ' m/s')} | Max: {_fmt(max_spd, ' m/s')}") + lines.append(f"{_t('SCM')}: {_fmt(scm, ' m/s')} | {_t('Max')}: {_fmt(max_spd, ' m/s')}") if boost_fwd is not None or boost_bwd is not None: - lines.append(f"Boost: +{_fmt(boost_fwd, ' m/s')} / -{_fmt(boost_bwd, ' m/s')}") + lines.append(f"{_t('Boost')}: +{_fmt(boost_fwd, ' m/s')} / -{_fmt(boost_bwd, ' m/s')}") if pitch is not None: lines.append( - f"Pitch: {_fmt(pitch, '°/s')} | Roll: {_fmt(roll, '°/s')} | Yaw: {_fmt(yaw, '°/s')}" + f"{_t('Pitch')}: {_fmt(pitch, '°/s')} | {_t('Roll')}: {_fmt(roll, '°/s')} | {_t('Yaw')}: {_fmt(yaw, '°/s')}" ) basics = [] - if crew_size is not None: basics.append(f"Crew: {_fmt(crew_size)}") - if length is not None: basics.append(f"Length: {_fmt(length, 'm', 1)}") - if career is not None: basics.append(f"Class: {career}") - if role is not None: basics.append(f"Role: {role}") + if crew_size is not None: basics.append(f"{_t('Crew')}: {_fmt(crew_size)}") + if length is not None: basics.append(f"{_t('Length')}: {_fmt(length, 'm', 1)}") + if career is not None: basics.append(f"{_t('Class')}: {career}") + if role is not None: basics.append(f"{_t('Role')}: {role}") if basics: lines.append(" | ".join(basics)) @@ -6065,7 +6116,7 @@ def enhancements_ship_dataforge( if ins_base is not None: lines.append( - f"Insurance: {_fmt(ins_base, ' min', 2)} base | {_fmt(ins_express, ' min', 2)} express" + f"{_t('Insurance')}: {_fmt(ins_base, ' min', 2)} {_t('base')} | {_fmt(ins_express, ' min', 2)} {_t('express')}" ) return "\\n".join(lines) @@ -6770,7 +6821,7 @@ def enhancements_medical_consumables(ctx: dict) -> dict[str, str]: for key, effect in MEDICAL_CONSUMABLE_EFFECTS.items(): if key not in loc: continue - out[key] = append_enhancements(loc[key], effect, separator=EFFECT_SEPARATOR, prepend=prepend) + out[key] = append_enhancements(loc[key], _t(effect), separator=EFFECT_SEPARATOR, prepend=prepend) logger.info(f"Finished medical consumables ({len(out)} entries)") return out @@ -7954,9 +8005,9 @@ def _contractgen_roots(xml_files): details_lines = [] if _show("mission_type"): - details_lines.append(f"Mission Type: {', '.join(all_flags) if all_flags else 'Standard'}") + details_lines.append(f"{_t('Mission Type')}: {', '.join(_t(f) for f in all_flags) if all_flags else _t('Standard')}") if _show("difficulty") and all_difficulties: - details_lines.append(f"Difficulty (1-7): {all_difficulties[0]}") + details_lines.append(f"{_t('Difficulty (1-7)')}: {all_difficulties[0]}") if _show("resource_signatures"): _rs_ores = battaglia_mineable_rs_desc_ores.get(desc_key) if _rs_ores: @@ -7964,7 +8015,7 @@ def _contractgen_roots(xml_files): if _show("spawns"): details_lines.extend(_format_spawn_lines(agg_spawns)) if _show("ace") and bool(agg_spawns.get(SPAWN_HOSTILE, {}).get("Ace Pilots", 0)): - details_lines.append("Ace Pilot: Yes") + details_lines.append(f"{_t('Ace Pilot')}: {_t('Yes')}") nonzero_tiers = [(s, f, rn, rt) for s, f, rn, rt in desc_seen_tiers if s > 0] if _show("reputation"): if len(nonzero_tiers) == 1: @@ -7972,13 +8023,13 @@ def _contractgen_roots(xml_files): details_lines.append(_rep_reward_line(rn, f"{sxp:,}", rep_xp_label, rt)) if fxp < 0: details_lines.append( - _rep_reward_line("Failure Penalty", f"{fxp:,}", rep_xp_label) + _rep_reward_line(_t("Failure Penalty"), f"{fxp:,}", rep_xp_label) ) elif len(nonzero_tiers) > 1: for i, (sxp, fxp, rn, rt) in enumerate(sorted(nonzero_tiers, key=lambda t: t[0]), 1): - line = _rep_reward_line(rn if rn else f"Tier {i}", f"{sxp:,}", rep_xp_label, rt) + line = _rep_reward_line(rn if rn else f"{_t('Tier')} {i}", f"{sxp:,}", rep_xp_label, rt) if fxp < 0: - line += f" (Failure: {fxp:,})" + line += f" ({_t('Failure')}: {fxp:,})" details_lines.append(line) sections: list[str] = [base_desc] @@ -7986,12 +8037,13 @@ def _contractgen_roots(xml_files): chance_pct = int(variant_bp_chance * 100) if all_variants_have_bp: bp_header = ( - f"Blueprint Reward: {chance_pct}% chance" - if chance_pct < 100 else "Blueprint Reward: Guaranteed" + f"{_t('Blueprint Reward')}: " + _t("{pct}% chance", pct=chance_pct) + if chance_pct < 100 else f"{_t('Blueprint Reward')}: {_t('Guaranteed')}" ) else: - variant_note = ", ".join(bp_variant_names) if bp_variant_names else "select variants" - bp_header = f"Blueprint Reward: {chance_pct}% chance ({variant_note} only)" + variant_note = ", ".join(bp_variant_names) if bp_variant_names else _t("select variants") + bp_header = (f"{_t('Blueprint Reward')}: " + + _t("{pct}% chance ({variants} only)", pct=chance_pct, variants=variant_note)) details_lines.append(bp_header) pools_by_system = mission_blueprints.get(title_key, {}) @@ -8296,7 +8348,8 @@ def main(base_ini_path: Path, forge_dir: Path | None = None, standardize_earnable_ship_names: bool = False, rs_ore_name_annotations: bool = True, english_base_ini_path: Path | None = None, - should_cancel: Optional[Callable[[], bool]] = None) -> None: + should_cancel: Optional[Callable[[], bool]] = None, + language: str | None = None) -> None: """Generate the enhancement INIs for *categories* (None means all) beside *base_ini_path*. @@ -8309,6 +8362,12 @@ def main(base_ini_path: Path, forge_dir: Path | None = None, the one the GUI always takes (its worker passes max_workers=1); with a pool (CLI and tests) only the check before the write phase applies. None, the default, never stops. + + *language* is the app folder name of the language the added text is + written in (``languages//enhancements.json``, #579). None, the + default, takes it from a ``cache/lang//base.ini`` path, so a + CLI run over a translated base.ini writes that language too, and English + otherwise. """ import sys as sys_mod # Deferred import — the script is loaded by both the app worker (where @@ -8346,6 +8405,12 @@ def _stop_if_asked(where: str) -> None: raise GenerationStopped(where) logger.info("=== SC Enhancements INI Generator (DataForge edition) ===") + # The generated text's language (#579): None or "english" writes English. + if language is None and Path(base_ini_path).parent.parent.name == "lang": + language = Path(base_ini_path).parent.name + _set_text_language(language) + if _TEXT: + logger.info(f"Generated text: {len(_TEXT):,} translated texts for {language}") if categories is not None: logger.info(f"Selective generation: {', '.join(sorted(categories))}") _flush() diff --git a/src/gui/CLAUDE.md b/src/gui/CLAUDE.md index 61d41019..0230a502 100644 --- a/src/gui/CLAUDE.md +++ b/src/gui/CLAUDE.md @@ -4,7 +4,7 @@ GUI layer (PyQt6). See the root `CLAUDE.md` for project context and cross-cuttin ## Files -- `main_window.py` — main window with table, toolbar, filters, backup/restore, DataForge extraction trigger, worker orchestration. The largest file in the repo; runs the core workflow load→merge→edit→apply. Workers live in `workers.py`; pure-Python helpers (`validate_applied_file`, `filter_entry_indices`, `markdown_to_html`) live in their own modules and are wrapped by thin `MainWindow` methods. Owns `_stamp_frontend_version` and `_add_play_button_reminder` — see *Frontend version stamp on apply* and *Play button reminder on apply* below. Less-frequent toolbar actions (restore backup, clear localization/cache, import/export INI, open loc dir) live under a **More** overflow `QMenu` (2.0). `_on_language_changed(language)` runs the language-switch pipeline (2.0, #30): cancel any in-flight loader, `i18n.set_language()` + `retranslate_ui()`, then `_apply_language_base_source()` repoints the `global` source at that language's base.ini (downloading it via `LanguageBaseDownloadWorker` when a URL is mapped; falling back to a cached copy, then to English), and `_reload_with_language_enhancements()` regenerates that language's enhancements first when the `.dataforge_stamp` is stale (skipped if no DataForge cache: prose loads without stat overlays). `retranslate_ui()` also re-renders the About, FAQ and Legal tabs (#314) and the Help panel (#540) from the new language's docs (`AppSettings.get_localized_doc_path`), which are otherwise rendered only when each is built and on a theme swap. Both go through `_render_document_browsers`, so a theme swap (`refresh_action_buttons`) and a switch cannot render different documents: each used to keep its own list, and the switch's had no Help panel. It also retitles the Help, String Editor and Test Plan panels, whose titles are set only when each is built, and each tab's `retranslate_ui` also sets again the texts its refreshes and loads write, which a switch used to leave in the old language: the Config tab reruns `_populate_channel_combo` (the channel list's not-installed tooltips and hint) and `_refresh_p4k_status`, the Blueprint Tracker renames each filter's first row (`enhancements.blueprints_facet_any`), and the Log tab rewrites its line count (#540). English goes through it too whenever its base.ini exists, because a re-extraction made while another language was selected regenerated only that language. That regeneration is the switch's launch: it clears the Generate button first, as `_run_enhancements_pipeline` does (#292), and leaves the switch's reload to the run. A run that fails still loads the language picked, with the stats it has: `_run_enhancements_generation` keeps its `if_unfinished` in `_after_unfinished_generation`, and the finished slot runs it once the run's error dialog has closed (parked in `_after_error_dialog`, which `_show_error_dialog` runs as it closes). `_run_enhancements_generation` returns whether it started, like `_run_p4k_extraction`, and a start refused because a generation is already running loads the language at once. user.cfg's `g_language` is NOT set here; that happens at window init and apply-to-game time. Its DataForge cache status and freshness checks read the cache folder without creating it, and `_run_dataforge_extraction` reports a cache folder it cannot create in one box before any worker starts (see *Status checks never create the DataForge cache folder* below, #494), as it does a cache folder that is a link (#491). More > Clear Cache (`clear_cache`, #479) deletes the active channel's cached `*.ini` and `*.txt` and, when the user agrees, the DataForge cache in use: the folder `get_dataforge_cache_leaf()` names (the default, the portable build's or a cache folder override), offered only when it holds a cache (its `.p4k_mtime` stamp or its records). It used to look in the data folder's `cache\dataforge`, where the cache lived before 1.x, so the real one was never offered; a leftover there is the queued old-cache cleanup's. A cache folder on a drive or share that is not there is named in the summary and the rest still clears, the file question is skipped when there are no files (a No to the DataForge question then changes nothing, just as a No to the file question), nothing is cleared while an extraction or a generation runs (`clear_cache_busy` in the status bar; the background delete of a finished extraction's working folder, or a sweep of the ones a crash left, does not count, #522, since neither touches the other's folder), the Enhancements tab is refreshed afterwards, a failure is listed in the summary and logged once at WARNING (an ERROR record opened a second box), and every text goes through `tr()`. A channel switch and a data-folder change (`_sync_canonical_source_paths`, through `AppSettings.sync_global_source_path`) and a successful global.ini extraction (`_on_p4k_extract_finished`) keep the `global` source on the selected language's base.ini (`AppSettings.get_global_source_base_ini()`, English when this channel has none yet); they used to point every language at the English one (#502). +- `main_window.py` — main window with table, toolbar, filters, backup/restore, DataForge extraction trigger, worker orchestration. The largest file in the repo; runs the core workflow load→merge→edit→apply. Workers live in `workers.py`; pure-Python helpers (`validate_applied_file`, `filter_entry_indices`, `markdown_to_html`) live in their own modules and are wrapped by thin `MainWindow` methods. Owns `_stamp_frontend_version` and `_add_play_button_reminder` — see *Frontend version stamp on apply* and *Play button reminder on apply* below. Less-frequent toolbar actions (restore backup, clear localization/cache, import/export INI, open loc dir) live under a **More** overflow `QMenu` (2.0). `_on_language_changed(language)` runs the language-switch pipeline (2.0, #30): cancel any in-flight loader, `i18n.set_language()` + `retranslate_ui()`, then `_apply_language_base_source()` repoints the `global` source at that language's base.ini (downloading it via `LanguageBaseDownloadWorker` when a URL is mapped; falling back to a cached copy, then to English), and `_reload_with_language_enhancements()` regenerates that language's enhancements first when the `.dataforge_stamp` is stale (skipped if no DataForge cache: prose loads without stat overlays). `retranslate_ui()` also re-renders the About, FAQ and Legal tabs (#314) and the Help panel (#540) from the new language's docs (`AppSettings.get_localized_doc_path`), which are otherwise rendered only when each is built and on a theme swap. Both go through `_render_document_browsers`, so a theme swap (`refresh_action_buttons`) and a switch cannot render different documents: each used to keep its own list, and the switch's had no Help panel. It also retitles the Help, String Editor and Test Plan panels, whose titles are set only when each is built, and each tab's `retranslate_ui` also sets again the texts its refreshes and loads write, which a switch used to leave in the old language: the Config tab reruns `_populate_channel_combo` (the channel list's not-installed tooltips and hint) and `_refresh_p4k_status`, the Blueprint Tracker renames each filter's first row (`enhancements.blueprints_facet_any`), and the Log tab rewrites its line count (#540). English goes through it too whenever its base.ini exists, because a re-extraction made while another language was selected regenerated only that language. That regeneration is the switch's launch: it clears the Generate button first, as `_run_enhancements_pipeline` does (#292), and leaves the switch's reload to the run. A run that fails still loads the language picked, with the stats it has: `_run_enhancements_generation` keeps its `if_unfinished` in `_after_unfinished_generation`, and the finished slot runs it once the run's error dialog has closed (parked in `_after_error_dialog`, which `_show_error_dialog` runs as it closes). `_run_enhancements_generation` returns whether it started, like `_run_p4k_extraction`, and a start refused because a generation is already running loads the language at once. Each start also fetches the selected language's community global.ini again when its source is a URL (`_check_language_translation_at_startup`, run last in `_continue_startup_after_update_gate`, its own `_lang_check_worker` with no dialog, a conditional request): before #579 only a switch fetched it, so a translation fixed after a game patch waited for a switch. When a new file came down (`LanguageBaseDownloadWorker.changed`), `_on_language_translation_checked` empties that language's `.dataforge_stamp` (its enhancements hold the old text) and reloads through `_reload_with_language_enhancements`, put off with `_ask_after_the_job` while a load, a job, a Simple run or a modal box is going, and dropped when the language changed or the window is closing. Closing waits for the check within its shared deadline. user.cfg's `g_language` is NOT set here; that happens at window init and apply-to-game time. Its DataForge cache status and freshness checks read the cache folder without creating it, and `_run_dataforge_extraction` reports a cache folder it cannot create in one box before any worker starts (see *Status checks never create the DataForge cache folder* below, #494), as it does a cache folder that is a link (#491). More > Clear Cache (`clear_cache`, #479) deletes the active channel's cached `*.ini` and `*.txt` and, when the user agrees, the DataForge cache in use: the folder `get_dataforge_cache_leaf()` names (the default, the portable build's or a cache folder override), offered only when it holds a cache (its `.p4k_mtime` stamp or its records). It used to look in the data folder's `cache\dataforge`, where the cache lived before 1.x, so the real one was never offered; a leftover there is the queued old-cache cleanup's. A cache folder on a drive or share that is not there is named in the summary and the rest still clears, the file question is skipped when there are no files (a No to the DataForge question then changes nothing, just as a No to the file question), nothing is cleared while an extraction or a generation runs (`clear_cache_busy` in the status bar; the background delete of a finished extraction's working folder, or a sweep of the ones a crash left, does not count, #522, since neither touches the other's folder), the Enhancements tab is refreshed afterwards, a failure is listed in the summary and logged once at WARNING (an ERROR record opened a second box), and every text goes through `tr()`. A channel switch and a data-folder change (`_sync_canonical_source_paths`, through `AppSettings.sync_global_source_path`) and a successful global.ini extraction (`_on_p4k_extract_finished`) keep the `global` source on the selected language's base.ini (`AppSettings.get_global_source_base_ini()`, English when this channel has none yet); they used to point every language at the English one (#502). - `workers.py` — every `QThread` background worker plus the shared `AnimatedProgressDialog` (its `set_close_guard(guard)` asks before Esc or the title-bar X dismisses it, never on a programmatic `close()`, and only for a dialog without a cancel button, #471; its `set_progress` shows the moving busy bar for a total of 0 and for nothing counted yet, 0 of N, until the first count, #507: a bar standing at 0% looked hung, as the generator's first lookups did for seconds, and the string loader and the update download start at 0 too) and `SelectAllDelegate`. Workers: `FileLoaderWorker` (sources → `StringEntry` list + sort keys), `AppliedStateWorker` (#398 review: runs the already-applied comparison off the GUI thread; takes an injected `compute(snapshot, should_stop)` instead of importing it, because the merge it shares with Apply to Game lives in `main_window.py` and importing that here would be a gui-to-gui cycle; always emits `finished(bool)` once, False being the safe "not applied" answer), `StartupSyncWorker` (refresh URL-backed sources at startup), `EnhancementsGeneratorWorker` (run `scripts/generate_enhancements_ini.py` in-process via `importlib.util`; takes a `language` param so output lands in that language's enhancements dir while annotation paths still parse the English base.ini; captures that folder, the DataForge build key and the tag fingerprint when its run starts, empties `.dataforge_stamp` just before the generator's `main()` and writes the tag stamp and then the DataForge stamp after it returns, see *A cut-off generation is offered again at the next start* below; `requestInterruption()`, which only closing the window sends, stops it before its patches, its module load or `main()`, and inside `main()` at the next job boundary, never during the writes, records it in `stopped` and ends with `finished(False)`, no `error` and nothing at ERROR), `P4kExtractWorker` (unp4k extract of `global.ini`, working beside the DataForge cache it is handed as `scratch_near`), `DataForgeExtractWorker` (unp4k + unforge + post-extract patches; both stop on `requestInterruption()`, record it in `stopped` and then end with `finished(False)`, no `error` and nothing at ERROR, #471; a successful DataForge run keeps its working folder for `take_working_folder()`, any other outcome deletes it before `finished`, and a DataForge run first waits for the background deletes it is handed as `wait_for`, #522), `WorkingFolderDeleteWorker` (deletes that folder in the background, #522, see *Closing stops a running extraction*), `StaleWorkingFolderSweepWorker` (sweeps the working folders a crash or a kill left, #522, same section), `LanguageBaseDownloadWorker` (2.0: fetch a non-English language's global.ini from its mapped URL into `cache\lang\{language}\base.ini`), `UexShopDataWorker` (3.1.0, #606: `uex_shops.load_shop_data` for the SCO Item Finder, always emits `finished(ShopData or None, error)` once; `closeEvent` waits for it, its requests time out after `REQUEST_TIMEOUT_S`), `LiveBlueprintLogWorker` (SCO, 3.0.0: polls `blueprint_log_scanner.GameLogTail` on the active channel's `Game.log` every `POLL_MS` while the overlay runs, LIVE and HOTFIX only, and emits `blueprints_found(raw names, newest)`; read-only like the Scan, the main thread updates the owned set; stopped with `requestInterruption()` + `_reap_worker`; a lasting poll fault logs one traceback, then debug; takes `(log_path, since, loc_files)` and reads the notification's texts from the loc files once, when it starts, #564; a failure there is guarded as a poll is, logged once at WARNING with its traceback, since an ERROR would open the error box over the game, while the watch goes on with English alone), `BlueprintLogScanWorker` (#222: scan a channel dir for "Received Blueprint" notifications via `blueprint_log_scanner.scan_channel`, watermark-aware — takes `(channel_dir, since, loc_files)`, emits a `ScanResult`; stays read-only, all owned-set/watermark mutation happens on the main thread in `MainWindow._on_blueprint_log_scan_finished`). Both read the notification's text in the language the game shows from the loc files they are handed (#564, `blueprint_log_scanner.notification_templates`, English always) on their own thread, because each can be about 11 MB, and log the texts at INFO. Each emits `progress` (str) and `progress_pct` (completed, total, message); `AnimatedProgressDialog.set_progress` consumes the latter. Exception: `AppUpdateCheckWorker` and `AppUpdateDownloadWorker` live in `src/utils/app_updater.py` because the workers, version comparison, and installer-asset picking belong together (#211). - `markdown_renderer.py` — `markdown_to_html(text, text_color, base_color, link_color)` for About/Help. Pure-Python; the Qt caller passes palette colours so the converter has no Qt dep. Stash-and-restore code-span handling keeps `**` and `_` inside backticks literal (loc keys like `vehicle_Name*` shouldn't sprout `` tags). - `config_tab.py` — **Config Tab**: source management, drag-drop merge hierarchy, SC install path, DataForge extraction trigger. Also the language selector (2.0): emits `language_changed(str)` for `MainWindow._on_language_changed`, and hosts `LanguageSourceDialog` (the *Map Language File* button) for per-language base.ini URL overrides. Changing the data folder migrates existing data via `migrate_user_data_dir(move=True)`. A DataForge cache folder change whose cache folder cannot be made (Windows refuses it, cannot reach it or rejects it) is undone as Cancel undoes it, with one box (`_report_cache_folder_error`, #494, see below). The cache folder field saves only a folder the user typed (`_cache_dir_edited`), so a click into it and out again, or Enter with nothing typed, tries nothing. While an extraction or a generation runs, `set_data_locations_locked` locks the folders, the channel, the language, Extract, Import Settings and Check for Updates, with the reason shown (#483, see *Run in Background and the job lock* below). Its Appearance group's **Minimize to Tray** saves `AppSettings.set_minimize_to_tray` and emits `minimize_to_tray_changed(bool)`, and is greyed out where there is no system tray (see `tray.py`). diff --git a/src/gui/main_window.py b/src/gui/main_window.py index 202f0933..08b46b94 100644 --- a/src/gui/main_window.py +++ b/src/gui/main_window.py @@ -950,6 +950,8 @@ def __init__(self, installer_data_move=None): # Per-language base.ini download worker (#30) self._lang_dl_worker: Optional[LanguageBaseDownloadWorker] = None + # The startup check for a newer community translation (#579) + self._lang_check_worker: Optional[LanguageBaseDownloadWorker] = None # P4K extraction worker and progress dialog self._p4k_worker: Optional[P4kExtractWorker] = None @@ -5035,6 +5037,7 @@ def _continue_startup_after_update_gate(self) -> None: self._maybe_warn_onedrive_data_dir() self._maybe_prompt_post_import_apply() self._maybe_auto_scan_blueprints() + self._check_language_translation_at_startup() def _maybe_auto_scan_blueprints(self) -> None: """Run "Scan Logs for Owned Blueprints" on startup if opted in (#386). @@ -5736,6 +5739,70 @@ def _apply_language_base_source(self, language: str) -> None: ) self._lang_dl_worker.start() + def _check_language_translation_at_startup(self) -> None: + """Fetch the selected language's community translation again, once a + start, in the background (#579). + + A language switch downloads it, but nothing else did, so after a game + patch the table kept the old translation until the user switched + language and back. Only a URL source is checked: the request is + conditional, so an unchanged file costs one round trip and changes + nothing. A file the user mapped by hand (Map Language File) is left + alone, as it only changes when they change it. A new file is acted + on in _on_language_translation_checked.""" + language = AppSettings.get_selected_language() + if language == AppSettings.DEFAULT_LANGUAGE or self._close_committed: + return + if self._lang_check_worker is not None or self._lang_dl_worker is not None: + return + source = AppSettings.get_language_base_url(language) + if not source.startswith(("http://", "https://")): + return + dest = AppSettings.get_base_ini_path(language) + worker = LanguageBaseDownloadWorker(source, dest) + worker.finished.connect( + lambda ok, w=worker, lang=language, d=dest: + self._on_language_translation_checked(w, lang, d, ok) + ) + self._lang_check_worker = worker + logger.info(f"Checking for a newer {language!r} translation") + worker.start() + + def _on_language_translation_checked(self, worker, language: str, dest, ok: bool) -> None: + """A new translation makes the language's enhancements out of date + (their descriptions are its text), so its stamp is emptied and the + reload goes through _reload_with_language_enhancements, as a language + switch does: it generates them again first when there is a DataForge + cache. Put off while a load, a job, a Simple run or a modal box is + going (_ask_after_the_job), and dropped when the language changed + meanwhile, since that switch fetched its own.""" + if worker is not self._lang_check_worker: + return + worker.quit() + worker.wait() + self._lang_check_worker = None + if not ok or not worker.changed or self._close_committed: + return + if not Path(dest).exists() or AppSettings.get_selected_language() != language: + return + logger.info(f"A newer {language!r} translation was downloaded; reloading with it") + AppSettings.invalidate_enhancements_stamp(AppSettings.get_enhancements_dir(language)) + if hasattr(self, "enhancements_tab"): + self.enhancements_tab.refresh_enhancements_dirty_state() + + def reload_with_it(): + if self._close_committed or AppSettings.get_selected_language() != language: + return + if self._loader_worker is not None or self._job_running() or self._simple_run_active: + self._ask_after_the_job(reload_with_it) + return + AppSettings.set_source_path(AppSettings.SOURCE_GLOBAL, str(dest)) + self.statusBar().showMessage(tr("dialogs.language_updated_status", language=language)) + self._reload_with_language_enhancements(language) + + self._ask_after_the_job(reload_with_it) + QTimer.singleShot(0, self._flush_asks_after_the_job) + def _on_language_base_ready(self, language: str, dest, dialog, ok: bool) -> None: """Finish a language switch once its base.ini fetch (download or local copy) settled.""" @@ -7646,6 +7713,16 @@ def _stop_workers_for_close(self, timeout_ms: int = 180_000) -> None: continue # keep the reference so Qt doesn't destroy a live thread self._working_folder_deleters.remove(deleter) + # The startup translation check (#579): a conditional download with + # a 60 s timeout, so it ends on its own; Qt must not destroy it live. + checker = self._lang_check_worker + if checker is not None and checker.isRunning(): + remaining_ms = max(0, int((deadline - time.monotonic()) * 1000)) + if not checker.wait(remaining_ms): + logger.warning("The translation check was still running when Smart Citizen closed") + return + self._lang_check_worker = None + def closeEvent(self, event): """Save state and overrides, and stop a running extraction (#471) or enhancement generation, before closing.""" diff --git a/src/gui/workers.py b/src/gui/workers.py index cc6b07dc..ac5d620d 100644 --- a/src/gui/workers.py +++ b/src/gui/workers.py @@ -428,12 +428,17 @@ def __init__(self, source: str, dest_path): super().__init__() self._source = source self._dest = dest_path + # True once a fetch wrote a new base.ini (a URL that changed, or a + # local copy), False for an unchanged URL or a failure (#579: the + # startup check reloads only after a change). + self.changed = False def run(self): from src.utils.updater import fetch_language_base is_url = self._source.startswith(("http://", "https://")) try: changed = fetch_language_base(self._source, self._dest) + self.changed = bool(changed) if is_url: logger.info( f"Language base.ini ready: {self._dest} " @@ -818,7 +823,11 @@ def run(self): # lookup pickles). forge_dir = AppSettings.get_dataforge_cache_leaf() english_base = AppSettings.get_base_ini_path(AppSettings.DEFAULT_LANGUAGE) - build_key = AppSettings.get_dataforge_build_key(forge_dir) + # With the language's generated-text table in it (#579), so a + # table an update changes makes the set read as out of date. + text_language = self.language or AppSettings.get_selected_language() + build_key = AppSettings.enhancements_stamp_value( + AppSettings.get_dataforge_build_key(forge_dir), text_language) tag_stamp = tag_config_fingerprint(self.tag_configs, self.annotate_mission_descs) # Temp files a hard kill left between a write and its swap # (atomic_io): the INI folder and the generator's lookup pickle @@ -902,7 +911,8 @@ def _on_progress(completed: int, total: int, message: str) -> None: standardize_earnable_ship_names=self.standardize_earnable_ship_names, rs_ore_name_annotations=self.rs_ore_name_annotations, english_base_ini_path=english_base, - should_cancel=self.isInterruptionRequested) + should_cancel=self.isInterruptionRequested, + language=text_language) logger.info("Enhancements generation worker: mod.main() completed successfully") # Record which Tag Builder config these INIs were generated diff --git a/src/utils/CLAUDE.md b/src/utils/CLAUDE.md index e83314c4..153ed69f 100644 --- a/src/utils/CLAUDE.md +++ b/src/utils/CLAUDE.md @@ -18,6 +18,7 @@ Utility layer: settings, build-mode flag, P4K extraction, enhancement support mo Also owns the **settings backup** filter (Config tab's Export / Import Settings; the zip I/O lives in `settings_profile.py`). `export_all_values()` lays down `profile_default_values()` first and writes stored values over the top, so a backup describes the user's whole configuration rather than only what differs from stock. That matters because a setting is not written to the backend until the user changes it: before #383 anything still at its default had no key to enumerate, so it never reached the backup and an import could not put a preference *back* to its default (rename a Mission Label, import an older backup, and the rename survived — same for theme, UI mode, the favourites prefix, and every checkbox). `profile_default_values()` is a function, not a constant, because `merge_hierarchy` is declared further down the class body and the theme default needs a deferred `src.gui.theme` import; it composes from the same maps the getters read (`_MISSION_HEADER_SETTING`, `_MISSION_FIELD_SETTING`, `_MISSION_TITLE_TAG_SETTING` / `_MISSION_TITLE_TAG_DEFAULTS`, `ENHANCEMENT_LABELS`, `DEFAULT_TAG_CONFIGS`) so those can't drift. `PROFILE_DEFAULT_EXCLUDE_KEYS` / `_PREFIXES` hold the deliberate carve-outs — per-machine state and user *data* whose "unset" default would make an import destructive rather than restorative (the install paths, since clearing one forces re-detection that can land on the wrong install per #370; `owned_items`; the starter-blueprint seed marker, which describes the owned set, so `import_values` applies it only from a backup that carries `owned_items` and resets it when that backup predates it (#416); the blueprint log watermark; the test-plan keys). `PROFILE_EXCLUDE_KEYS` still filters machine-local keys ahead of all this. `tests/test_settings_profile_defaults.py::TestNoDrift` replays every no-arg getter against a recording backend and fails if a defaulted key is neither materialised nor excluded, so a new setting can't silently reintroduce the bug. Also owns the language layer (2.0, #30): `get_selected_language()` / `set_selected_language()` (registry key `SELECTED_LANGUAGE`), `get_available_languages()` (hides languages whose `ui.json` is a stub), `SC_LANGUAGE_IDS` + `get_sc_language_id()` (app folder name `portuguese_br` → game id `portuguese_(brazil)`, used in both the Localization path and `g_language`), `get_base_ini_path(language)` (English: `{channel}\cache\base.ini`; others: `{channel}\cache\lang\{language}\base.ini`), `get_base_ini_leaf(language, channel)` (the same file for any channel, named without making the channel, cache or language folder, as `get_dataforge_cache_leaf` is: a blueprint scan reads LIVE's and HOTFIX's files whichever channel is active, #564; `tests/test_language_paths.py` pins it to `get_base_ini_path` for the active channel), `get_applied_global_ini(channel_dir, language)` (the applied `global.ini` in any channel's install folder, the one place its `data\Localization\{sc_id}\global.ini` layout is written; `get_global_ini_path()` gives it for the active channel), `get_global_source_base_ini(language)` (the base.ini the `global` merge source reads: the language's own when the active channel's cache has it, otherwise the English one, #502) and `sync_global_source_path(context)` (points a file-backed `global` source there and leaves a URL source alone; `main()` runs it at every start and `MainWindow._sync_canonical_source_paths` after a channel switch or a data-folder change, and a successful global.ini extraction points the source at the same file: all three but startup used to point every language at the English base.ini, and the bundled `languages//global.ini` overlays are empty, so the table, and the next Apply, turned English), `get_enhancements_dir(language)` (always `get_base_ini_path(language).parent`, so enhancements sit next to the base.ini they were generated from), `get_/set_enhancements_stamp()` (`.dataforge_stamp` marker recording the DataForge build a language's enhancements came from; missing/stale forces regen on switch; it and `.tag_config_stamp` are written in one step and read with a short retry through `atomic_io.py`; both setters take `folder=`, the folder a generation captured when its run started, as `get_dataforge_build_key(forge_dir)` takes its cache folder), `invalidate_enhancements_stamp(folder)` (empties `.dataforge_stamp` just before the generator's `main()`, so a run cut off or failed from there reads as out of date), `enhancements_built_from_current_dataforge(language)` (the stamp is set and matches the current build key: the one definition of "current" for the startup check, the Generate button and the language switch), and `get_language_base_url()` + `get_/set_language_source_override()` (download URL from a per-user override, falling back to the bundled `languages/sources.json`). +- `enhancement_text.py` (#579): the translations of the text the enhancement generator adds (stat labels, mission details, journal lines). `languages//enhancements.json` maps each English text to the language's own, in `ui.json`'s `{"ht", "at"}` leaf shape (`ht` wins, then `at`; an empty or unchanged leaf stays English). `load_table(language)` gives `{}` for English, a missing file or one that cannot be read (WARNING), so a run then writes English as before. `table_fingerprint(language)` (12 hex characters, `""` with no table) is part of the enhancements stamp through `AppSettings.enhancements_stamp_value(build_key, language)`: `build_key|text=` for a translated language, the plain build key for English, so English stamps are unchanged and an update that changes a language's table makes its set out of date. `languages/english/enhancements.json` is the list of every English text, generated by `tests/test_enhancement_text.py --write`, and never loaded. A leaf module (no Qt, no AppSettings) so the generator can import it through its `src` shim. - `json_settings.py` — `JsonSettings`: file-backed key-value store mirroring the four `QSettings` methods `AppSettings` uses (`value` / `setValue` / `remove` / `sync`). Writes on every set, thread-safe via `RLock`. Used when `build_mode.IS_PORTABLE` is true. We do **not** use `QSettings(IniFormat)` — it mangles slash-prefixed keys (e.g. `enhancements/categories/foo/enabled`) into nested groups and can't round-trip them; `tests/test_json_settings.py` locks this. - `build_mode.py` — single `IS_PORTABLE` flag. Default `False`; `scripts/build/build_exe.py --portable` writes a generated `src/utils/_build_info.py` (git-ignored) with `IS_PORTABLE = True` that `build_mode.py` picks up via `try: from src.utils._build_info import IS_PORTABLE`. The build script deletes the generated file post-build so the source tree is never committed in portable state. Tests flip the flag via `monkeypatch.setattr`; production code only reads it. - `locpack_exporter.py` — pure-Python writer for the **Export Loc-Pack** toolbar action. Zips the applied `global.ini` from the game's localization directory into `SmartCitizen-LocPack-{channel}-{YYYYMMDD}.zip` (compression 9; bare `global.ini` at the zip root so recipients drop it straight into `StarCitizen\\data\Localization\english\`). The Qt button lives on `MainWindow.export_locpack`; this module owns the I/O so the logic is testable without Qt. diff --git a/src/utils/enhancement_text.py b/src/utils/enhancement_text.py new file mode 100644 index 00000000..4a0e45ed --- /dev/null +++ b/src/utils/enhancement_text.py @@ -0,0 +1,97 @@ +"""Translations of the text the enhancement generator adds (#579). + +The generator writes its stat labels, mission details and journal lines in +English. ``languages//enhancements.json`` maps each English text to +the language's own, and the generator looks each one up while it writes +(``scripts/generate_enhancements_ini.py``'s ``_t``). The English text is the +key, so a text with no translation stays English and English output never +changes. + +File shape, like ``ui.json`` (#182):: + + { + "_comment": "...", + "strings": { + "Max HP": {"ht": "", "at": "Max. TP"}, + "{count} items": {"ht": "", "at": "{count} Gegenstände"} + } + } + +``ht`` is a human translation and ``at`` an AI draft; ``ht`` wins, then +``at``, and a text with both empty stays English. ``{name}`` placeholders are +filled in by the generator and must be kept as they are. + +``languages/english/enhancements.json`` lists every English text, each +mapped to itself, as the list translators work from. It is never loaded. + +A leaf module: no Qt, no AppSettings, so the generator can import it. +""" +import hashlib +import json +import logging +from pathlib import Path + +logger = logging.getLogger(__name__) + +# Must agree with AppSettings.DEFAULT_LANGUAGE (i18n carries its own copy +# for the same reason). +_DEFAULT_LANG = "english" + +TEXT_FILE_NAME = "enhancements.json" + + +def text_file_path(language: str) -> Path: + """Where *language*'s table lives, in the source tree or the bundle.""" + from src.utils.resource_path import get_resource_path + return Path(get_resource_path(f"languages/{language}/{TEXT_FILE_NAME}")) + + +def parse_table(data: dict) -> dict[str, str]: + """English text -> translation, from a parsed enhancements.json. + + Leaves with no translation are left out, so they stay English.""" + out: dict[str, str] = {} + strings = data.get("strings") if isinstance(data, dict) else None + if not isinstance(strings, dict): + return out + for english, leaf in strings.items(): + if isinstance(leaf, dict): + text = leaf.get("ht") or leaf.get("at") or "" + elif isinstance(leaf, str): + text = leaf + else: + text = "" + if text and text != english: + out[english] = text + return out + + +def load_table(language: "str | None") -> dict[str, str]: + """*language*'s translations, or {} for English, a missing file or a + file that cannot be read (the run then writes English, as before).""" + if not language or language == _DEFAULT_LANG: + return {} + path = text_file_path(language) + try: + if not path.exists(): + return {} + with path.open(encoding="utf-8") as fh: + return parse_table(json.load(fh)) + except (OSError, ValueError) as exc: + logger.warning(f"Could not read {TEXT_FILE_NAME} for {language!r}: {exc}") + return {} + + +def table_fingerprint(language: "str | None") -> str: + """12 hex characters naming *language*'s translations, or "" when it has + none (English, or no file). + + Part of the enhancements stamp (``AppSettings.enhancements_stamp_value``), + so an update that changes a language's table makes that language's + generated set read as out of date and the app offers to generate it + again. English has no table, so its stamp stays the plain build key.""" + table = load_table(language) + if not table: + return "" + payload = json.dumps(table, sort_keys=True, ensure_ascii=True) + return hashlib.sha256(payload.encode("ascii")).hexdigest()[:12] diff --git a/src/utils/settings.py b/src/utils/settings.py index 0fde1e2c..1f2ee220 100644 --- a/src/utils/settings.py +++ b/src/utils/settings.py @@ -3417,7 +3417,25 @@ def enhancements_built_from_current_dataforge(language: "str | None" = None) -> :meth:`invalidate_enhancements_stamp`), or nothing was ever generated. """ stamp = AppSettings.get_enhancements_stamp(language) - return bool(stamp) and stamp == AppSettings.get_dataforge_build_key() + return bool(stamp) and stamp == AppSettings.enhancements_stamp_value( + AppSettings.get_dataforge_build_key(), language) + + @staticmethod + def enhancements_stamp_value(build_key: str, language: "str | None" = None) -> str: + """The ``.dataforge_stamp`` text for a set generated from *build_key* + in *language*. + + A language with a table of translated generated text (#579, + ``languages//enhancements.json``) adds ``|text=`` and the + table's fingerprint, so an update that changes the table makes that + language's set read as out of date and the app offers to generate it + again. English has no table, so its stamp is the plain build key, as + before.""" + from src.utils.enhancement_text import table_fingerprint + if language is None: + language = AppSettings.get_selected_language() + text = table_fingerprint(language) + return f"{build_key}|text={text}" if text else build_key @staticmethod def invalidate_enhancements_stamp(folder: Path) -> None: diff --git a/tests/CLAUDE.md b/tests/CLAUDE.md index 19b2b4cc..f76944ba 100644 --- a/tests/CLAUDE.md +++ b/tests/CLAUDE.md @@ -92,6 +92,8 @@ Split by domain: - `test_i18n.py`: 2.0 UI translation contract. `tr()` dot-path resolution, English fallback for untranslated keys, bare-key fallback when missing everywhere, kwargs interpolation degradation, `_deep_merge` scalar-over-dict tolerance, lazy English load when `set_language` was never called (workers' progress strings). - `test_language_paths.py`: 2.0 per-language cache layout. English base.ini at the cache root vs `cache/lang/{language}/` for others, enhancements dir = base.ini parent, per-language `.dataforge_stamp` isolation, both stamps written in one step and read with a short retry (a failed write keeps the old stamp, and a stamp held with no sharing for a moment is not read as missing, Windows only), the stamp setters' `folder=` and `get_dataforge_build_key(forge_dir)` (what a generation passes so its stamps go where its run started), `invalidate_enhancements_stamp` (empties the DataForge stamp only and writes nothing else, a failure only logged), base.ini URL resolution (override > bundled sources.json > ''), `SC_LANGUAGE_IDS` mapping fallback, and `get_localized_doc_path` (translated HELP/ABOUT/LEGAL win for non-English, bundled `docs/` is the fallback). #564, `TestAnotherChannelsFiles` on real paths (`tmp_profile`): `get_base_ini_leaf` is `get_base_ini_path` for the active channel (English and Spanish, the selected language by default) and names another channel's base.ini without making a folder, and `get_applied_global_ini` gives the applied file in any channel's install folder, the same as `get_global_ini_path` for the active one, for English, Spanish and Brazilian Portuguese and by default the selected language. - `test_language_switch_text.py`: #540, a language switch shows what a restart in that language shows, on a real `MainWindow` (`tests/gui_window.py`) switched as the Config tab does (the language saved, then `_on_language_changed`, with `_apply_language_base_source` recorded instead of run). `test_a_switch_shows_what_a_restart_shows` builds a window in English, in each view (Advanced and Simple), with the String Editor and Test Plan panels opened (they are built on first use), switches it to German, then builds a second window in the same folder with German saved, as a restart finds it, and reads every text both show in Qt's child order: label and button text, placeholders, group box, menu and dock titles, tab texts, combo box items and their tooltips, spin box affixes, view headers and their tooltips, tree and list rows, every tooltip and every action's text. Any field that differs fails the test, naming the widget, the field and both values. A control pins that the switch itself changed over 200 of those texts, the Help panel's title among them. Before #540 it named the Blueprint Tracker filters' five "Any" rows, the Config tab's channel hint, the channel list's not-installed tooltips and the Data.p4k status, and the Log tab's line count, each written by a refresh or a load that a switch did not run again. The Help panel's title was a fixed "Help" in both windows, so the control and the German start below catch that one. The Help panel's HELP.md: English, German, then English again, the panel shows each language's HELP.md (told apart by its title) and title (`toolbar.help_btn`, "Hilfe" in German) straight after the switch, with the About tab (#314) as a control, told apart by its first section heading because ABOUT.md's title is "Smart Citizen" in both. A check pins that none of those headings is empty or found inside the other language's. A theme swap (`refresh_action_buttons`) and `retranslate_ui` each render all four documents (About, FAQ, Legal and Help, the renderers recorded), which both get from `_render_document_browsers`, so one cannot leave out a document the other renders. A window built with German saved (`build_main_window`'s `language=`) titles the panel "Hilfe" too, where it was a fixed "Help". +- `test_enhancement_text.py`: #579, the generator's added text in the selected language. The English list (`languages/english/enhancements.json`) is exactly the texts the generator can write: every literal `_t()` call (read by AST) plus the texts it passes from its tables and classifiers, so a new one fails until `python tests/test_enhancement_text.py --write` is run. Every language with a `ui.json` has an `enhancements.json` holding exactly those keys, each leaf `{ht, at}`, every `{placeholder}` and `` kept, no newline or `=`. `parse_table` (human wins, then the draft, an empty or unchanged leaf left out), no table for English, `None` or an unknown language. A run with English writes English, a run with a table writes its words (`_t`, the section labels in `write_ini`, `enhancements_mission`), and a CLI run over `cache/lang//base.ini` loads that language. The stamp: English is the plain build key, a translated language's carries `table_fingerprint`, and a changed table makes the set stale. +- `test_language_translation_check.py`: #579, the start-time re-download of the selected language's community global.ini, on the real `MainWindow` methods with a `MagicMock` self and a fake worker. Only a URL source is fetched (not English, no source, a local file, a switch downloading, or closing), and the startup gate runs it. An unchanged file or a failed fetch changes nothing; a new file empties the language's stamp, refreshes the Generate button and reloads through `_reload_with_language_enhancements` with the `global` source on the new file, after a load or a job (`_ask_after_the_job`), and a language switch, a close or a released worker drops it. - `test_language_overlay.py`: 2.0 merge overlay. `load_sources_from_settings()` inserts the bundled `languages//global.ini` as a `language` source just before `user` (appended without user); missing or empty overlay degrades to English-only without touching the hierarchy. - `test_language_global_source.py`: #502. The `global` source stays on the selected language's base.ini. Real settings (a `JsonSettings` file in `tmp_path`), the real path helpers and the real loader (`load_sources_from_settings`), German selected and each base.ini holding one `ui_Greeting`, so the loaded value says which file the table shows. `AppSettings.get_global_source_base_ini` gives English for English, the language's own base.ini when there is one, and English for a language not fetched yet. `sync_global_source_path` (what `main()` runs) puts a source left on English back on the language with one INFO line, leaves a URL source alone and logs nothing when the source is already right, and an AST check shows `main()` calls it and sets the `global` source nowhere else. The real `_on_p4k_extract_finished` success keeps German (it used to turn the table English), still gives English to English and to a language not fetched yet, and still replaces a URL source with a local file with auto-update off. The real `_on_channel_changed` and `_on_data_dir_changed` on stub windows keep German in the new channel or data folder, give the new channel's English base.ini when it has no German one, still point `user.ini` at the new channel, and leave URL sources alone. - `test_enhancements_source_injection.py`: `load_sources_from_settings()` loads each enabled enhancement category's generated INI as the synthetic `AppSettings.SOURCE_ENHANCEMENTS` source, inserts it just before `user` (or appends it when there is none), and maps every key to its category label for the table's category column. An enabled category whose INI has not been generated adds no source and raises nothing. Also drives `load_source_files` over that result: a key the enhancement file overrides is attributed to the enhancements source, labelled `Enhanced`, and categorised from the map. It also drives `ConfigTab.preview_merge` with a fake `QMessageBox` to pin that the Config tab's Apply Preview buckets enhancement keys by that same map as the Apply dialog (it used to read medical consumables as Gear). Same hermetic `AppSettings` approach as `test_language_overlay.py`. diff --git a/tests/test_enhancement_text.py b/tests/test_enhancement_text.py new file mode 100644 index 00000000..618dd0d4 --- /dev/null +++ b/tests/test_enhancement_text.py @@ -0,0 +1,281 @@ +"""Translated generated text (#579). + +The generator's added text goes through ``_t()``, keyed by its English text, +and ``languages//enhancements.json`` holds each language's words. +These tests lock: + +* the English list (``languages/english/enhancements.json``) names exactly + the texts the generator can write, so translators never miss one and no + table carries a dead key; +* every language's table keeps each ``{placeholder}`` of its English text; +* an English run writes the same bytes as before, and a translated run + writes the table's words; +* the enhancements stamp carries a translated language's table, so a table + change makes its set read as out of date. + +After adding or changing a ``_t()`` text, rewrite the English list with +``python tests/test_enhancement_text.py --write`` and add the text to the +other languages' tables. +""" +from __future__ import annotations + +import ast +import importlib.util +import json +import re +import string +import sys +from pathlib import Path + +import pytest + +pytestmark = pytest.mark.unit + +REPO = Path(__file__).resolve().parent.parent +SCRIPT = REPO / "scripts" / "generate_enhancements_ini.py" +LANGUAGES = REPO / "languages" +ENGLISH_LIST = LANGUAGES / "english" / "enhancements.json" + +if str(REPO) not in sys.path: + sys.path.insert(0, str(REPO)) + + +def _load_generator(name: str = "generate_enhancements_ini_text_test"): + spec = importlib.util.spec_from_file_location(name, SCRIPT) + mod = importlib.util.module_from_spec(spec) + sys.modules[spec.name] = mod + spec.loader.exec_module(mod) + return mod + + +def _literal_texts() -> set[str]: + """Every ``_t("...")`` call with a literal first argument.""" + tree = ast.parse(SCRIPT.read_text(encoding="utf-8")) + out: set[str] = set() + for node in ast.walk(tree): + if (isinstance(node, ast.Call) and isinstance(node.func, ast.Name) + and node.func.id == "_t" and node.args + and isinstance(node.args[0], ast.Constant) + and isinstance(node.args[0].value, str) + and node.args[0].value): + out.add(node.args[0].value) + return out + + +def _data_texts(gen) -> set[str]: + """Texts the generator passes to ``_t()`` from its tables and its + classifiers rather than as literals.""" + out: set[str] = set() + out |= set(gen._FIRE_MODE_LABELS.values()) + out |= set(gen._DAMAGE_LABELS.values()) + out |= set(gen._CRAFT_CATEGORY_LABELS.values()) + out |= set(gen.MEDICAL_CONSUMABLE_EFFECTS.values()) + out |= {row[3] for row in gen._SPAWN_KEYWORD_TABLE} + out |= {label for _, label in gen._WRAPPER_HOSTILE_FALLBACK} + # The spawn bucket headers (_format_spawn_lines), the mission flags + # (_extract_mission_flags and the contract scan), the engagement types + # (_classify_mission_engagement) and the two section labels (write_ini). + out |= {"Hostiles", "Friendlies", "Objectives"} + out |= {"Chain", "Starter", "Unique"} + out |= {"Ship", "FPS", "FPS & Ship"} + out |= set(gen._SEPARATOR_LABELS) + return out + + +def expected_texts() -> list[str]: + gen = _load_generator("generate_enhancements_ini_text_keys") + return sorted(_literal_texts() | _data_texts(gen)) + + +def english_list_json(texts: list[str]) -> str: + data = { + "_comment": ( + "Every text Smart Citizen adds to the game strings (stat labels, " + "mission details, journal lines), in English. Each language's " + "enhancements.json maps these same English texts to its own " + "words: 'ht' for a human translation, 'at' for an AI draft. " + "Keep each {placeholder} as it is. Generated by " + "tests/test_enhancement_text.py --write; not loaded by the app." + ), + "strings": {t: {"ht": t, "at": ""} for t in texts}, + } + return json.dumps(data, ensure_ascii=False, indent=2) + "\n" + + +def _placeholders(text: str) -> set[str]: + return {f for _, f, _, _ in string.Formatter().parse(text) if f} + + +def _language_tables() -> dict[str, dict]: + out = {} + for path in sorted(LANGUAGES.glob("*/enhancements.json")): + if path.parent.name == "english": + continue + out[path.parent.name] = json.loads(path.read_text(encoding="utf-8")) + return out + + +class TestTheEnglishList: + def test_names_every_text_the_generator_writes(self): + assert ENGLISH_LIST.read_text(encoding="utf-8") == english_list_json(expected_texts()), ( + "languages/english/enhancements.json is out of date: run " + "python tests/test_enhancement_text.py --write" + ) + + +class TestTheLanguageTables: + def test_every_language_with_a_ui_has_a_table(self): + tables = _language_tables() + for ui in LANGUAGES.glob("*/ui.json"): + lang = ui.parent.name + if lang != "english": + assert lang in tables, f"languages/{lang}/enhancements.json is missing" + + @pytest.mark.parametrize("lang", sorted(_language_tables())) + def test_keys_are_english_texts_and_placeholders_kept(self, lang): + english = set(expected_texts()) + strings = _language_tables()[lang]["strings"] + unknown = sorted(set(strings) - english) + assert not unknown, f"{lang}: texts the generator never writes: {unknown}" + missing = sorted(english - set(strings)) + assert not missing, f"{lang}: texts with no entry: {missing}" + for key, leaf in strings.items(): + assert set(leaf) == {"ht", "at"}, (lang, key) + for text in (leaf["ht"], leaf["at"]): + if text: + assert _placeholders(text) == _placeholders(key), (lang, key, text) + assert "\n" not in text and "=" not in text, (lang, key, text) + + @pytest.mark.parametrize("lang", sorted(_language_tables())) + def test_tags_and_markup_are_kept(self, lang): + """An or a [CODE] in an English text stays in its translation.""" + for key, leaf in _language_tables()[lang]["strings"].items(): + text = leaf["ht"] or leaf["at"] + if text: + assert re.findall(r"<[^>]+>", text) == re.findall(r"<[^>]+>", key), (lang, key) + + +class TestTheTable: + def test_human_translation_wins_then_the_draft(self): + from src.utils.enhancement_text import parse_table + table = parse_table({"strings": { + "A": {"ht": "human", "at": "draft"}, + "B": {"ht": "", "at": "draft"}, + "C": {"ht": "", "at": ""}, + "D": {"ht": "D", "at": ""}, + }}) + assert table == {"A": "human", "B": "draft"} + + def test_english_and_unknown_languages_have_none(self): + from src.utils.enhancement_text import load_table, table_fingerprint + assert load_table("english") == {} + assert load_table(None) == {} + assert load_table("klingon") == {} + assert table_fingerprint("english") == "" + + def test_german_has_a_table(self): + from src.utils.enhancement_text import load_table, table_fingerprint + table = load_table("german") + assert table.get("Max HP") + assert len(table_fingerprint("german")) == 12 + + +class TestGeneratedText: + def test_english_run_writes_english(self): + gen = _load_generator() + gen._set_text_language("english") + assert gen._t("Max HP") == "Max HP" + assert gen._t("{count} items", count=3) == "3 items" + assert gen._localize_separators("x\\n\\n--- STATS ---\\ny") == "x\\n\\n--- STATS ---\\ny" + + def test_translated_run_writes_the_table(self, monkeypatch): + gen = _load_generator() + monkeypatch.setattr(gen, "_load_text_table", lambda lang: { + "Max HP": "Max. TP", "{count} items": "{count} Teile", + "--- STATS ---": "--- WERTE ---", "Standard": "Normal", + }) + gen._set_text_language("german") + try: + assert gen._t("Max HP") == "Max. TP" + assert gen._t("Regen") == "Regen" # no entry: English + assert gen._t("{count} items", count=3) == "3 Teile" + assert (gen._localize_separators("a\\n\\n--- STATS ---\\nb") + == "a\\n\\n--- WERTE ---\\nb") + finally: + gen._set_text_language(None) + + def test_mission_details_use_the_table(self, monkeypatch): + from lxml import etree as ET + gen = _load_generator() + monkeypatch.setattr(gen, "_load_text_table", lambda lang: { + "Engagement Type": "Einsatzart", "Ship": "Schiff", + "Mission Type": "Missionsart", "Standard": "Normal", + "Unique": "Einmalig", + }) + root = ET.fromstring('') + english = gen.enhancements_mission(root) + gen._set_text_language("german") + try: + german = gen.enhancements_mission(root) + finally: + gen._set_text_language(None) + assert "Engagement Type: Ship" in english + assert "Mission Type: Unique" in english + assert "Einsatzart: Schiff" in german + assert "Missionsart: Einmalig" in german + + def test_write_ini_swaps_the_section_label(self, tmp_path, monkeypatch): + gen = _load_generator() + monkeypatch.setattr(gen, "_load_text_table", + lambda lang: {"--- STATS ---": "--- WERTE ---"}) + gen._set_text_language("german") + try: + out = tmp_path / "x.ini" + gen.write_ini(out, {"k": "desc\\n\\n--- STATS ---\\nMax HP: 5"}) + finally: + gen._set_text_language(None) + assert out.read_text(encoding="utf-8").strip() == "k=desc\\n\\n--- WERTE ---\\nMax HP: 5" + + def test_language_is_read_from_a_translated_base_ini_path(self, tmp_path, monkeypatch): + """A CLI run over cache/lang//base.ini writes that language.""" + gen = _load_generator() + seen = [] + monkeypatch.setattr(gen, "_load_text_table", lambda lang: seen.append(lang) or {}) + base = tmp_path / "lang" / "german" / "base.ini" + base.parent.mkdir(parents=True) + base.write_text("a=b\n", encoding="utf-8") + with pytest.raises(FileNotFoundError): # no DataForge cache: stops after the parse + gen.main(base, tmp_path / "missing") + assert seen == ["german"] + + +class TestTheStamp: + def test_english_stamp_is_the_build_key(self): + from src.utils.settings import AppSettings + assert AppSettings.enhancements_stamp_value("123", "english") == "123" + + def test_translated_stamp_carries_its_table(self): + from src.utils.enhancement_text import table_fingerprint + from src.utils.settings import AppSettings + value = AppSettings.enhancements_stamp_value("123", "german") + assert value == f"123|text={table_fingerprint('german')}" + + def test_a_table_change_makes_the_set_stale(self, monkeypatch): + from src.utils import enhancement_text + from src.utils.settings import AppSettings + monkeypatch.setattr(AppSettings, "get_dataforge_build_key", + staticmethod(lambda forge_dir=None: "123")) + monkeypatch.setattr(AppSettings, "get_enhancements_stamp", + staticmethod(lambda language=None: "123|text=aaaaaaaaaaaa")) + monkeypatch.setattr(enhancement_text, "table_fingerprint", lambda lang: "aaaaaaaaaaaa") + assert AppSettings.enhancements_built_from_current_dataforge("german") + monkeypatch.setattr(enhancement_text, "table_fingerprint", lambda lang: "bbbbbbbbbbbb") + assert not AppSettings.enhancements_built_from_current_dataforge("german") + + +if __name__ == "__main__": + if sys.argv[1:] == ["--write"]: + ENGLISH_LIST.write_text(english_list_json(expected_texts()), encoding="utf-8") + print(f"Wrote {ENGLISH_LIST}") + else: + print("usage: python tests/test_enhancement_text.py --write") diff --git a/tests/test_enhancements_stale_startup.py b/tests/test_enhancements_stale_startup.py index ddf0ea95..c76e2944 100644 --- a/tests/test_enhancements_stale_startup.py +++ b/tests/test_enhancements_stale_startup.py @@ -152,7 +152,10 @@ def _write_set(language: str) -> None: def _stamp(language: str, state: str) -> None: """Set *language*'s .dataforge_stamp: "current", "older" or "empty".""" if state == "current": - AppSettings.set_enhancements_stamp(AppSettings.get_dataforge_build_key(), language) + # What a run writes: a translated language's stamp carries its + # enhancements.json too (#579). + AppSettings.set_enhancements_stamp(AppSettings.enhancements_stamp_value( + AppSettings.get_dataforge_build_key(), language), language) elif state == "older": AppSettings.set_enhancements_stamp("1600000000.0", language) else: diff --git a/tests/test_language_translation_check.py b/tests/test_language_translation_check.py new file mode 100644 index 00000000..54022710 --- /dev/null +++ b/tests/test_language_translation_check.py @@ -0,0 +1,187 @@ +"""The startup check for a newer community translation (#579). + +A language switch downloads the selected language's global.ini, but nothing +else did, so after a game patch the table kept the old translation. Each +start now fetches it again in the background (a conditional request, URL +sources only) and, when a new file came down, empties that language's +enhancements stamp and reloads through the language switch's own path. + +The real MainWindow methods run on a MagicMock self, as in +test_run_in_background.py, with the worker and AppSettings faked. +""" +from __future__ import annotations + +import sys +from pathlib import Path +from unittest.mock import MagicMock + +import pytest + +REPO = Path(__file__).resolve().parent.parent +if str(REPO) not in sys.path: + sys.path.insert(0, str(REPO)) + +from src.gui import main_window as mw # noqa: E402 +from src.gui.main_window import MainWindow # noqa: E402 + +pytestmark = pytest.mark.unit + +URL = "https://example.invalid/german/global.ini" + + +class FakeWorker: + made: list = [] + + def __init__(self, source, dest): + self.source, self.dest = source, dest + self.changed = False + self.started = False + self.finished = MagicMock() + FakeWorker.made.append(self) + + def start(self): + self.started = True + + def quit(self): + pass + + def wait(self, *_): + return True + + def isRunning(self): + return False + + +@pytest.fixture +def env(monkeypatch, tmp_path): + FakeWorker.made = [] + state = {"language": "german", "url": URL, "invalidated": [], "sources": []} + dest = tmp_path / "lang" / "german" / "base.ini" + S = mw.AppSettings + monkeypatch.setattr(mw, "LanguageBaseDownloadWorker", FakeWorker) + monkeypatch.setattr(S, "get_selected_language", staticmethod(lambda: state["language"])) + monkeypatch.setattr(S, "get_language_base_url", staticmethod(lambda lang: state["url"])) + monkeypatch.setattr(S, "get_base_ini_path", staticmethod(lambda lang=None: dest)) + monkeypatch.setattr(S, "get_enhancements_dir", staticmethod(lambda lang=None: dest.parent)) + monkeypatch.setattr(S, "invalidate_enhancements_stamp", + staticmethod(lambda folder: state["invalidated"].append(folder))) + monkeypatch.setattr(S, "set_source_path", + staticmethod(lambda name, path: state["sources"].append((name, path)))) + monkeypatch.setattr(mw.QTimer, "singleShot", staticmethod(lambda *a, **k: None)) + + win = MagicMock() + win._close_committed = False + win._lang_check_worker = None + win._lang_dl_worker = None + win._loader_worker = None + win._simple_run_active = False + win._job_running.return_value = False + asks = [] + win._ask_after_the_job.side_effect = asks.append + win._on_language_translation_checked = ( + lambda *a: MainWindow._on_language_translation_checked(win, *a)) + state.update(win=win, asks=asks, dest=dest) + return state + + +def _start(env): + MainWindow._check_language_translation_at_startup(env["win"]) + return FakeWorker.made[-1] if FakeWorker.made else None + + +def _finish(env, worker, ok=True, changed=True): + worker.changed = changed + if changed: + env["dest"].parent.mkdir(parents=True, exist_ok=True) + env["dest"].write_text("k=v\n", encoding="utf-8") + MainWindow._on_language_translation_checked(env["win"], worker, "german", env["dest"], ok) + + +class TestWhatIsChecked: + def test_a_url_source_is_fetched_in_the_background(self, env): + worker = _start(env) + assert worker is not None and worker.started + assert worker.source == URL and worker.dest == env["dest"] + assert env["win"]._lang_check_worker is worker + + def test_english_checks_nothing(self, env): + env["language"] = "english" + assert _start(env) is None + + @pytest.mark.parametrize("source", ["", r"C:\Games\korean\global.ini"]) + def test_no_url_or_a_local_file_checks_nothing(self, env, source): + env["url"] = source + assert _start(env) is None + + def test_not_while_a_switch_downloads_or_closing(self, env): + env["win"]._lang_dl_worker = object() + assert _start(env) is None + env["win"]._lang_dl_worker = None + env["win"]._close_committed = True + assert _start(env) is None + + def test_the_startup_gate_runs_it(self): + import inspect + src = inspect.getsource(MainWindow._continue_startup_after_update_gate) + assert "self._check_language_translation_at_startup()" in src + + +class TestWhatAChangeDoes: + def test_an_unchanged_file_changes_nothing(self, env): + worker = _start(env) + _finish(env, worker, changed=False) + assert env["win"]._lang_check_worker is None + assert env["invalidated"] == [] and env["asks"] == [] + env["win"]._reload_with_language_enhancements.assert_not_called() + + def test_a_failed_fetch_changes_nothing(self, env): + worker = _start(env) + _finish(env, worker, ok=False, changed=False) + assert env["invalidated"] == [] and env["asks"] == [] + + def test_a_new_file_makes_the_set_stale_and_reloads(self, env): + worker = _start(env) + _finish(env, worker) + assert env["invalidated"] == [env["dest"].parent] + env["win"].enhancements_tab.refresh_enhancements_dirty_state.assert_called_once() + assert len(env["asks"]) == 1 + env["asks"].pop()() + assert env["sources"] == [(mw.AppSettings.SOURCE_GLOBAL, str(env["dest"]))] + env["win"]._reload_with_language_enhancements.assert_called_once_with("german") + + def test_the_reload_waits_for_a_load_or_a_job(self, env): + worker = _start(env) + _finish(env, worker) + reload_with_it = env["asks"].pop() + env["win"]._job_running.return_value = True + reload_with_it() + assert env["asks"] == [reload_with_it] + env["win"]._reload_with_language_enhancements.assert_not_called() + env["win"]._job_running.return_value = False + env["asks"].pop()() + env["win"]._reload_with_language_enhancements.assert_called_once_with("german") + + def test_a_language_switch_meanwhile_drops_it(self, env): + worker = _start(env) + env["language"] = "french" + _finish(env, worker) + assert env["invalidated"] == [] and env["asks"] == [] + + def test_a_switch_after_the_download_drops_the_reload(self, env): + worker = _start(env) + _finish(env, worker) + env["language"] = "french" + env["asks"].pop()() + env["win"]._reload_with_language_enhancements.assert_not_called() + + def test_closing_drops_it(self, env): + worker = _start(env) + env["win"]._close_committed = True + _finish(env, worker) + assert env["asks"] == [] + + def test_a_released_worker_is_ignored(self, env): + worker = _start(env) + env["win"]._lang_check_worker = None + _finish(env, worker) + assert env["asks"] == []