AINB: Difference between revisions

Jump to navigation Jump to search
3,124 bytes added ,  11 months ago
added info on all the short sections
m (fixed formatting)
(added info on all the short sections)
Line 993: Line 993:


==== Resident Update Array ====
==== Resident Update Array ====
This section is an array of entries for resident nodes that are updated mid-node update sequence. The first four bytes specify the number of entries. Each entry is four bytes.
{| class="wikitable"
|+
!Bits
!Description
|-
|8
|Is Valid Update
|-
|23
|
|-
|1
|Update Post Current Command Calculation
|}
If the first byte of the flags is set to false, then the entry contains another four bytes with a string offset (purpose unknown). By default, the node is scheduled to update pre-next command calculation, however, this can change depending on the flags set. Additionally, Fork and Join nodes behave differently. Fork nodes will append the node to the run array while Join nodes will update the node post-current command calculation.


==== 0x50 Section ====
==== 0x50 Section ====
Line 998: Line 1,014:


==== Precondition Nodes Array ====
==== Precondition Nodes Array ====
This section is an array of entries of precondition nodes present in the file.
{| class="wikitable"
|+Precondition Node Entry
!Offset
!Size
!Type
!Description
|-
|0x00
|0x02
|u16
|Precondition Node Index (local to number of precondition nodes)
|-
|0x02
|0x02
|u16
|
|}


==== Expression Binary Section ====
==== Expression Binary Section ====
Line 1,003: Line 1,037:


==== Embedded AINB Files ====
==== Embedded AINB Files ====
This section contains an array of all external AINB files linked to the current AINB file. The first four bytes specify the entry count.
{| class="wikitable"
|+Embedded AINB File Entry
!Offset
!Size
!Type
!Description
|-
|0x00
|0x04
|u32
|File Path Offset
|-
|0x04
|0x04
|u32
|File Category Offset
|-
|0x08
|0x04
|u32
|AINB File Count
|}


==== Entry Strings ====
==== Entry Strings ====
The purpose of this section is unknown. The first four bytes specify the entry count.
{| class="wikitable"
|+Entry String Entry
!Offset
!Size
!Type
!Description
|-
|0x00
|0x04
|u32
|Node Index
|-
|0x04
|0x04
|u32
|String 1 Offset (always メインステート ("Main State"))
|-
|0x08
|0x04
|u32
|State Name Offset
|}


==== File Hashes ====
==== File Hashes ====
Line 1,010: Line 1,090:


==== Child Replacement Table ====
==== Child Replacement Table ====
This section is used to remove or replace specific nodes or attachments at runtime. This is used to toggle of debug nodes/attachments for release builds. The section begins with an eight-byte section header.
{| class="wikitable"
|+Child Replacement Section Header
!Offset
!Size
!Type
!Description
|-
|0x00
|0x01
|u8
|Initialization Guard (Is Initialized)
|-
|0x01
|0x01
|u8
|
|-
|0x02
|0x02
|u16
|Replacement Count
|-
|0x04
|0x02
|s16
|Override Node Count
|-
|0x06
|0x02
|s16
|Override Attachment Parameter Count
|}
{| class="wikitable"
|+Child Replacement Table Entry
!Offset
!Size
!Type
!Description
|-
|0x00
|0x01
|u8
|Replacement Type Enum (0 = remove child node, 1 = replace child node, 2 = remove attachment)
|-
|0x01
|0x01
|u8
|
|-
|0x02
|0x02
|u16
|Node Index
|-
|0x04
|0x02
|u16
|Child Node Index/Attachment Index
|-
|0x06
|0x02
|u16
|New Node Index (for child node replacements)
|}


==== 0x6C Section ====
==== 0x6C Section ====
Line 1,015: Line 1,160:


==== Enum Resolve Array ====
==== Enum Resolve Array ====
This section is used to resolve enum values at runtime. This section is unused in ''Tears of the Kingdom'' as all enum values are statically present in the file. However, in ''Splatoon 3'', this section is used extensively as all enum values are stored in the main executable. The first four bytes of this section specifies the number of entries in the section.
{| class="wikitable"
|+Enum Resolve Array Entry
!Offset
!Size
!Type
!Description
|-
|0x00
|0x04
|u32
|Enum Value Offset
|-
|0x04
|0x04
|u32
|Enum Class Name Offset
|-
|0x08
|0x04
|u32
|Enum Value Name Offset
|}


==== String Pool ====
==== String Pool ====
The string pool is an array of null-terminated strings encoded with UTF-8. All string offsets in the file are relative to the first byte of this section.
The string pool is an array of null-terminated strings encoded with UTF-8. All string offsets in the file are relative to the first byte of this section.
[[Category:File formats]]
[[Category:File formats]]
28

edits

Navigation menu