Annotate all data with DUSK_GAME_DATA (#2214)

The hope of auto-importing data via lld MinGW
+ pseudo_reloc is now dead thanks to ARM64,
so I just wrote a script to go annotate every
exported data symbol in the game instead.
This commit is contained in:
Luke Street
2026-07-14 13:49:21 -06:00
committed by GitHub
parent f5d30a886d
commit eed14acdc6
843 changed files with 4817 additions and 4821 deletions
+2 -2
View File
@@ -256,7 +256,7 @@ inline Z2Audience* Z2GetAudience() {
return JASGlobalInstance<Z2Audience>::getInstance();
}
extern s8 data_80451358;
extern s8 data_80451359;
DUSK_GAME_EXTERN s8 data_80451358;
DUSK_GAME_EXTERN s8 data_80451359;
#endif /* Z2AUDIENCE_H */
+1 -1
View File
@@ -34,7 +34,7 @@ public:
bool isResetting() { return mResettingFlag; }
static Z2AudioMgr* getInterface() { return mAudioMgrPtr; }
static Z2AudioMgr* mAudioMgrPtr;
static DUSK_GAME_DATA Z2AudioMgr* mAudioMgrPtr;
/* 0x0514 */ virtual bool startSound(JAISoundID soundID, JAISoundHandle* handle, const JGeometry::TVec3<f32>* posPtr);
/* 0x0518 */ bool mResettingFlag;
+2 -2
View File
@@ -42,8 +42,8 @@ f32 getParamByExp(f32 value, f32 inMin, f32 inMax, f32 exponent, f32 outMin, f32
f32 getRandom(f32 magnitude, f32 exponent, f32 bias);
f32 getRandom_0_1();
extern const f32 cEqualCSlope;
extern const f32 cEqualPSlope;
DUSK_GAME_EXTERN const f32 cEqualCSlope;
DUSK_GAME_EXTERN const f32 cEqualPSlope;
} // namespace Z2Calc
#endif /* Z2CALC_H */
+1 -1
View File
@@ -175,7 +175,7 @@ struct Z2EnvSeMgr : public JASGlobalInstance<Z2EnvSeMgr> {
STATIC_ASSERT(sizeof(Z2EnvSeMgr) == 0x30C);
extern Z2EnvSeMgr g_mEnvSeMgr;
DUSK_GAME_EXTERN Z2EnvSeMgr g_mEnvSeMgr;
inline Z2EnvSeMgr* Z2GetEnvSeMgr() {
return JASGlobalInstance<Z2EnvSeMgr>::getInstance();
+1 -1
View File
@@ -57,7 +57,7 @@ public:
void setUsingIronBall(bool isUsingIronBall) { mUsingIronBall = isUsingIronBall; }
void setMarkState(u8 state) { mMarkState = state; }
static Z2CreatureLink* mLinkPtr;
static DUSK_GAME_DATA Z2CreatureLink* mLinkPtr;
static Z2CreatureLink* getLink() { return mLinkPtr; }
friend class Z2LinkSoundStarter;
+52 -52
View File
@@ -4,72 +4,72 @@
#include <types.h>
struct Z2Param {
static f32 DISTANCE_MAX;
static f32 MAX_VOLUME_DISTANCE;
static f32 DOLBY_CENTER_VALUE;
static f32 DOLBY_FLONT_DISTANCE_MAX;
static f32 DOLBY_BEHIND_DISTANCE_MAX;
static f32 DISTANCE_FX_PARAM;
static f32 SONIC_SPEED;
static f32 VOL_BGM_DEFAULT;
static f32 VOL_SE_SYSTEM_DEFAULT;
static f32 VOL_SE_LINK_VOICE_DEFAULT;
static f32 VOL_SE_LINK_MOTION_DEFAULT;
static f32 VOL_SE_LINK_FOOTNOTE_DEFAULT;
static f32 VOL_SE_CHAR_VOICE_DEFAULT;
static f32 VOL_SE_CHAR_MOVE_DEFAULT;
static f32 VOL_SE_OBJECT_DEFAULT;
static f32 VOL_SE_ATMOSPHERE_DEFAULT;
static f32 VOL_BGM_TALKING;
static f32 VOL_SE_SYSTEM_TALKING;
static f32 VOL_SE_LINK_VOICE_TALKING;
static f32 VOL_SE_LINK_MOTION_TALKING;
static f32 VOL_SE_LINK_FOOTNOTE_TALKING;
static f32 VOL_SE_CHAR_VOICE_TALKING;
static f32 VOL_SE_CHAR_MOVE_TALKING;
static f32 VOL_SE_OBJECT_TALKING;
static f32 VOL_SE_ATMOSPHERE_TALKING;
static f32 VOL_BGM_PAUSING;
static f32 VOL_SE_SYSTEM_PAUSING;
static f32 VOL_SE_LINK_VOICE_PAUSING;
static f32 VOL_SE_LINK_MOTION_PAUSING;
static f32 VOL_SE_LINK_FOOTNOTE_PAUSING;
static f32 VOL_SE_CHAR_VOICE_PAUSING;
static f32 VOL_SE_CHAR_MOVE_PAUSING;
static f32 VOL_SE_OBJECT_PAUSING;
static f32 VOL_SE_ATMOSPHERE_PAUSING;
static f32 MIN_DISTANCE_VOLUME;
static f32 ENEMY_LASTHIT_MUTE_VOLUME;
static DUSK_GAME_DATA f32 DISTANCE_MAX;
static DUSK_GAME_DATA f32 MAX_VOLUME_DISTANCE;
static DUSK_GAME_DATA f32 DOLBY_CENTER_VALUE;
static DUSK_GAME_DATA f32 DOLBY_FLONT_DISTANCE_MAX;
static DUSK_GAME_DATA f32 DOLBY_BEHIND_DISTANCE_MAX;
static DUSK_GAME_DATA f32 DISTANCE_FX_PARAM;
static DUSK_GAME_DATA f32 SONIC_SPEED;
static DUSK_GAME_DATA f32 VOL_BGM_DEFAULT;
static DUSK_GAME_DATA f32 VOL_SE_SYSTEM_DEFAULT;
static DUSK_GAME_DATA f32 VOL_SE_LINK_VOICE_DEFAULT;
static DUSK_GAME_DATA f32 VOL_SE_LINK_MOTION_DEFAULT;
static DUSK_GAME_DATA f32 VOL_SE_LINK_FOOTNOTE_DEFAULT;
static DUSK_GAME_DATA f32 VOL_SE_CHAR_VOICE_DEFAULT;
static DUSK_GAME_DATA f32 VOL_SE_CHAR_MOVE_DEFAULT;
static DUSK_GAME_DATA f32 VOL_SE_OBJECT_DEFAULT;
static DUSK_GAME_DATA f32 VOL_SE_ATMOSPHERE_DEFAULT;
static DUSK_GAME_DATA f32 VOL_BGM_TALKING;
static DUSK_GAME_DATA f32 VOL_SE_SYSTEM_TALKING;
static DUSK_GAME_DATA f32 VOL_SE_LINK_VOICE_TALKING;
static DUSK_GAME_DATA f32 VOL_SE_LINK_MOTION_TALKING;
static DUSK_GAME_DATA f32 VOL_SE_LINK_FOOTNOTE_TALKING;
static DUSK_GAME_DATA f32 VOL_SE_CHAR_VOICE_TALKING;
static DUSK_GAME_DATA f32 VOL_SE_CHAR_MOVE_TALKING;
static DUSK_GAME_DATA f32 VOL_SE_OBJECT_TALKING;
static DUSK_GAME_DATA f32 VOL_SE_ATMOSPHERE_TALKING;
static DUSK_GAME_DATA f32 VOL_BGM_PAUSING;
static DUSK_GAME_DATA f32 VOL_SE_SYSTEM_PAUSING;
static DUSK_GAME_DATA f32 VOL_SE_LINK_VOICE_PAUSING;
static DUSK_GAME_DATA f32 VOL_SE_LINK_MOTION_PAUSING;
static DUSK_GAME_DATA f32 VOL_SE_LINK_FOOTNOTE_PAUSING;
static DUSK_GAME_DATA f32 VOL_SE_CHAR_VOICE_PAUSING;
static DUSK_GAME_DATA f32 VOL_SE_CHAR_MOVE_PAUSING;
static DUSK_GAME_DATA f32 VOL_SE_OBJECT_PAUSING;
static DUSK_GAME_DATA f32 VOL_SE_ATMOSPHERE_PAUSING;
static DUSK_GAME_DATA f32 MIN_DISTANCE_VOLUME;
static DUSK_GAME_DATA f32 ENEMY_LASTHIT_MUTE_VOLUME;
// made up names based on HIO labels
static u8 SCENE_CHANGE_BGM_FADEOUT_TIME;
static u8 BGM_CROSS_FADEIN_TIME;
static u8 BGM_CROSS_FADEOUT_TIME;
static u8 BATTLE_BGM_WAIT_TIME;
static DUSK_GAME_DATA u8 SCENE_CHANGE_BGM_FADEOUT_TIME;
static DUSK_GAME_DATA u8 BGM_CROSS_FADEIN_TIME;
static DUSK_GAME_DATA u8 BGM_CROSS_FADEOUT_TIME;
static DUSK_GAME_DATA u8 BATTLE_BGM_WAIT_TIME;
static f32 ENEMY_NEARBY_DIST;
static f32 BATTLE_FADEIN_DIST;
static f32 BATTLE_FADEOUT_DIST;
static u8 FOUND_TRACK_FI_TIME;
static u8 FOUND_TRACK_FO_TIME;
static u8 CLOSE_BATTLE_TRACK_FI_TIME;
static u8 CLOSE_BATTLE_TRACK_FO_TIME;
static DUSK_GAME_DATA u8 FOUND_TRACK_FI_TIME;
static DUSK_GAME_DATA u8 FOUND_TRACK_FO_TIME;
static DUSK_GAME_DATA u8 CLOSE_BATTLE_TRACK_FI_TIME;
static DUSK_GAME_DATA u8 CLOSE_BATTLE_TRACK_FO_TIME;
static u8 ENDING_BLOW_VOL_DOWN_TIME;
static u8 ENDING_BLOW_VOL_LOWER_TIME;
static u8 ENDING_BLOW_VOL_LOWER_RECOVER_TIME;
static u8 ENDING_BLOW_MIN_FINISH_TIME;
static DUSK_GAME_DATA u8 ENDING_BLOW_VOL_DOWN_TIME;
static DUSK_GAME_DATA u8 ENDING_BLOW_VOL_LOWER_TIME;
static DUSK_GAME_DATA u8 ENDING_BLOW_VOL_LOWER_RECOVER_TIME;
static DUSK_GAME_DATA u8 ENDING_BLOW_MIN_FINISH_TIME;
static u8 DARK_SE_FILTER_ON;
static u8 DARK_SE_LOW_PASS_FILTER_SETTING;
static u8 SYSTEM_SE_USE_DARK_SE_SETTING;
static DUSK_GAME_DATA u8 DARK_SE_FILTER_ON;
static DUSK_GAME_DATA u8 DARK_SE_LOW_PASS_FILTER_SETTING;
static DUSK_GAME_DATA u8 SYSTEM_SE_USE_DARK_SE_SETTING;
static f32 AUDIBLE_DELTA_RANGE_VOLUME;
static f32 AUDIBLE_DELTA_RANGE_PAN;
static f32 AUDIBLE_DELTA_RANGE_DOLBY;
};
extern u8 data_8045086C;
DUSK_GAME_EXTERN u8 data_8045086C;
#endif /* Z2PARAM_H */