use full signature for event annotations

This commit is contained in:
LittleCube 2024-09-30 19:30:36 -04:00
parent 296d45614e
commit 9f8de91564
3 changed files with 12 additions and 12 deletions

View File

@ -113,7 +113,7 @@ RECOMP_PATCH void func_80147314(SramContext* sramCtx, s32 fileNum) {
gSaveContext.save.isOwlSave = false; gSaveContext.save.isOwlSave = false;
// @recomp Prevent owl save/autosave deletion if autosaving is enabled, and... // @recomp Prevent owl save/autosave deletion if autosaving is enabled, and...
// @recomp_use_export_var Prevent owl save deletion if mods disable it. // @recomp_use_export_var loading_deletes_owl_save: Prevent owl save deletion if mods disable it.
if (!recomp_autosave_enabled() && loading_deletes_owl_save) { if (!recomp_autosave_enabled() && loading_deletes_owl_save) {
gSaveContext.save.saveInfo.playerData.newf[0] = '\0'; gSaveContext.save.saveInfo.playerData.newf[0] = '\0';
gSaveContext.save.saveInfo.playerData.newf[1] = '\0'; gSaveContext.save.saveInfo.playerData.newf[1] = '\0';
@ -542,7 +542,7 @@ RECOMP_PATCH void Sram_OpenSave(FileSelectState* fileSelect, SramContext* sramCt
s32 pad1; s32 pad1;
s32 fileNum; s32 fileNum;
// @recomp_event recomp_on_load_save: A save-file was just chosen. // @recomp_event recomp_on_load_save(FileSelectState* fileSelect, SramContext* sramCtx): A save-file was just chosen.
recomp_on_load_save(fileSelect, sramCtx); recomp_on_load_save(fileSelect, sramCtx);
if (gSaveContext.flashSaveAvailable) { if (gSaveContext.flashSaveAvailable) {
@ -669,7 +669,7 @@ RECOMP_PATCH void Sram_OpenSave(FileSelectState* fileSelect, SramContext* sramCt
// @recomp Initialize the autosave state tracking. // @recomp Initialize the autosave state tracking.
autosave_init(); autosave_init();
// @recomp_event recomp_after_load_save: The save has finished loading. // @recomp_event recomp_after_load_save(FileSelectState* fileSelect, SramContext* sramCtx): The save has finished loading.
recomp_after_load_save(fileSelect, sramCtx); recomp_after_load_save(fileSelect, sramCtx);
} }
@ -691,7 +691,7 @@ RECOMP_PATCH void Sram_ResetSaveFromMoonCrash(SramContext* sramCtx) {
s32 i; s32 i;
s32 cutsceneIndex = gSaveContext.save.cutsceneIndex; s32 cutsceneIndex = gSaveContext.save.cutsceneIndex;
// @recomp_event recomp_on_moon_crash: A moon crash has just been triggered. // @recomp_event recomp_on_moon_crash(SramContext* sramCtx): A moon crash has just been triggered.
recomp_on_moon_crash(sramCtx); recomp_on_moon_crash(sramCtx);
if (moon_crash_resets_save) if (moon_crash_resets_save)
@ -742,7 +742,7 @@ RECOMP_PATCH void Sram_ResetSaveFromMoonCrash(SramContext* sramCtx) {
// @recomp Use the slow autosave timer to give the player extra time to respond to the moon crashing to decide if they want to reload their autosave. // @recomp Use the slow autosave timer to give the player extra time to respond to the moon crashing to decide if they want to reload their autosave.
recomp_reset_autosave_timer_slow(); recomp_reset_autosave_timer_slow();
// @recomp_event recomp_after_moon_crash: The effects of moon crash have been written. // @recomp_event recomp_after_moon_crash(SramContext* sramCtx): The effects of moon crash have been written.
recomp_after_moon_crash(sramCtx); recomp_after_moon_crash(sramCtx);
} }
@ -764,7 +764,7 @@ RECOMP_PATCH void ObjWarpstone_Update(Actor* thisx, PlayState* play) {
ObjWarpstone* this = (ObjWarpstone*)thisx; ObjWarpstone* this = (ObjWarpstone*)thisx;
s32 pad; s32 pad;
// @recomp_event recomp_on_owl_update: Allow mods to handle owl update frames. // @recomp_event recomp_on_owl_update(ObjWarpstone* this, PlayState* play): Allow mods to handle owl update frames.
recomp_on_owl_update(this, play); recomp_on_owl_update(this, play);
if (this->isTalking) { if (this->isTalking) {
@ -772,7 +772,7 @@ RECOMP_PATCH void ObjWarpstone_Update(Actor* thisx, PlayState* play) {
this->isTalking = false; this->isTalking = false;
} else if ((Message_GetState(&play->msgCtx) == TEXT_STATE_CHOICE) && Message_ShouldAdvance(play)) { } else if ((Message_GetState(&play->msgCtx) == TEXT_STATE_CHOICE) && Message_ShouldAdvance(play)) {
if (play->msgCtx.choiceIndex != 0) { if (play->msgCtx.choiceIndex != 0) {
// @recomp_event recomp_on_owl_save: The player chose to save from an owl statue. // @recomp_event recomp_on_owl_save(ObjWarpstone* this, PlayState* play): The player chose to save from an owl statue.
recomp_on_owl_save(this, play); recomp_on_owl_save(this, play);
Audio_PlaySfx_MessageDecide(); Audio_PlaySfx_MessageDecide();
@ -788,7 +788,7 @@ RECOMP_PATCH void ObjWarpstone_Update(Actor* thisx, PlayState* play) {
play->msgCtx.unk120D4 = 0; play->msgCtx.unk120D4 = 0;
gSaveContext.save.owlWarpId = OBJ_WARPSTONE_GET_OWL_WARP_ID(&this->dyna.actor); gSaveContext.save.owlWarpId = OBJ_WARPSTONE_GET_OWL_WARP_ID(&this->dyna.actor);
// @recomp_event recomp_after_owl_save: Owl save is finished. // @recomp_event recomp_after_owl_save(ObjWarpstone* this, PlayState* play): Owl save is finished.
recomp_after_owl_save(this, play); recomp_after_owl_save(this, play);
} else { } else {
Message_CloseTextbox(play); Message_CloseTextbox(play);

View File

@ -17,7 +17,7 @@ RECOMP_PATCH void Play_Main(GameState* thisx) {
static Input* prevInput = NULL; static Input* prevInput = NULL;
PlayState* this = (PlayState*)thisx; PlayState* this = (PlayState*)thisx;
// @recomp_event Allow mods to execute code every frame. // @recomp_event recomp_on_play_main(PlayState* play): Allow mods to execute code every frame.
recomp_on_play_main(this); recomp_on_play_main(this);
// @recomp // @recomp
@ -40,12 +40,12 @@ RECOMP_PATCH void Play_Main(GameState* thisx) {
} }
camera_pre_play_update(this); camera_pre_play_update(this);
// @recomp_event Play_Update is about to be called. // @recomp_event recomp_on_play_update(PlayState* play): Play_Update is about to be called.
recomp_on_play_update(this); recomp_on_play_update(this);
Play_Update(this); Play_Update(this);
// @recomp_event Play_Update was called. // @recomp_event recomp_after_play_update(PlayState* play): Play_Update was called.
recomp_after_play_update(this); recomp_after_play_update(this);
camera_post_play_update(this); camera_post_play_update(this);

View File

@ -16,7 +16,7 @@ RECOMP_PATCH void Main_Init(void) {
OSMesg msg[1]; OSMesg msg[1];
size_t prevSize; size_t prevSize;
// @recomp_event Allow mods to initialize themselves once. // @recomp_event recomp_on_init(): Allow mods to initialize themselves once.
recomp_on_init(); recomp_on_init();
osCreateMesgQueue(&mq, msg, ARRAY_COUNT(msg)); osCreateMesgQueue(&mq, msg, ARRAY_COUNT(msg));