diff options
| author | robojumper <robojumper@gmail.com> | 2025-06-07 14:06:23 +0200 |
|---|---|---|
| committer | robojumper <robojumper@gmail.com> | 2025-06-07 14:06:23 +0200 |
| commit | b53bafeeb4471d7d1f62bbfc1936bdf8d52d6c1a (patch) | |
| tree | eb55774a902195c16f355d846a712c6b06e51d70 /include/toBeSorted | |
| parent | ac94c5f0efa19481ef030997f5f771347f79a2de (diff) | |
actor_info OK
Diffstat (limited to 'include/toBeSorted')
| -rw-r--r-- | include/toBeSorted/actor_info.h | 44 |
1 files changed, 44 insertions, 0 deletions
diff --git a/include/toBeSorted/actor_info.h b/include/toBeSorted/actor_info.h new file mode 100644 index 00000000..e48fcd2c --- /dev/null +++ b/include/toBeSorted/actor_info.h @@ -0,0 +1,44 @@ +#ifndef D_ACTOR_INFO_H +#define D_ACTOR_INFO_H + +#include "common.h" + +// TODO: Expand when we figure out what the other entries have in common +enum SoundSourceCategory_e { + SND_SOURCE_PLAYER = 0, + SND_SOURCE_ARROW = 7, + SND_SOURCE_BULLET = 29, + SND_SOURCE_OBJECT = 32, + SND_SOURCE_ITEM = 35, + SND_SOURCE_TERRY_SHOP = 36, + SND_SOURCE_TIME_STONE = 37, + SND_SOURCE_CLEF = 38, + SND_SOURCE_SHUTTER = 39, + SND_SOURCE_KENSEI = 44, + SND_SOURCE_PLAYER_BIRD = 45, + SND_SOURCE_INSECT = 49, + SND_SOURCE_NPC_NRM = 51, + SND_SOURCE_SW_HARP = 56, +}; + +/** + * profileId and profileId2 are always the same. + */ +struct ActorInfo { + /* 0x00 */ const char *name; + /* 0x04 */ u16 profileId; + /* 0x06 */ u16 profileId2; + /* 0x08 */ u16 fiTextEntryId; // also used for kill counters + /* 0x0A */ s8 soundSourceCategory; + /* 0x0B */ u8 subtype; +}; + +const ActorInfo *getActorInfoByName(const char *name); +u16 getProfileIdForName(const char *name); +u16 getProfileId2ForName(const char *name); +const char *getNameForProfileId(u32 profileId); +const char *getActorName(const ActorInfo *actorInfo); +const ActorInfo *getActorInfoByProfileAndSubtype(u32 profileId, u32 subtype); +s32 getSoundSourceCategoryForName(const char *name); + +#endif |
