外观
BTL 运行语义索引
本目录记录跨 Record 的运行时关系。它不重新定义 Route 5 的完整 Battle Runtime 规则,而是说明 BTL 输入如何进入原版对象和 consumer。
如果目标是直接查询 ActionType、TriggerType、OperationType 等数值含义,优先进入 值域速查。
专题 Reference
- Fallback AI 主行为 0~4:串联 Unit 持久字段、ArmyAIConfig 调度、Event 覆盖、
0x1000~0x8000候选组,以及 mode2 的一格战略落脚和精确评分差异。
后续章节主要包括:
- BTL loader / section construction pipeline;
- Terrain 的 embedded/world.bin 来源、16-byte raw slice、MapTerrain、TerrainType、Runtime Tile 与表现分层;
- v1 record conversion;
- Country/Tile/Province/Building/Unit 的构造与引用;
- Event/Reinforcement registry;
- BTL 字段到 runtime state 的 copy / transform / lookup;
BattleMode、owner、feature 等条件化 consumer;- serialized input、runtime-derived state 与 runtime-only state 的边界。
已确认的总体原则
原版不会把所有 BTL 记录作为长期 opaque blob 直接使用。多个记录在加载时被解析、查定义、转换并写入独立 runtime object。
例如 Unit 主链:
text
raw Unit record
-> resolve Tile
-> resolve ArmySettings
-> allocate runtime Unit
-> initialize Unit
-> apply disk state
-> attach to Tile/Country collections因此 Reference 中必须分别标出“磁盘字段”和“runtime consumer”,不能把 runtime object layout 当 BTL 磁盘 layout。
Terrain 是最典型的多层例子:同一个 raw byte 可以先作为磁盘记录字段,再进入 def_mapterrain identity、def_terraintype 规则、Runtime derived cost 和渲染 consumer。完整链见 Terrain Record。
主要总体证据:reports/btl_v1280_so_recovery.md。