Skip to content

Commit

Permalink
Merge pull request #821 from FedericoMilesi/SOUND_structs
Browse files Browse the repository at this point in the history
[SOUND]: Update structs
  • Loading branch information
FedericoMilesi authored Feb 10, 2024
2 parents 691ebc9 + fb71d2f commit e03b949
Showing 1 changed file with 47 additions and 43 deletions.
90 changes: 47 additions & 43 deletions KAIN2/Game/SOUND.H
Original file line number Diff line number Diff line change
Expand Up @@ -12,59 +12,62 @@ struct _AnimSoundData_Type
short minVolDistance; // size=0, offset=6
};

struct ObjectOneShotSound {
unsigned char type; // size=0, offset=0
unsigned char numSfxIDs; // size=0, offset=1
unsigned char soundInst; // size=0, offset=2
unsigned char flags; // size=0, offset=3
unsigned short minVolDistance; // size=0, offset=4
short pitch; // size=0, offset=6
unsigned short pitchVariation; // size=0, offset=8
unsigned char maxVolume; // size=0, offset=10
unsigned char maxVolVariation; // size=0, offset=11
unsigned char initialDelay; // size=0, offset=12
unsigned char initialDelayVariation; // size=0, offset=13
struct ObjectOneShotSound
{
unsigned char type; // size=0, offset=0
unsigned char numSfxIDs; // size=0, offset=1
unsigned char soundInst; // size=0, offset=2
unsigned char flags; // size=0, offset=3
unsigned short minVolDistance; // size=0, offset=4
short pitch; // size=0, offset=6
unsigned short pitchVariation; // size=0, offset=8
unsigned char maxVolume; // size=0, offset=10
unsigned char maxVolVariation; // size=0, offset=11
unsigned char initialDelay; // size=0, offset=12
unsigned char initialDelayVariation; // size=0, offset=13
};

struct ObjectEventSound {
unsigned char type; // size=0, offset=0
unsigned char numSfxIDs; // size=0, offset=1
unsigned char soundInst; // size=0, offset=2
unsigned char flags; // size=0, offset=3
unsigned short minVolDistance; // size=0, offset=4
short pitch; // size=0, offset=6
unsigned short pitchVariation; // size=0, offset=8
unsigned char maxVolume; // size=0, offset=10
unsigned char maxVolVariation; // size=0, offset=11
unsigned char initialDelay; // size=0, offset=12
unsigned char initialDelayVariation; // size=0, offset=13
struct ObjectEventSound
{
unsigned char type; // size=0, offset=0
unsigned char numSfxIDs; // size=0, offset=1
unsigned char soundInst; // size=0, offset=2
unsigned char flags; // size=0, offset=3
unsigned short minVolDistance; // size=0, offset=4
short pitch; // size=0, offset=6
unsigned short pitchVariation; // size=0, offset=8
unsigned char maxVolume; // size=0, offset=10
unsigned char maxVolVariation; // size=0, offset=11
unsigned char initialDelay; // size=0, offset=12
unsigned char initialDelayVariation; // size=0, offset=13
};

struct ObjectPeriodicSound {
unsigned char type; // size=0, offset=0
unsigned char numSfxIDs; // size=0, offset=1
unsigned char soundInst; // size=0, offset=2
unsigned char flags; // size=0, offset=3
unsigned short minVolDistance; // size=0, offset=4
short pitch; // size=0, offset=6
unsigned short pitchVariation; // size=0, offset=8
unsigned char maxVolume; // size=0, offset=10
unsigned char maxVolVariation; // size=0, offset=11
unsigned char initialDelay; // size=0, offset=12
unsigned char initialDelayVariation; // size=0, offset=13
unsigned char onTime; // size=0, offset=14
unsigned char onTimeVariation; // size=0, offset=15
unsigned char offTime; // size=0, offset=16
unsigned char offTimeVariation; // size=0, offset=17
struct ObjectPeriodicSound
{
unsigned char type; // size=0, offset=0
unsigned char numSfxIDs; // size=0, offset=1
unsigned char soundInst; // size=0, offset=2
unsigned char flags; // size=0, offset=3
unsigned short minVolDistance; // size=0, offset=4
short pitch; // size=0, offset=6
unsigned short pitchVariation; // size=0, offset=8
unsigned char maxVolume; // size=0, offset=10
unsigned char maxVolVariation; // size=0, offset=11
unsigned char initialDelay; // size=0, offset=12
unsigned char initialDelayVariation; // size=0, offset=13
unsigned char onTime; // size=0, offset=14
unsigned char onTimeVariation; // size=0, offset=15
unsigned char offTime; // size=0, offset=16
unsigned char offTimeVariation; // size=0, offset=17
};

struct MusicLoadCmd // hashcode: 0x575883B8 (dec: 1465418680)
struct MusicLoadCmd
{
int type; // size=0, offset=0
int data; // size=0, offset=4
};

struct MusicLoadInfo // hashcode: 0xC8F67C40 (dec: -923370432)
struct MusicLoadInfo
{
int state; // size=0, offset=0
int nextState; // size=0, offset=4
Expand All @@ -79,7 +82,8 @@ struct MusicLoadInfo // hashcode: 0xC8F67C40 (dec: -923370432)
int numCmdsInQueue; // size=0, offset=72
};

struct SoundEffectChannel {
struct SoundEffectChannel
{
unsigned char inUse; // size=0, offset=0
unsigned char unused; // size=0, offset=1
unsigned short unused1; // size=0, offset=2
Expand Down

0 comments on commit e03b949

Please sign in to comment.