Havok: Difference between revisions

12 bytes removed ,  5 years ago
m
→‎Header: Updated headings to be more consistent
imported>Zephenryus
m (→‎Usage: Italicized Breath of the Wild)
imported>Zephenryus
m (→‎Header: Updated headings to be more consistent)
Line 95: Line 95:
the data section (<code>__data__</code> internally) contains binary data to be serialized into Havok data structures for use by the Havok engine.
the data section (<code>__data__</code> internally) contains binary data to be serialized into Havok data structures for use by the Havok engine.


=== Header ===
== Header ==
The header seems to have a 16-byte alignment and can be 64-bytes (short header) or 80-bytes (long header) in length, depending on if '''Unknown 13''' equals 0 (short header) or 16 (long header).
The header seems to have a 16-byte alignment and can be 64-bytes (short header) or 80-bytes (long header) in length, depending on if '''Unknown 13''' equals 0 (short header) or 16 (long header).
{| class="wikitable"
{| class="wikitable"
Line 186: Line 186:
|}
|}


==== Optional Header Bytes ====
=== Optional Header Bytes ===
There are optional header bytes for a long header. If Unknown 13 equals 16, an additional 16 bytes are added to the header for a total of 80 bytes.
There are optional header bytes for a long header. If Unknown 13 equals 16, an additional 16 bytes are added to the header for a total of 80 bytes.
{| class="wikitable"
{| class="wikitable"
Line 221: Line 221:
|}
|}


=== Section Headers ===
== Section Headers ==
[[File:Havok-class-header-delimits.png|thumb|<code>FF</code> bytes indicate section header boundaries]]
[[File:Havok-class-header-delimits.png|thumb|<code>FF</code> bytes indicate section header boundaries]]
Each section has a 64-byte header which includes the section name, absolute offset to the section start and six relative offsets to segments within the section. All three section headers follow the file header and are delimited by 16 delimiter bytes (<code>0xFF</code>).
Each section has a 64-byte header which includes the section name, absolute offset to the section start and six relative offsets to segments within the section. All three section headers follow the file header and are delimited by 16 delimiter bytes (<code>0xFF</code>).
Line 272: Line 272:
|}
|}


==== Section Name ====
=== Section Name ===
There are only three section names: <code>__classnames__</code>, <code>__types__</code> and <code>__data__</code>. The section name is a null-terminated string with a delimiter byte (<code>0xFF</code>) in byte 20.
There are only three section names: <code>__classnames__</code>, <code>__types__</code> and <code>__data__</code>. The section name is a null-terminated string with a delimiter byte (<code>0xFF</code>) in byte 20.


==== Absolute Offset ====
=== Absolute Offset ===
The absolute offset to the section.
The absolute offset to the section.


==== Relative Offsets ====
=== Relative Offsets ===
The relative offsets point to different large structures within the section. There are usually a few unique offsets and then multiple duplicated offsets. It is unknown if only unique offsets are significant at this time.
The relative offsets point to different large structures within the section. There are usually a few unique offsets and then multiple duplicated offsets. It is unknown if only unique offsets are significant at this time.


Anonymous user