AttribSys Vault: Difference between revisions

Add array and refspec.
m (Even more rewording)
(Add array and refspec.)
Line 34:
 
= Vault =
The vault is a set of structures with [[#Attrib::Vault::ChunkBlock | ChunkBlocks]] which are read sequentially. In Burnout Paradise, these are:
* '''Vers''': The version
* '''DepN''': The dependency node
Line 58:
! Offset !! Length !! Type !! Name !! Description !! Comments
|-
| 0x0 || 0x8 || [[#Attrib::Vault::ChunkBlock | ChunkBlock]] || super_ChunkBlock || ||
|-
| 0x8 || 0x8 || uint64_t || mVersion || Version hash ||
Line 69:
! Offset !! Length !! Type !! Name !! Description !! Comments
|-
| 0x0 || 0x8 || [[#Attrib::Vault::ChunkBlock | ChunkBlock]] || super_ChunkBlock || ||
|-
| 0x8 || 0x8 || [[Attribute hash | HashInt]] || mCount || Number of dependencies ||
|}
 
This structure is immediately followed by the [[Attribute hash | hashes]] of the dependency strings, then the offsets of the strings relative to the start of the first string, then the strings themselves.
 
== Start node ==
Line 81:
! Offset !! Length !! Type !! Name !! Description !! Comments
|-
| 0x0 || 0x8 || [[#Attrib::Vault::ChunkBlock | ChunkBlock]] || super_ChunkBlock || ||
|-
| ??? || || || || ||
Line 93:
! Offset !! Length !! Type !! Name !! Description !! Comments
|-
| 0x0 || 0x8 || [[#Attrib::Vault::ChunkBlock | ChunkBlock]] || super_ChunkBlock || ||
|}
 
This is followed by several [[#Attrib::CollectionLoadData | collections]].
 
This node is not read directly. Pointers in other nodes read the data that lies in this node.
Line 105:
! Offset !! Length !! Type !! Name !! Description !! Comments
|-
| 0x0 || 0x8 || [[Attribute hash | Key]] || mKey || ||
|-
| 0x8 || 0x8 || [[Attribute hash | Key]] || mClass || ||
|-
| 0x10 || 0x8 || [[Attribute hash | Key]] || mParent || ||
|-
| 0x18 || 0x4 || uint32_t || mTableReserve || Amount allocated for entries ||
Line 126:
|}
 
This is always followed by the types, then the entries (which are [[#Attrib::Node | nodes]]).
 
=== Attrib::Node ===
Line 133:
! Offset !! Length !! Type !! Name !! Description !! Comments
|-
| 0x0 || 0x8 || [[Attribute hash | Key]] || mKey || ||
|-
| 0x8 || 0x4 || [[#Attrib::Node::anon_union_0 | anon_union_0]] || field_1 || || Just a pointer
|-
| 0xC || 0x2 || uint16_t || mTypeIndex || ||
Line 164:
! Offset !! Length !! Type !! Name !! Description !! Comments
|-
| 0x0 || 0x8 || [[#Attrib::Vault::ChunkBlock | ChunkBlock]] || super_ChunkBlock || ||
|-
| 0x8 || 0x8 || [[Attribute hash | HashInt]] || mCount || Number of dependencies ||
|}
 
Followed by [[#Attrib::Vault::ExportEntry | export entries]] of an amount defined by mCount.
 
=== Attrib::Vault::ExportEntry ===
Line 176:
! Offset !! Length !! Type !! Name !! Description !! Comments
|-
| 0x0 || 0x8 || [[Attribute hash | ExportID]] || mID || ||
|-
| 0x8 || 0x8 || [[Attribute hash | TypeID]] || mType || ||
|-
| 0x10 || 0x4 || uint32_t || mDataBytes || Size of the data node entry ||
Line 191:
! Offset !! Length !! Type !! Name !! Description !! Comments
|-
| 0x0 || 0x8 || [[#Attrib::Vault::ChunkBlock | ChunkBlock]] || super_ChunkBlock || ||
|}
 
Followed by several [[#Attrib::PtrRef | PtrRefs]].
 
=== Attrib::PtrRef ===
Line 207:
| 0x6 || 0x2 || uint16_t || mIndex || Which dependency the value is relative to || 0 is normally the vault<br />1 is normally the bin
|-
| 0x8 || 0x8 || [[#Attrib::PtrRef::anon_union_0 | anon_union_0]] || field_3 || Value ||
|}
 
Line 215:
! Length !! Type !! Name !! Description !! Comments
|-
| 0x8 || [[Attribute hash | ExportID]] || mExportID || ||
|-
| 0x8 || [[Attribute hash | HashInt]] || mOffset || ||
|}
 
Line 243:
The rest of the data in the bin is not associated to a chunk and is instead pointed to by the vault.
 
=== String exports ===
{| class="wikitable"
|-
! Offset !! Length !! Type !! Name !! Description !! Comments
|-
| 0x0 || 0x8 || [[#Attrib::Vault::ChunkBlock | ChunkBlock]] || super_ChunkBlock || ||
|}
 
Line 257 ⟶ 256:
* [[Engines (Burnout Paradise)/Attributes]]
* [[Vehicles (Burnout Paradise)/Attributes]]
 
== Common structures ==
=== Attrib::Array ===
{| class="wikitable"
! Offset !! Length !! Type !! Name !! Description !! Comments
|-
| 0x0 || 0x2 || uint16_t || mAlloc || Number of entries allocated ||
|-
| 0x2 || 0x2 || uint16_t || mCount || Number of entries used ||
|-
| 0x4 || 0x2 || uint16_t || mSize || The length of each entry ||
|-
| 0x6 || 0x2 || uint16_t || mEncodedTypePad || Padding ||
|}
 
=== Attrib::RefSpec ===
The [[Attribute hash|hashed]] collection and class.
 
{| class="wikitable"
! Offset !! Length !! Type !! Name !! Description !! Comments
|-
| 0x0 || 0x8 || [[Attribute hash|Key]] || mClassKey || ||
|-
| 0x8 || 0x8 || [[Attribute hash|Key]] || mCollectionKey || ||
|-
| 0x10 || 0x4 || Collection* || mCollectionPtr || || Always nullptr in resource
|-
| 0x14 || 0x4 || || || Padding ||
|}