From 62516cb750626dcdaa56141c17e4bddb0fe7917f Mon Sep 17 00:00:00 2001 From: seedds Date: Wed, 14 Oct 2026 18:09:30 +0800 Subject: [PATCH] Fire Emblem Engage profile (bring-up started) - dm/games/fe_engage: identity and the 2.0.0 build IDs (main, subsdk0, sdk), modules in Horizon load order, RomFS marker, empty shader tables and their chain header. Memory: an 8 GB reservation with a 5.5 GB alias region for its virtual address memory (Mac only for now: iOS allows at most 6 GB without the extended-addressing entitlement); NVN constants are Mario's until measured. - On the Mac the host boots Engage through Unity's startup and runs to the opening movie with nothing on screen yet: its shaders are in UnityFS bundles that shader_split.py cannot read, and movies are not decoded. - README: the games table row. --- README.md | 2 +- dm/games/fe_engage/bf_want.tsv | 1 + dm/games/fe_engage/c1_full.tsv | 1 + dm/games/fe_engage/dmsh_chain.h | 2 + dm/games/fe_engage/game.tsv | 50 +++++++++++++++++++ dm/games/fe_engage/pso_manifest.tsv | 2 + dm/games/fe_engage/shader_facts.tsv | 1 + dm/games/fe_engage/shader_map.tsv | 2 + .../fe_engage/shader_map.tsv.conflicts.tsv | 2 + dm/games/fe_engage/shader_pairs.tsv | 1 + 10 files changed, 63 insertions(+), 1 deletion(-) create mode 100644 dm/games/fe_engage/bf_want.tsv create mode 100644 dm/games/fe_engage/c1_full.tsv create mode 100644 dm/games/fe_engage/dmsh_chain.h create mode 100644 dm/games/fe_engage/game.tsv create mode 100644 dm/games/fe_engage/pso_manifest.tsv create mode 100644 dm/games/fe_engage/shader_facts.tsv create mode 100644 dm/games/fe_engage/shader_map.tsv create mode 100644 dm/games/fe_engage/shader_map.tsv.conflicts.tsv create mode 100644 dm/games/fe_engage/shader_pairs.tsv diff --git a/README.md b/README.md index b454e85..1536789 100644 --- a/README.md +++ b/README.md @@ -12,7 +12,7 @@ The project is built from the generic parts of [d2r-mobile](../d2r-mobile) (MIT) | Game | Profile | State | |---|---|---| | Super Mario Bros. Wonder (base game v0, update 1.2.1) | `smbw` | **Playable on the iPhone with sound through several levels**: an 11-minute session at 60 fps with no crash and no audio dropouts. Scripted Mac runs reach the opening course. Notes are in the [Super Mario Bros. Wonder](#super-mario-bros-wonder-smbw) section | -| Fire Emblem Engage | none | Surveyed, not ported: Unity 2020.3 IL2CPP on SDK 12.3.7. Its shaders are in UnityFS bundles (27,152 of them), which `shader_split.py` cannot read yet | +| Fire Emblem Engage | `fe_engage` | Bring-up started (Unity 2020.3 IL2CPP, SDK 12.3.7): on the Mac it boots through Unity's startup and runs to the opening movie, with nothing on screen yet. Next: its shaders, which sit in UnityFS bundles (27,152 of them) that `shader_split.py` cannot read yet, and the movies (VP9 WebM; the hardware decoder is stubbed) | ## Status diff --git a/dm/games/fe_engage/bf_want.tsv b/dm/games/fe_engage/bf_want.tsv new file mode 100644 index 0000000..54caeb8 --- /dev/null +++ b/dm/games/fe_engage/bf_want.tsv @@ -0,0 +1 @@ +# generated diff --git a/dm/games/fe_engage/c1_full.tsv b/dm/games/fe_engage/c1_full.tsv new file mode 100644 index 0000000..b8d3ca5 --- /dev/null +++ b/dm/games/fe_engage/c1_full.tsv @@ -0,0 +1 @@ +# chain b-1bd214f43955 2026-10-14T15:37:40+08:00 diff --git a/dm/games/fe_engage/dmsh_chain.h b/dm/games/fe_engage/dmsh_chain.h new file mode 100644 index 0000000..9f5d827 --- /dev/null +++ b/dm/games/fe_engage/dmsh_chain.h @@ -0,0 +1,2 @@ +// 生成文件(dm/gfx/tools/dmsh_chain.py --header,游戏 fe_engage):本源码树期望的 B 着色器库翻译链版本(缺省选项);宿主只加载 <库目录>/b-/ +#define DMSH_CHAIN "1bd214f43955" diff --git a/dm/games/fe_engage/game.tsv b/dm/games/fe_engage/game.tsv new file mode 100644 index 0000000..a45a280 --- /dev/null +++ b/dm/games/fe_engage/game.tsv @@ -0,0 +1,50 @@ +# 火焰纹章 Engage(Switch,基础版 v0 + 更新 2.0.0 = v327680)的游戏档案。移植刚起步:只有身份、构建号与模块;内存与 NVN 常数先沿用马力欧的,起机时实测再改 +# Game profile of Fire Emblem Engage (Switch, base game v0 + update 2.0.0 = v327680). The port has just started: only identity, build IDs and modules; the memory and NVN constants are Mario's for now, to be measured during bring-up +# 格式见 dm/games/README.md | Format: see dm/games/README.md +# Unity 2020.3.18f1(IL2CPP),SDK 12.3.7:着色器在 RomFS/Data/StreamingAssets 的 UnityFS 包里,shader_split.py 还读不到,着色器表暂空 | Unity 2020.3.18f1 (IL2CPP), SDK 12.3.7: the shaders sit in UnityFS bundles under RomFS/Data/StreamingAssets, which shader_split.py cannot read yet, so the shader tables are empty for now + +# ---- 身份 | Identity ---- +title_id 0100A6301214E000 +program_id 0100A6301214E000 + +# ---- App ---- +app_name FE Engage +bundle_id org.feengage.app +ipa FEEngage.ipa +app_category public.app-category.strategy-games + +# ---- 版本 | Versions ---- +# 只解了合并 2.0.0 的那份;基础版单独的构建号用到时再补 | only the merged 2.0.0 copy is extracted; the base game's own build IDs are added when needed +build v327680 2.0.0 main=8c08b9719e085f91847b5e0f935d9488 subsdk0=bffed55ea46c1b48ddeabcacdfbf81bf sdk=56ec24747ec9e7f19b3efb062483a19d +package v327680 +shader_versions v327680 + +# ---- 文件 | Files ---- +# 装载顺序同 Horizon:main、subsdk*、sdk(subsdk0 = NintendoSDK_movie) | load order as on Horizon: main, subsdk*, sdk (subsdk0 = NintendoSDK_movie) +modules main subsdk0 sdk +romfs_marker Data/data.unity3d +zip_store .bundle:.wem:.unity3d:.metallib + +# ---- 内存 | Memory ---- +# NPDM 声明系统资源 16 MB,所以 IsVirtualAddressMemoryEnabled 为真:nninitStartup 把整个空闲内存(约 3.2 GB)作虚拟地址内存交给 StandardAllocator, +# 要在别名区里一次分到这么大的地址区域(较新 SDK 的 AddressRegionManager 先占别名区开头约 1 GB 作节点区)。马力欧的 2.875 GB 别名区不够(StandardAllocator::Initialize 中止)。 +# 先给 Mac 起机用:预留 8 GB、别名区 5.5 GB。iOS 没有「扩展虚拟寻址」授权时单块预留最多 6 GB,到时再定(授权,或少报内存池) +# The NPDM declares 16 MB of system resource, so IsVirtualAddressMemoryEnabled is true: nninitStartup hands all free memory (about 3.2 GB) to StandardAllocator as virtual address memory, +# which needs one address region that large in the alias region (newer SDKs' AddressRegionManager first takes about 1 GB at the start of the alias region as its node area). Mario's 2.875 GB alias region is too small (StandardAllocator::Initialize aborts). +# For Mac bring-up for now: an 8 GB reservation with a 5.5 GB alias region. On iOS without the "extended virtual addressing" entitlement a single reservation is at most 6 GB; decide then (the entitlement, or a smaller reported pool) +mem_reserve 0x200000000 +mem_alias 0x160000000 +mem_stack 0x10000000 +app_pool 0xCD500000 + +# ---- NVN 驱动常量段(马力欧的值,待按 Engage 的着色器实测) | NVN driver constant segments (Mario's values, to be measured on Engage's shaders) ---- +nvn_tex_base 0x20 +nvn_tex_slots 32 +nvn_samp_base 0x568 +nvn_img_base 0x120 +nvn_img_slots 8 +nvn_ssbo_bases vs=0x110 ps=0x510 cs=0x310 + +# ---- 着色器拆分(尚未适用:Unity 着色器要先写 UnityFS 读取) | Shader split (not applicable yet: Unity shaders need a UnityFS reader first) ---- +shader_groups /StreamingAssets/=unity +shader_note Engage 着色器(尚未拆出:在 UnityFS 包里) diff --git a/dm/games/fe_engage/pso_manifest.tsv b/dm/games/fe_engage/pso_manifest.tsv new file mode 100644 index 0000000..8539a5d --- /dev/null +++ b/dm/games/fe_engage/pso_manifest.tsv @@ -0,0 +1,2 @@ +# 预热种子清单(随包,与 shader_map.tsv 同目录)。行:S着色器键阶段 / R渲染管线键(pso_skey 十六进制)/ C计算着色器键。 +# 本作尚未录制(DM_PSO_RECORD):空表 = 不预热。行序 = 首次使用顺序,不要排序。 diff --git a/dm/games/fe_engage/shader_facts.tsv b/dm/games/fe_engage/shader_facts.tsv new file mode 100644 index 0000000..c36dfe1 --- /dev/null +++ b/dm/games/fe_engage/shader_facts.tsv @@ -0,0 +1 @@ +# 翻译查询的作答表(dm/gfx/tools/shader_split.py 生成,勿手改):键 事实 JSON。表空:着色器尚未拆出 | translation query answers (generated, do not edit): key facts JSON. Empty: shaders not split out yet diff --git a/dm/games/fe_engage/shader_map.tsv b/dm/games/fe_engage/shader_map.tsv new file mode 100644 index 0000000..ed2196f --- /dev/null +++ b/dm/games/fe_engage/shader_map.tsv @@ -0,0 +1,2 @@ +# kind: evidence Engage 着色器:尚未拆出(Unity 着色器在 UnityFS 包里,shader_split.py 还读不到)| Engage shaders: not split out yet (Unity shaders sit in UnityFS bundles, which shader_split.py cannot read yet) +package index stage dm_ctl_sha16 source diff --git a/dm/games/fe_engage/shader_map.tsv.conflicts.tsv b/dm/games/fe_engage/shader_map.tsv.conflicts.tsv new file mode 100644 index 0000000..5be7a60 --- /dev/null +++ b/dm/games/fe_engage/shader_map.tsv.conflicts.tsv @@ -0,0 +1,2 @@ +# kind: evidence 控制段键冲突裁定:表空 | control-section key conflict rulings: empty +dm_ctl_sha16 chosen_pc class candidates records diff --git a/dm/games/fe_engage/shader_pairs.tsv b/dm/games/fe_engage/shader_pairs.tsv new file mode 100644 index 0000000..c79f621 --- /dev/null +++ b/dm/games/fe_engage/shader_pairs.tsv @@ -0,0 +1 @@ +# kind: evidence 顶点 / 像素着色器配对(dm/gfx/tools/shader_split.py 生成,勿手改):表空 | vertex / pixel shader pairs (generated, do not edit): empty