docs: finalize accepted tutorial localization and handoff guide

This commit is contained in:
DragonHD
2026-09-20 12:26:57 +08:00
parent b7ae04ec18
commit 6c5f86f628
4 changed files with 84 additions and 4 deletions
+7
View File
@@ -205,3 +205,10 @@ so centred labels (the "Start New Game" button) were flushed right. Fixed to
- Backup: `E:/DragonHD/backup_game/tutorial-complete-20260920/Tutorial.dsc`. Rollback to the accepted five-group version tested on an isolated copy. Deployed after stopping the game under existing authorization; installed bytes reread and match output. SHA256: `720b7fce23b80405d6c8af2a1302ed95c085a072d8c8ecbae49b9db2cb32b8e3`.
- Rebuild: `python tools/script_text.py --source E:/DragonHD/backup_game/tutorial-step1-20260920/Tutorial.dsc --mapping tools/tutorial_cn.json --out E:/DragonHD/build/tutorial-complete/Tutorial.dsc --allow-alignment-changes`.
- Remaining acceptance: native playthrough from height through completion. Automated layout and byte checks do not prove the full gameplay chain; user has verified the earlier five groups and punctuation fix.
## 2026-09-20 — Final acceptance and Gitea handoff
- User confirmed the complete tutorial has no issues and requested repository organization/push. This supersedes pending acceptance notes in the historical trial entries above.
- Re-ran all 39 targeted tests: pass. Re-verified the installed tutorial: all 57 display literals translated and all other bytes unchanged.
- Added `docs/tutorial-localization.md` with final scope, hashes, build/test instructions, restoration procedure and font-update caveats. README now links the accepted deliverable and tools.
- Complete tutorial, font punctuation and prior layout fixes are on `codex/tutorial-step1`; no generated game binaries/assets are included. Subsequent main-mission translation and HD batches have not started.
@@ -186,6 +186,6 @@ def validate_size(original, result):
- [x] 剩余教程完整翻译,含两处原版引号异常的施法说明:57/57 显示字面量、42 条映射。
- [x] 39 项回归测试、字库覆盖、非显示字节一致、三种宽度排版、独立副本回滚验证。
- [x] 全量教程部署并重读校验。
- [ ] 从飞行高度至教程结束的完整实机流程验收
- [x] 用户确认完整教程没有问题(2026-09-20)
Task 1 的翻译部署已完成;实机验收完成前,整体完成门槛仍保持待验收
Task 1 的翻译部署与用户实机验收完成。最终交付说明见 `docs/tutorial-localization.md`。前文未勾选的分批试作项保留为历史记录,以本条最终状态为准
+58
View File
@@ -0,0 +1,58 @@
# 教程汉化交付说明
## 当前结果(2026-09-20
用户已确认完整教程及字体修正“没有问题”。本次验收来自用户实机反馈;自动化检查覆盖字节、编码、排版与回滚,不替代实机操作。
- 教程全部 57 处标题、消息正文、任务说明使用 42 条中文映射。
- 范围包括开场、镜头、飞行、高度、攻击、蓄力、吐息、进食、法术、速度控制和结束提示。
- 开场及后续新增页面使用居中短句;此前已验收的镜头说明保留原有格式。
- 句号在 12×12 字格中下移 3 像素,边界由 `(2,5,6,9)` 变为 `(2,8,6,12)`;字宽和其他字符不变。
- 按钮中文与快捷键不再重叠,选项页标题按实际文字宽度居中。
- 原事件、按键绑定、资源路径、等待与判定条件保持原字节。
## 教程构建
在仓库根目录使用 Python。将路径换为本机位置,`Tutorial.original.dsc` 必须是保留的原版英文脚本,而非已经汉化的文件。
```powershell
python tools/script_text.py --source "C:/DragonWork/Tutorial.original.dsc" --mapping tools/tutorial_cn.json --out "C:/DragonWork/build/Tutorial.dsc" --allow-alignment-changes
python tools/verify_tutorial_step1.py modified "C:/DragonWork/Tutorial.original.dsc" "C:/DragonWork/build/Tutorial.dsc"
```
工具同时生成 `Tutorial.manifest.json`。验证器沿用早期文件名,目前检查的是完整教程。
| 文件 | SHA256 |
|---|---|
| 原版英文输入 | `bd959758223b976ffac35b4ef7d94661f62060c1134316eddb559772d544e02c` |
| 完整中文输出 | `720b7fce23b80405d6c8af2a1302ed95c085a072d8c8ecbae49b9db2cb32b8e3` |
默认严格保留控制符;`--allow-alignment-changes` 仅允许替换同一位置的对齐/缩进控制符,换行顺序及数量仍受检查。原版施法正文两处未转义的 `"F"` 采用专门识别,不扩大到一般表达式。百分数文字 `0% is` 与实际格式占位符分别处理。
## 验证
字体排版测试需要 `unicorn`,位图测试需要 `Pillow`;排版测试默认读取已修补的本机游戏程序,路径可通过 `tools/test_cjk_layout.py``DEFAULT_EXE` 统一调整。
```powershell
$tests = @('test_script_text.py', 'test_tutorial_intro.py', 'test_tutorial_flight.py', 'test_tutorial_complete.py', 'test_cjk_layout.py', 'test_cjk_titles.py', 'test_full_stop.py')
foreach ($test in $tests) {
python "tools/$test"
if ($LASTEXITCODE -ne 0) { throw "Test failed: $test" }
}
```
最新运行:39 项通过。完整教程校验输出 `MODIFIED: all 57 display literals translated; all other bytes unchanged; PASS`。新页面在 360/400/480 像素宽度下检查行首标点、中心坐标和总高度。所有中文字符均核对存在于已生成的 GB2312 字库中。
## 安装与恢复
本次本机安装已经完成;以下步骤用于以后重建。游戏退出后,先备份当前 `Data/Scripts/English/Tutorial.dsc`,再用生成的同名文件替换。保持已有 CJK 程序补丁、字库及字体表。
恢复教程只需把该次备份复制回相同位置,核对 SHA256;不需要重装字体或重建程序。本次已在独立副本执行恢复,字节与备份一致。最后一批的备份是 `E:/DragonHD/backup_game/tutorial-complete-20260920/Tutorial.dsc`,内容为已验收的前五组汉化版本。
句号修正通过 `tools/fix_full_stop.py --source <原字库.TGA> --cells <cells.json> --out <新字库.TGA>` 生成。部署须同步更新松散字库和 `Textures.res``UI\Overhead\Shrift_gb_Germany.TGA` 条目;保留并恢复这两个文件的成对备份。`tools/build_cjk.py` 已包含相同修正,重新生成字库时不会丢失。
不要为单独更新教程重新执行 `install_cjk.py install`:它会重建并部署整套程序/字体/字符串文件。
## 下一阶段
教程已经验收。后续主线汉化或高清素材试作按独立批次推进,尚未在本次启动。历史试作记录见 `DEVLOG.md`,其中早期“待验收”状态以本说明和最终验收条目为准。