lotr2_battle_tile — siege battle map cell
Header: lotr2_battle_tile.h
Summary
Castle siege battles use an 80×80 tile map parallel to the figure array. Each cell is 8 bytes; layouts load from castles.dat (0x3200-byte slice per castle). Gates, walls, oil cauldrons, moat, and the victory flag are encoded as tile_type values.
- Confidence: likely
- Stride: 8 bytes
- Index:
(map_y * 0x50 + map_x) * 8
Module: combat MODULE. Stats: lotr2_unit_stats.md.
Offset table
| Offset |
Field |
Symbol |
Description |
| +0x00 |
damage_counter |
lotr2_battle_tile_damage_ctr |
Gate/wall HP; ram, catapult, manual hack |
| +0x01 |
flags_a |
— |
Bit 1 = water; bit 2 = moat edge |
| +0x02 |
flags_b |
— |
Passability / render flags |
| +0x03 |
terrain_sprite |
— |
Modified by moat fill, breaches, oil |
| +0x04 |
elevation |
— |
Height; affects LOS and wall hits |
| +0x07 |
tile_type |
lotr2_battle_tile_type |
Object discriminator |
Tile type IDs
| ID |
Object |
Evidence |
| 0 |
Open ground |
Moat-fill target @ 0x0041198e |
| 1 |
Open gate passage |
lotr2_siege_open_gate sets type 1 |
| 2 |
Castle gate / drawbridge |
Manual hack @ lotr2_siege_tick_gate_hack |
| 3 |
Wall breach |
Spread / catapult breach @ 0x0041198e |
| 4 |
Intact wall |
Catapult target; breach when damage_counter > 15 |
| 5 |
Gate face (ram) |
From castles.dat type 7 → runtime 5 |
| 7 |
Boiling oil cauldron |
Defender pour @ 0x0048bf56 area |
| 9 |
Moat water |
Render path @ 0x00483570 region |
| 10 |
Active oil spill |
Set by lotr2_siege_pour_boiling_oil |
| 14 |
Victory flag |
Win condition @ 0x0041198e |
Names likely pending l2.eng.
Damage thresholds
| Constant |
Value |
Effect |
lotr2_siege_gate_break_threshold |
15 |
Gate destroyed after 15 hits |
| Wall breach |
damage_counter > 15 |
Breach via wall hit handler |
Evidence
| Claim |
Source |
| 8-byte stride |
iStack_1c += 8 in lotr2_siege_load_castle_layout |
| castles.dat 0x3200 read |
__read(..., 0x3200) in lotr2_siege_load_castle_layout @ 0x004c8dfb |
| Oil cauldron pour |
lotr2_siege_pour_boiling_oil // was thunk_FUN_004966c5 |
| Gate open |
lotr2_siege_open_gate // was thunk_FUN_0048f83c |
Data files
| File |
Role |
castles.dat |
Per-castle layout records |
gateway.pl8 / gateway.256 |
Drawbridge graphics |
flags*.pl8 |
Victory flag sprites |
Open questions