1
0
Fork 0
mirror of https://github.com/zeldaret/oot.git synced 2025-08-17 20:42:23 +00:00

Clean Up Sequence Structs in Scene/Save/z64 (#1051)

* Clean up sound scene struct

* Follow-up cleaning

* cleanup

* Document forcedSeqId

* Update include/z64save.h

Co-authored-by: fig02 <fig02srl@gmail.com>

* Update include/z64.h

Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com>

Co-authored-by: fig02 <fig02srl@gmail.com>
Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com>
This commit is contained in:
engineer124 2021-12-04 01:49:32 +11:00 committed by GitHub
parent 21a92ab95f
commit 5e9d24fca4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
20 changed files with 96 additions and 97 deletions

View file

@ -115,11 +115,11 @@ void EnHorseGameCheck_FinishIngoRace(EnHorseGameCheckIngoRace* this, GlobalConte
gSaveContext.eventInf[0] = (gSaveContext.eventInf[0] & ~0xF) | 6;
gSaveContext.eventInf[0] = (gSaveContext.eventInf[0] & ~0x8000) | 0x8000;
globalCtx->fadeTransition = 3;
func_800775F0(NA_BGM_INGO);
Environment_ForcePlaySequence(NA_BGM_INGO);
} else {
gSaveContext.eventInf[0] = (gSaveContext.eventInf[0] & ~0xF) | 4;
gSaveContext.eventInf[0] = (gSaveContext.eventInf[0] & ~0x8000) | 0x8000;
func_800775F0(NA_BGM_INGO);
Environment_ForcePlaySequence(NA_BGM_INGO);
globalCtx->fadeTransition = 0x2E;
}
} else {

View file

@ -630,7 +630,7 @@ void func_80A7A4C8(EnIn* this, GlobalContext* globalCtx) {
gSaveContext.eventInf[0] = (gSaveContext.eventInf[0] & ~0x000F) | 0x0001;
gSaveContext.eventInf[0] = (gSaveContext.eventInf[0] & ~0x8000) | 0x8000;
gSaveContext.infTable[10] &= ~4;
func_800775F0(NA_BGM_HORSE);
Environment_ForcePlaySequence(NA_BGM_HORSE);
globalCtx->msgCtx.stateTimer = 0;
globalCtx->msgCtx.msgMode = MSGMODE_TEXT_CLOSING;
this->unk_308.unk_00 = 0;

View file

@ -94,7 +94,7 @@ void EnOkarinaEffect_ManageStorm(EnOkarinaEffect* this, GlobalContext* globalCtx
globalCtx->envCtx.unk_F2[0] = 0;
if (globalCtx->csCtx.state == CS_STATE_IDLE) {
func_80077684(globalCtx);
} else if (func_800FA0B4(SEQ_PLAYER_BGM_MAIN) == NA_BGM_NATURE_BACKGROUND) {
} else if (func_800FA0B4(SEQ_PLAYER_BGM_MAIN) == NA_BGM_NATURE_AMBIENCE) {
func_800F6D58(0xF, 1, 0);
func_800F6D58(0xE, 1, 0);
}

View file

@ -58,7 +58,7 @@ const ActorInit En_Syateki_Man_InitVars = {
static u16 sBgmList[] = {
NA_BGM_GENERAL_SFX,
NA_BGM_NATURE_BACKGROUND,
NA_BGM_NATURE_AMBIENCE,
NA_BGM_FIELD_LOGIC,
NA_BGM_DUNGEON,
NA_BGM_KAKARIKO_ADULT,

View file

@ -2824,8 +2824,8 @@ void func_80836448(GlobalContext* globalCtx, Player* this, LinkAnimationHeader*
globalCtx->gameOverCtx.state = GAMEOVER_DEATH_START;
func_800F6AB0(0);
Audio_PlayFanfare(NA_BGM_GAME_OVER);
gSaveContext.seqIndex = (u8)NA_BGM_DISABLED;
gSaveContext.nightSeqIndex = 0xFF;
gSaveContext.seqId = (u8)NA_BGM_DISABLED;
gSaveContext.natureAmbienceId = 0xFF;
}
OnePointCutscene_Init(globalCtx, 9806, cond ? 120 : 60, &this->actor, MAIN_CAM);
@ -3986,8 +3986,8 @@ s32 func_80839034(GlobalContext* globalCtx, Player* this, CollisionPoly* poly, u
if (temp == 11) {
func_800788CC(NA_SE_OC_SECRET_HOLE_OUT);
func_800F6964(5);
gSaveContext.seqIndex = (u8)NA_BGM_DISABLED;
gSaveContext.nightSeqIndex = 0xFF;
gSaveContext.seqId = (u8)NA_BGM_DISABLED;
gSaveContext.natureAmbienceId = 0xFF;
} else {
linearVel = this->linearVelocity;
@ -11923,8 +11923,8 @@ void func_8084E3C4(Player* this, GlobalContext* globalCtx) {
Environment_WarpSongLeave(globalCtx);
}
gSaveContext.seqIndex = (u8)NA_BGM_DISABLED;
gSaveContext.nightSeqIndex = 0xFF;
gSaveContext.seqId = (u8)NA_BGM_DISABLED;
gSaveContext.natureAmbienceId = 0xFF;
}
}
@ -12440,8 +12440,8 @@ void func_8084F88C(Player* this, GlobalContext* globalCtx) {
} else {
globalCtx->fadeTransition = 2;
gSaveContext.nextTransition = 2;
gSaveContext.seqIndex = (u8)NA_BGM_DISABLED;
gSaveContext.nightSeqIndex = 0xFF;
gSaveContext.seqId = (u8)NA_BGM_DISABLED;
gSaveContext.natureAmbienceId = 0xFF;
}
globalCtx->sceneLoadFlag = 0x14;