localize
它能做什么
这个技能执行把游戏翻译成其他语言所需的步骤,从查找硬编码文本到检查翻译和从右到左的版面。适合准备本地化版本的游戏团队。
适用场景
- ✓当游戏中有直接写在代码里的文本,需要移入翻译文件的时候。
- ✓当团队希望检查翻译是否完整,并且能否适配屏幕的时候。
- ✓当游戏正在为从右到左书写的语言做准备的时候。
技能链接
https://github.com/Donchitos/Claude-Code-Game-Studios/blob/main/.claude/skills/localize/SKILL.md复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。
使用方法
最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。
可直接粘贴的消息
适用于 Claude Code、Codex 或 Cursor:在项目文件夹中运行,即可安装该技能。
下载 SKILL.md,放进智能体的技能文件夹。
可以这样问 AI
“请找出我游戏中所有的硬编码文本,并为翻译成西班牙语和德语做好准备。”
每周 5 个新技能,1 分钟读完。
工作原理
这个技能会运行几种模式之一,例如扫描硬编码文本、提取字符串表、验证翻译,或运行完整的质量循环。你选择需要的模式,技能会涵盖从提取文本到最终检查的整个过程。
技术内容(原始 SKILL.md)
作者在 GitHub 上的英文原文。
!bash "${CLAUDE_SKILL_DIR}/../../hooks/yaml-helper.sh" resolve_config --keys automation
Localization Pipeline
Localization is not just translation — it is the full process of making a game feel native in every language and region. Poor localization breaks immersion, confuses players, and blocks platform certification. This skill covers the complete pipeline from string extraction through cultural review, VO recording, RTL layout testing, and localization QA sign-off.
Modes:
scan— Find hardcoded strings and localization anti-patterns (read-only)extract— Extract strings and generate translation-ready tablesvalidate— Check translations for completeness, placeholders, and lengthstatus— Coverage matrix across all localesbrief— Generate translator context briefing document for an external teamcultural-review— Flag culturally sensitive content, symbols, colours, idiomsvo-pipeline— Manage voice-over localization: scripts, recording specs, integrationrtl-check— Validate RTL language layout, mirroring, and font supportfreeze— Enforce string freeze; lock source strings before translation beginsqa— Run the full localization QA cycle before release
If no subcommand is provided, output usage and stop. Verdict: FAIL — missing required subcommand.
Every AskUserQuestion call follows .claude/docs/automation-modes.md
(collaborative asks always · guided major-only · autonomous logs and proceeds;
automation_always_ask categories always prompt).
Phase 2A: Scan Mode
Search the code root (resolve per .claude/docs/code-root-resolution.md) for hardcoded user-facing strings. If the code root is unresolved, report NOT ASSESSED — code root unresolved rather than zero hits. Zero hits from an unresolved root reads as "nothing to localize", which is the failure this guards:
- String literals in UI code not wrapped in a localization function (
tr(),Tr(),NSLocalizedString,GetText, etc.) - Concatenated strings that should be parameterized
- Strings with positional placeholders (
%s,%d) instead of named ones ({playerName}) - Format strings that mix locale-sensitive data (numbers, dates, currencies) without locale-aware formatting
Search for localization anti-patterns:
- Date/time formatting not using locale-aware functions
- Number formatting without locale awareness (
1,000vs1.000) - Text embedded in images or textures (flag asset files in
assets/) - Strings that assume left-to-right text direction (positional layout, string assembly order)
- Gender/plurality assumptions baked into string logic (must use plural forms or gender tokens)
- Hardcoded punctuation (e.g.
"You won!"— exclamation styles vary by locale)
Report all findings with file paths and line numbers. This mode is read-only — no files are written.
Phase 2B: Extract Mode
- Scan all source files for localized string references
- Compare against the existing string table in
assets/data/strings/ - Generate new entries for strings not yet keyed
- Suggest key names following the convention:
[category].[subcategory].[description]- Example:
ui.hud.health_label,dialogue.npc.merchant.greeting,menu.main.play_button
- Example:
- Each new entry must include a
contextfield — a translator comment explaining:- Where it appears (which screen, which scene)
- Maximum character length
- Any placeholder meaning (
{playerName}= the player's chosen display name) - Gender/plurality context if applicable
Output a diff of new strings to add to the string table.
Present the diff to the user. Ask: "May I write these new entries to assets/data/strings/strings-en.json?"
If yes, write only the diff (new entries), not a full replacement. Verdict: COMPLETE — strings extracted and written.
Phase 2C: Validate Mode
Read all string table files in assets/data/strings/. For each locale, check:
- Completeness — key exists in source (en) but no translation for this locale
- Placeholder mismatches — source has
{name}but translation omits it or adds extras - String length violations — translation exceeds the character limit recorded in the source
contextfield - Plural form count — locale requires N plural forms; translation provides fewer
- Orphaned keys — translation exists but nothing in the code root references the key
- Stale translations — source string changed after translation was written (flag for re-translation
常见问题
它会自己翻译文本吗?
这个技能负责准备和检查流程,包括为外部翻译团队编写的说明文档。
什么是字符串冻结?
这是一个锁定源文本的时间点,让译者只处理不会再变化的文本。
文化审查检查什么?
它会标记符号、颜色和习语等可能不适合某些地区的内容。
详情
作者的原始描述
Localization pipeline — find hardcoded strings, extract string tables, cultural review, VO, RTL, enforce string freeze.
热度
- GitHub 星标
- 33k
- 排名
- #8461
- 许可证
- MIT
- 更新时间
- 2026/10/18
评论
- …