SOUNDDEFINITION
struct · sound · 152 bytes
- Meaning
- Holds a SoundEntries row's sound definition: ten file slots, volume, flags, distances, weights and picks
- Confidence
- verified, proof one
- Finding
- sound/entries#sound-definitions
Finding: Sound definitions in sound: sound entries and plays
A definition is a 0x98-byte record from a block pool: ten file slots of 12 bytes (+0x00 name,
+0x04 remaining weight, +0x08 weight), the volume (+0x78), the flags (+0x7c), the minimum
distance (+0x80), the distance cutoff (+0x84), the remaining total (+0x88), the EAX definition
(+0x8c), the last file picked (+0x90) and the file count (+0x94). The loader makes one per
SoundEntries row from columns 24 to 28 and the file columns, and keeps it in an array indexed by
the row's id. A row with no files gets no definition, so its id plays nothing. 0x45cda0(id)
returns the definition or null for an id past the array.
The derivation is in the doc.
Fields 9
| offset | size | type | name | meaning | confidence | finding |
|---|---|---|---|---|---|---|
0x0000 | 120 | uint32_t[30] | m_files | Holds ten file slots of name, remaining weight and weight | verified, proof one | sound/entries#sound-definitions |
0x0078 | 4 | float | m_volume | Holds the volume, 1.0 by default | verified, proof one | sound/entries#sound-definitions |
0x007c | 4 | uint32_t | m_flags | Holds the SoundEntries row's flags | verified, proof one | sound/entries#sound-definitions |
0x0080 | 4 | float | m_minDistance | Holds the minimum distance, 27.777779 by default | verified, proof one | sound/entries#sound-definitions |
0x0084 | 4 | float | m_cutoff | Holds the distance cutoff, 83.333336 by default | verified, proof one | sound/entries#sound-definitions |
0x0088 | 4 | uint32_t | m_remainingWeight | Holds the sum of the remaining weights | verified, proof one | sound/entries#sound-definitions |
0x008c | 4 | int32_t | m_eaxDefinition | Holds the channel reverb record index, -1 by default | verified, proof one | sound/entries#sound-definitions |
0x0090 | 4 | int32_t | m_lastFile | Holds the last file picked, -1 by default | verified, proof one | sound/entries#sound-definitions |
0x0094 | 4 | uint32_t | m_fileCount | Holds the number of file slots filled | verified, proof one | sound/entries#sound-definitions |