4
edits
THplusplus (talk | contribs) (Clarified the exact meaning of the offsets in the lookup tables.) |
THplusplus (talk | contribs) (More in depth exploration of the Extra Information Array structure.) |
||
Line 157: | Line 157: | ||
Each entry contains meta data for one tile in the terrain scene. There are multiple levels of detail (lod) for the terrain. | Each entry contains meta data for one tile in the terrain scene. There are multiple levels of detail (lod) for the terrain. | ||
Entry size ranges from <code>0x30</code> to <code>0x58</code> depending on the size of <code>extra_info_array</code> | |||
{| class="wikitable" | {| class="wikitable" | ||
!Offset (h) | !Offset (h) | ||
Line 235: | Line 235: | ||
Every area includes a [[HGHT|.hght]] and [[MATE|.mate]] file. The <code>extra_info_array</code> indicates if there is an additional [[Water.extm|.water.extm]] and / or [[Grass.extm|.grass.extm]] file | Every area includes a [[HGHT|.hght]] and [[MATE|.mate]] file. The <code>extra_info_array</code> indicates if there is an additional [[Water.extm|.water.extm]] and / or [[Grass.extm|.grass.extm]] file | ||
==== Header ==== | |||
{| class="wikitable" | {| class="wikitable" | ||
!Offset (h) | !Offset (h) | ||
Line 241: | Line 243: | ||
!Description | !Description | ||
|- | |- | ||
|<code> | |<code>0x00</code> | ||
|4 | |4 | ||
|Unsigned Int | |Unsigned Int | ||
|extra_info_array length. Number of elements in array. | |extra_info_array length. Number of values (not elements) in array. | ||
|- | |- | ||
|<code> | |<code>(0x04)</code> | ||
|4 | |4 | ||
|Unsigned Int | |Unsigned Int | ||
|Unknown. | |Unknown. Always 20, but only present when extra_info_array length is 8. | ||
|} | |||
==== Extra Information Array Value Table ==== | |||
After the Header, there is either 1 (extra_info_array length 4) or 2 (extra_info_array length 8) elements of this structure. | |||
{| class="wikitable" | |||
!Offset (h) | |||
!Size | |||
!Data Type | |||
!Description | |||
|- | |- | ||
| | |0x00 | ||
|4 | |4 | ||
|Unsigned Int | |Unsigned Int | ||
|Unknown. | |Unknown. Always 3. | ||
|- | |- | ||
| | |0x04 | ||
|4 | |4 | ||
|Unsigned Int | |Unsigned Int | ||
|Unknown. | |Unknown. 0 or 1. | ||
|- | |- | ||
| | |0x08 | ||
|4 | |4 | ||
|Unsigned Int | |Unsigned Int | ||
|Unknown. | |Unknown. Always 1. | ||
|- | |- | ||
| | |0x0c | ||
|4 | |4 | ||
|Unsigned Int | |Unsigned Int | ||
|Unknown. Always 0. | |Unknown. Always 0. | ||
|} | |} | ||
[ | [3, 0, 1, 0, 3, 1, 1, 0] = grass, water | ||
[ | [3, 1, 1, 0, 3, 0, 1, 0] = water, grass | ||
[ 3, 1, 1, 0] = water | [3, 1, 1, 0] = water | ||
[ 3, 0, 1, 0] = grass | [3, 0, 1, 0] = grass | ||
It seems that water is <code>[3, 1, 1]</code> and grass is <code>[3, 0, 1]</code> | It seems that water is <code>[3, 1, 1]</code> and grass is <code>[3, 0, 1]</code> | ||
== <code>stera</code> File Positions == | == <code>stera</code> File Positions == |
edits