mirror of
https://github.com/zeldaret/oot.git
synced 2025-05-10 19:13:42 +00:00
Document SaveContext.gameMode
(#1295)
* Document `SaveContext.gameMode` * end credits * Remove no longer needed comment
This commit is contained in:
parent
e16779cc33
commit
984871eb38
17 changed files with 41 additions and 31 deletions
|
@ -245,6 +245,13 @@ typedef enum {
|
||||||
/* 3 */ SUNSSONG_SPECIAL // time does not advance, but signals the song was played. used for freezing redeads
|
/* 3 */ SUNSSONG_SPECIAL // time does not advance, but signals the song was played. used for freezing redeads
|
||||||
} SunsSongState;
|
} SunsSongState;
|
||||||
|
|
||||||
|
typedef enum {
|
||||||
|
/* 0 */ GAMEMODE_NORMAL,
|
||||||
|
/* 1 */ GAMEMODE_TITLE_SCREEN,
|
||||||
|
/* 2 */ GAMEMODE_FILE_SELECT, // Note: only instance type transitions swap to file select
|
||||||
|
/* 3 */ GAMEMODE_END_CREDITS
|
||||||
|
} GameMode;
|
||||||
|
|
||||||
typedef enum {
|
typedef enum {
|
||||||
/* 0 */ LINK_AGE_ADULT,
|
/* 0 */ LINK_AGE_ADULT,
|
||||||
/* 1 */ LINK_AGE_CHILD
|
/* 1 */ LINK_AGE_CHILD
|
||||||
|
|
|
@ -384,7 +384,7 @@ void Graph_Update(GraphicsContext* gfxCtx, GameState* gameState) {
|
||||||
|
|
||||||
if (gIsCtrlr2Valid && CHECK_BTN_ALL(gameState->input[0].press.button, BTN_Z) &&
|
if (gIsCtrlr2Valid && CHECK_BTN_ALL(gameState->input[0].press.button, BTN_Z) &&
|
||||||
CHECK_BTN_ALL(gameState->input[0].cur.button, BTN_L | BTN_R)) {
|
CHECK_BTN_ALL(gameState->input[0].cur.button, BTN_L | BTN_R)) {
|
||||||
gSaveContext.gameMode = 0;
|
gSaveContext.gameMode = GAMEMODE_NORMAL;
|
||||||
SET_NEXT_GAMESTATE(gameState, MapSelect_Init, MapSelectState);
|
SET_NEXT_GAMESTATE(gameState, MapSelect_Init, MapSelectState);
|
||||||
gameState->running = false;
|
gameState->running = false;
|
||||||
}
|
}
|
||||||
|
|
|
@ -7529,7 +7529,7 @@ Vec3s Camera_Update(Camera* camera) {
|
||||||
}
|
}
|
||||||
|
|
||||||
if (camera->status == CAM_STAT_ACTIVE) {
|
if (camera->status == CAM_STAT_ACTIVE) {
|
||||||
if ((gSaveContext.gameMode != 0) && (gSaveContext.gameMode != 3)) {
|
if ((gSaveContext.gameMode != GAMEMODE_NORMAL) && (gSaveContext.gameMode != GAMEMODE_END_CREDITS)) {
|
||||||
sCameraInterfaceFlags = 0;
|
sCameraInterfaceFlags = 0;
|
||||||
Camera_UpdateInterface(sCameraInterfaceFlags);
|
Camera_UpdateInterface(sCameraInterfaceFlags);
|
||||||
} else if ((D_8011D3F0 != 0) && (camera->camId == CAM_ID_MAIN)) {
|
} else if ((D_8011D3F0 != 0) && (camera->camId == CAM_ID_MAIN)) {
|
||||||
|
|
|
@ -506,7 +506,7 @@ void func_80111070(void) {
|
||||||
WREG(94) = 3;
|
WREG(94) = 3;
|
||||||
WREG(95) = 6;
|
WREG(95) = 6;
|
||||||
|
|
||||||
if (gSaveContext.gameMode == 0) {
|
if (gSaveContext.gameMode == GAMEMODE_NORMAL) {
|
||||||
R_TEXTBOX_X = 52;
|
R_TEXTBOX_X = 52;
|
||||||
R_TEXTBOX_Y = 36;
|
R_TEXTBOX_Y = 36;
|
||||||
VREG(2) = 214;
|
VREG(2) = 214;
|
||||||
|
|
|
@ -489,8 +489,8 @@ void Cutscene_Command_Terminator(PlayState* play, CutsceneContext* csCtx, CsCmdB
|
||||||
Player* player = GET_PLAYER(play);
|
Player* player = GET_PLAYER(play);
|
||||||
s32 temp = 0;
|
s32 temp = 0;
|
||||||
|
|
||||||
if ((gSaveContext.gameMode != 0) && (gSaveContext.gameMode != 3) && (play->sceneNum != SCENE_SPOT00) &&
|
if ((gSaveContext.gameMode != GAMEMODE_NORMAL) && (gSaveContext.gameMode != GAMEMODE_END_CREDITS) &&
|
||||||
(csCtx->frames > 20) &&
|
(play->sceneNum != SCENE_SPOT00) && (csCtx->frames > 20) &&
|
||||||
(CHECK_BTN_ALL(play->state.input[0].press.button, BTN_A) ||
|
(CHECK_BTN_ALL(play->state.input[0].press.button, BTN_A) ||
|
||||||
CHECK_BTN_ALL(play->state.input[0].press.button, BTN_B) ||
|
CHECK_BTN_ALL(play->state.input[0].press.button, BTN_B) ||
|
||||||
CHECK_BTN_ALL(play->state.input[0].press.button, BTN_START)) &&
|
CHECK_BTN_ALL(play->state.input[0].press.button, BTN_START)) &&
|
||||||
|
@ -509,7 +509,7 @@ void Cutscene_Command_Terminator(PlayState* play, CutsceneContext* csCtx, CsCmdB
|
||||||
|
|
||||||
osSyncPrintf("\n分岐先指定!!=[%d]番", cmd->base); // "Future fork designation=No. [%d]"
|
osSyncPrintf("\n分岐先指定!!=[%d]番", cmd->base); // "Future fork designation=No. [%d]"
|
||||||
|
|
||||||
if ((gSaveContext.gameMode != 0) && (csCtx->frames != cmd->startFrame)) {
|
if ((gSaveContext.gameMode != GAMEMODE_NORMAL) && (csCtx->frames != cmd->startFrame)) {
|
||||||
gSaveContext.unk_13E7 = 1;
|
gSaveContext.unk_13E7 = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -826,7 +826,7 @@ void Cutscene_Command_Terminator(PlayState* play, CutsceneContext* csCtx, CsCmdB
|
||||||
play->transitionType = TRANS_TYPE_FADE_WHITE;
|
play->transitionType = TRANS_TYPE_FADE_WHITE;
|
||||||
break;
|
break;
|
||||||
case 54:
|
case 54:
|
||||||
gSaveContext.gameMode = 3;
|
gSaveContext.gameMode = GAMEMODE_END_CREDITS;
|
||||||
Audio_SetSoundBanksMute(0x6F);
|
Audio_SetSoundBanksMute(0x6F);
|
||||||
play->linkAgeOnLoad = LINK_AGE_CHILD;
|
play->linkAgeOnLoad = LINK_AGE_CHILD;
|
||||||
play->nextEntranceIndex = ENTR_SPOT09_0;
|
play->nextEntranceIndex = ENTR_SPOT09_0;
|
||||||
|
@ -1207,7 +1207,7 @@ void Cutscene_Command_Terminator(PlayState* play, CutsceneContext* csCtx, CsCmdB
|
||||||
gSaveContext.nextTransitionType = TRANS_TYPE_FADE_WHITE;
|
gSaveContext.nextTransitionType = TRANS_TYPE_FADE_WHITE;
|
||||||
break;
|
break;
|
||||||
case 117:
|
case 117:
|
||||||
gSaveContext.gameMode = 3;
|
gSaveContext.gameMode = GAMEMODE_END_CREDITS;
|
||||||
Audio_SetSoundBanksMute(0x6F);
|
Audio_SetSoundBanksMute(0x6F);
|
||||||
play->linkAgeOnLoad = LINK_AGE_ADULT;
|
play->linkAgeOnLoad = LINK_AGE_ADULT;
|
||||||
play->nextEntranceIndex = ENTR_SPOT00_0;
|
play->nextEntranceIndex = ENTR_SPOT00_0;
|
||||||
|
@ -1959,7 +1959,7 @@ void func_80068DC0(PlayState* play, CutsceneContext* csCtx) {
|
||||||
|
|
||||||
osSyncPrintf("\n\n\n\n\nやっぱりここかいな"); // "Right here, huh"
|
osSyncPrintf("\n\n\n\n\nやっぱりここかいな"); // "Right here, huh"
|
||||||
gSaveContext.cutsceneIndex = 0;
|
gSaveContext.cutsceneIndex = 0;
|
||||||
gSaveContext.gameMode = 0;
|
gSaveContext.gameMode = GAMEMODE_NORMAL;
|
||||||
|
|
||||||
if (D_8015FCC8 != 0) {
|
if (D_8015FCC8 != 0) {
|
||||||
switch (gSaveContext.entranceIndex) {
|
switch (gSaveContext.entranceIndex) {
|
||||||
|
@ -2076,7 +2076,8 @@ void Cutscene_HandleEntranceTriggers(PlayState* play) {
|
||||||
void Cutscene_HandleConditionalTriggers(PlayState* play) {
|
void Cutscene_HandleConditionalTriggers(PlayState* play) {
|
||||||
osSyncPrintf("\ngame_info.mode=[%d] restart_flag", ((void)0, gSaveContext.respawnFlag));
|
osSyncPrintf("\ngame_info.mode=[%d] restart_flag", ((void)0, gSaveContext.respawnFlag));
|
||||||
|
|
||||||
if ((gSaveContext.gameMode == 0) && (gSaveContext.respawnFlag <= 0) && (gSaveContext.cutsceneIndex < 0xFFF0)) {
|
if ((gSaveContext.gameMode == GAMEMODE_NORMAL) && (gSaveContext.respawnFlag <= 0) &&
|
||||||
|
(gSaveContext.cutsceneIndex < 0xFFF0)) {
|
||||||
if ((gSaveContext.entranceIndex == ENTR_SPOT11_1) && !Flags_GetEventChkInf(EVENTCHKINF_AC)) {
|
if ((gSaveContext.entranceIndex == ENTR_SPOT11_1) && !Flags_GetEventChkInf(EVENTCHKINF_AC)) {
|
||||||
Flags_SetEventChkInf(EVENTCHKINF_AC);
|
Flags_SetEventChkInf(EVENTCHKINF_AC);
|
||||||
gSaveContext.entranceIndex = ENTR_SPOT11_0;
|
gSaveContext.entranceIndex = ENTR_SPOT11_0;
|
||||||
|
|
|
@ -881,7 +881,8 @@ void Environment_Update(PlayState* play, EnvironmentContext* envCtx, LightContex
|
||||||
EnvLightSettings* lightSettingsList = play->envCtx.lightSettingsList;
|
EnvLightSettings* lightSettingsList = play->envCtx.lightSettingsList;
|
||||||
s32 adjustment;
|
s32 adjustment;
|
||||||
|
|
||||||
if ((((void)0, gSaveContext.gameMode) != 0) && (((void)0, gSaveContext.gameMode) != 3)) {
|
if ((((void)0, gSaveContext.gameMode) != GAMEMODE_NORMAL) &&
|
||||||
|
(((void)0, gSaveContext.gameMode) != GAMEMODE_END_CREDITS)) {
|
||||||
func_800AA16C();
|
func_800AA16C();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -918,9 +919,10 @@ void Environment_Update(PlayState* play, EnvironmentContext* envCtx, LightContex
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((pauseCtx->state == 0) && (gameOverCtx->state == GAMEOVER_INACTIVE)) {
|
if ((pauseCtx->state == 0) && (gameOverCtx->state == GAMEOVER_INACTIVE)) {
|
||||||
if (((msgCtx->msgLength == 0) && (msgCtx->msgMode == 0)) || (((void)0, gSaveContext.gameMode) == 3)) {
|
if (((msgCtx->msgLength == 0) && (msgCtx->msgMode == GAMEMODE_NORMAL)) ||
|
||||||
|
(((void)0, gSaveContext.gameMode) == GAMEMODE_END_CREDITS)) {
|
||||||
if ((envCtx->changeSkyboxTimer == 0) && !FrameAdvance_IsEnabled(play) &&
|
if ((envCtx->changeSkyboxTimer == 0) && !FrameAdvance_IsEnabled(play) &&
|
||||||
(play->transitionMode == TRANS_MODE_OFF || ((void)0, gSaveContext.gameMode) != 0)) {
|
(play->transitionMode == TRANS_MODE_OFF || ((void)0, gSaveContext.gameMode) != GAMEMODE_NORMAL)) {
|
||||||
|
|
||||||
if (IS_DAY || gTimeSpeed >= 400) {
|
if (IS_DAY || gTimeSpeed >= 400) {
|
||||||
gSaveContext.dayTime += gTimeSpeed;
|
gSaveContext.dayTime += gTimeSpeed;
|
||||||
|
|
|
@ -2439,7 +2439,7 @@ void Magic_Update(PlayState* play) {
|
||||||
// Add magic until magicFillTarget is reached
|
// Add magic until magicFillTarget is reached
|
||||||
gSaveContext.magic += 4;
|
gSaveContext.magic += 4;
|
||||||
|
|
||||||
if (gSaveContext.gameMode == 0 && gSaveContext.sceneSetupIndex < 4) {
|
if (gSaveContext.gameMode == GAMEMODE_NORMAL && gSaveContext.sceneSetupIndex < 4) {
|
||||||
Audio_PlaySoundGeneral(NA_SE_SY_GAUGE_UP - SFX_FLAG, &gSfxDefaultPos, 4, &gSfxDefaultFreqAndVolScale,
|
Audio_PlaySoundGeneral(NA_SE_SY_GAUGE_UP - SFX_FLAG, &gSfxDefaultPos, 4, &gSfxDefaultFreqAndVolScale,
|
||||||
&gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb);
|
&gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb);
|
||||||
}
|
}
|
||||||
|
|
|
@ -288,7 +288,7 @@ void Play_Init(GameState* thisx) {
|
||||||
|
|
||||||
Cutscene_HandleConditionalTriggers(this);
|
Cutscene_HandleConditionalTriggers(this);
|
||||||
|
|
||||||
if (gSaveContext.gameMode != 0 || gSaveContext.cutsceneIndex >= 0xFFF0) {
|
if (gSaveContext.gameMode != GAMEMODE_NORMAL || gSaveContext.cutsceneIndex >= 0xFFF0) {
|
||||||
gSaveContext.nayrusLoveTimer = 0;
|
gSaveContext.nayrusLoveTimer = 0;
|
||||||
Magic_Reset(this);
|
Magic_Reset(this);
|
||||||
gSaveContext.sceneSetupIndex = (gSaveContext.cutsceneIndex & 0xF) + 4;
|
gSaveContext.sceneSetupIndex = (gSaveContext.cutsceneIndex & 0xF) + 4;
|
||||||
|
@ -369,7 +369,7 @@ void Play_Init(GameState* thisx) {
|
||||||
this->unk_11E18 = 0;
|
this->unk_11E18 = 0;
|
||||||
this->unk_11DE9 = false;
|
this->unk_11DE9 = false;
|
||||||
|
|
||||||
if (gSaveContext.gameMode != 1) {
|
if (gSaveContext.gameMode != GAMEMODE_TITLE_SCREEN) {
|
||||||
if (gSaveContext.nextTransitionType == TRANS_NEXT_TYPE_DEFAULT) {
|
if (gSaveContext.nextTransitionType == TRANS_NEXT_TYPE_DEFAULT) {
|
||||||
this->transitionType = ENTRANCE_INFO_END_TRANS_TYPE(
|
this->transitionType = ENTRANCE_INFO_END_TRANS_TYPE(
|
||||||
gEntranceTable[((void)0, gSaveContext.entranceIndex) + tempSetupIndex].field);
|
gEntranceTable[((void)0, gSaveContext.entranceIndex) + tempSetupIndex].field);
|
||||||
|
@ -627,7 +627,7 @@ void Play_Update(PlayState* this) {
|
||||||
} else if (this->transitionTrigger != TRANS_TRIGGER_END) {
|
} else if (this->transitionTrigger != TRANS_TRIGGER_END) {
|
||||||
this->state.running = false;
|
this->state.running = false;
|
||||||
|
|
||||||
if (gSaveContext.gameMode != 2) {
|
if (gSaveContext.gameMode != GAMEMODE_FILE_SELECT) {
|
||||||
SET_NEXT_GAMESTATE(&this->state, Play_Init, PlayState);
|
SET_NEXT_GAMESTATE(&this->state, Play_Init, PlayState);
|
||||||
gSaveContext.entranceIndex = this->nextEntranceIndex;
|
gSaveContext.entranceIndex = this->nextEntranceIndex;
|
||||||
|
|
||||||
|
@ -832,7 +832,7 @@ void Play_Update(PlayState* this) {
|
||||||
if (1 && (gTrnsnUnkState != 3)) {
|
if (1 && (gTrnsnUnkState != 3)) {
|
||||||
PLAY_LOG(3542);
|
PLAY_LOG(3542);
|
||||||
|
|
||||||
if ((gSaveContext.gameMode == 0) && (this->msgCtx.msgMode == MSGMODE_NONE) &&
|
if ((gSaveContext.gameMode == GAMEMODE_NORMAL) && (this->msgCtx.msgMode == MSGMODE_NONE) &&
|
||||||
(this->gameOverCtx.state == GAMEOVER_INACTIVE)) {
|
(this->gameOverCtx.state == GAMEOVER_INACTIVE)) {
|
||||||
KaleidoSetup_Update(this);
|
KaleidoSetup_Update(this);
|
||||||
}
|
}
|
||||||
|
@ -930,7 +930,7 @@ void Play_Update(PlayState* this) {
|
||||||
Play_SetViewpoint(this, this->viewpoint ^ (VIEWPOINT_LOCKED ^ VIEWPOINT_PIVOT));
|
Play_SetViewpoint(this, this->viewpoint ^ (VIEWPOINT_LOCKED ^ VIEWPOINT_PIVOT));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Play_ChangeViewpointBgCamIndex(this);
|
Play_ChangeViewpointBgCamIndex(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1006,7 +1006,7 @@ void Play_DrawOverlayElements(PlayState* this) {
|
||||||
KaleidoScopeCall_Draw(this);
|
KaleidoScopeCall_Draw(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (gSaveContext.gameMode == 0) {
|
if (gSaveContext.gameMode == GAMEMODE_NORMAL) {
|
||||||
Interface_Draw(this);
|
Interface_Draw(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -903,7 +903,8 @@ void Player_DrawImpl(PlayState* play, void** skeleton, Vec3s* jointTable, s32 dL
|
||||||
SkelAnime_DrawFlexLod(play, skeleton, jointTable, dListCount, overrideLimbDraw, postLimbDraw, data, lod);
|
SkelAnime_DrawFlexLod(play, skeleton, jointTable, dListCount, overrideLimbDraw, postLimbDraw, data, lod);
|
||||||
|
|
||||||
if ((overrideLimbDraw != Player_OverrideLimbDrawGameplayFirstPerson) &&
|
if ((overrideLimbDraw != Player_OverrideLimbDrawGameplayFirstPerson) &&
|
||||||
(overrideLimbDraw != Player_OverrideLimbDrawGameplay_80090440) && (gSaveContext.gameMode != 3)) {
|
(overrideLimbDraw != Player_OverrideLimbDrawGameplay_80090440) &&
|
||||||
|
(gSaveContext.gameMode != GAMEMODE_END_CREDITS)) {
|
||||||
if (LINK_IS_ADULT) {
|
if (LINK_IS_ADULT) {
|
||||||
s32 strengthUpgrade = CUR_UPG_VALUE(UPG_STRENGTH);
|
s32 strengthUpgrade = CUR_UPG_VALUE(UPG_STRENGTH);
|
||||||
|
|
||||||
|
|
|
@ -49,8 +49,7 @@ void EnLight_Init(Actor* thisx, PlayState* play) {
|
||||||
EnLight* this = (EnLight*)thisx;
|
EnLight* this = (EnLight*)thisx;
|
||||||
s16 yOffset;
|
s16 yOffset;
|
||||||
|
|
||||||
if (gSaveContext.gameMode == 3) {
|
if (gSaveContext.gameMode == GAMEMODE_END_CREDITS) {
|
||||||
// special case for the credits
|
|
||||||
yOffset = (this->actor.params < 0) ? 1 : 40;
|
yOffset = (this->actor.params < 0) ? 1 : 40;
|
||||||
Lights_PointNoGlowSetInfo(&this->lightInfo, this->actor.world.pos.x, yOffset + (s16)this->actor.world.pos.y,
|
Lights_PointNoGlowSetInfo(&this->lightInfo, this->actor.world.pos.x, yOffset + (s16)this->actor.world.pos.y,
|
||||||
this->actor.world.pos.z, 255, 255, 180, -1);
|
this->actor.world.pos.z, 255, 255, 180, -1);
|
||||||
|
|
|
@ -145,7 +145,7 @@ void EnMag_Update(Actor* thisx, PlayState* play) {
|
||||||
Audio_PlaySoundGeneral(NA_SE_SY_PIECE_OF_HEART, &gSfxDefaultPos, 4, &gSfxDefaultFreqAndVolScale,
|
Audio_PlaySoundGeneral(NA_SE_SY_PIECE_OF_HEART, &gSfxDefaultPos, 4, &gSfxDefaultFreqAndVolScale,
|
||||||
&gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb);
|
&gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb);
|
||||||
|
|
||||||
gSaveContext.gameMode = 2;
|
gSaveContext.gameMode = GAMEMODE_FILE_SELECT;
|
||||||
play->transitionTrigger = TRANS_TRIGGER_START;
|
play->transitionTrigger = TRANS_TRIGGER_START;
|
||||||
play->transitionType = TRANS_TYPE_FADE_BLACK;
|
play->transitionType = TRANS_TYPE_FADE_BLACK;
|
||||||
}
|
}
|
||||||
|
|
|
@ -459,7 +459,7 @@ void func_80AAE294(EnMm* this, PlayState* play) {
|
||||||
dustPos.y = this->actor.world.pos.y;
|
dustPos.y = this->actor.world.pos.y;
|
||||||
dustPos.z = this->actor.world.pos.z;
|
dustPos.z = this->actor.world.pos.z;
|
||||||
|
|
||||||
if (gSaveContext.gameMode != 3) {
|
if (gSaveContext.gameMode != GAMEMODE_END_CREDITS) {
|
||||||
func_80033480(play, &dustPos, 50.0f, 2, 350, 20, 0);
|
func_80033480(play, &dustPos, 50.0f, 2, 350, 20, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -73,7 +73,7 @@ void EnOkarinaEffect_ManageStorm(EnOkarinaEffect* this, PlayState* play) {
|
||||||
Flags_UnsetEnv(play, 5); // clear storms env flag
|
Flags_UnsetEnv(play, 5); // clear storms env flag
|
||||||
if (((play->pauseCtx.state == 0) && (play->gameOverCtx.state == GAMEOVER_INACTIVE) &&
|
if (((play->pauseCtx.state == 0) && (play->gameOverCtx.state == GAMEOVER_INACTIVE) &&
|
||||||
(play->msgCtx.msgLength == 0) && (!FrameAdvance_IsEnabled(play)) &&
|
(play->msgCtx.msgLength == 0) && (!FrameAdvance_IsEnabled(play)) &&
|
||||||
((play->transitionMode == TRANS_MODE_OFF) || (gSaveContext.gameMode != 0))) ||
|
((play->transitionMode == TRANS_MODE_OFF) || (gSaveContext.gameMode != GAMEMODE_NORMAL))) ||
|
||||||
(this->timer >= 250)) {
|
(this->timer >= 250)) {
|
||||||
if ((play->envCtx.lightMode != LIGHT_MODE_TIME) || play->envCtx.lightConfig != 1) {
|
if ((play->envCtx.lightMode != LIGHT_MODE_TIME) || play->envCtx.lightConfig != 1) {
|
||||||
this->timer--;
|
this->timer--;
|
||||||
|
|
|
@ -9373,7 +9373,7 @@ void Player_Init(Actor* thisx, PlayState* play2) {
|
||||||
D_80854738[initMode](play, this);
|
D_80854738[initMode](play, this);
|
||||||
|
|
||||||
if (initMode != 0) {
|
if (initMode != 0) {
|
||||||
if ((gSaveContext.gameMode == 0) || (gSaveContext.gameMode == 3)) {
|
if ((gSaveContext.gameMode == GAMEMODE_NORMAL) || (gSaveContext.gameMode == GAMEMODE_END_CREDITS)) {
|
||||||
this->naviActor = Player_SpawnFairy(play, this, &thisx->world.pos, &D_80854778, FAIRY_NAVI);
|
this->naviActor = Player_SpawnFairy(play, this, &thisx->world.pos, &D_80854778, FAIRY_NAVI);
|
||||||
if (gSaveContext.dogParams != 0) {
|
if (gSaveContext.dogParams != 0) {
|
||||||
gSaveContext.dogParams |= 0x8000;
|
gSaveContext.dogParams |= 0x8000;
|
||||||
|
|
|
@ -1445,7 +1445,7 @@ void FileSelect_LoadGame(GameState* thisx) {
|
||||||
&gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb);
|
&gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb);
|
||||||
gSaveContext.fileNum = this->buttonIndex;
|
gSaveContext.fileNum = this->buttonIndex;
|
||||||
Sram_OpenSave(&this->sramCtx);
|
Sram_OpenSave(&this->sramCtx);
|
||||||
gSaveContext.gameMode = 0;
|
gSaveContext.gameMode = GAMEMODE_NORMAL;
|
||||||
SET_NEXT_GAMESTATE(&this->state, MapSelect_Init, MapSelectState);
|
SET_NEXT_GAMESTATE(&this->state, MapSelect_Init, MapSelectState);
|
||||||
this->state.running = false;
|
this->state.running = false;
|
||||||
} else {
|
} else {
|
||||||
|
@ -1453,7 +1453,7 @@ void FileSelect_LoadGame(GameState* thisx) {
|
||||||
&gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb);
|
&gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb);
|
||||||
gSaveContext.fileNum = this->buttonIndex;
|
gSaveContext.fileNum = this->buttonIndex;
|
||||||
Sram_OpenSave(&this->sramCtx);
|
Sram_OpenSave(&this->sramCtx);
|
||||||
gSaveContext.gameMode = 0;
|
gSaveContext.gameMode = GAMEMODE_NORMAL;
|
||||||
SET_NEXT_GAMESTATE(&this->state, Play_Init, PlayState);
|
SET_NEXT_GAMESTATE(&this->state, Play_Init, PlayState);
|
||||||
this->state.running = false;
|
this->state.running = false;
|
||||||
}
|
}
|
||||||
|
|
|
@ -7,7 +7,7 @@
|
||||||
#include "global.h"
|
#include "global.h"
|
||||||
|
|
||||||
void TitleSetup_SetupTitleScreen(TitleSetupState* this) {
|
void TitleSetup_SetupTitleScreen(TitleSetupState* this) {
|
||||||
gSaveContext.gameMode = 1;
|
gSaveContext.gameMode = GAMEMODE_TITLE_SCREEN;
|
||||||
this->state.running = false;
|
this->state.running = false;
|
||||||
gSaveContext.linkAge = LINK_AGE_ADULT;
|
gSaveContext.linkAge = LINK_AGE_ADULT;
|
||||||
Sram_InitDebugSave();
|
Sram_InitDebugSave();
|
||||||
|
|
|
@ -139,7 +139,7 @@ void ConsoleLogo_Main(GameState* thisx) {
|
||||||
if (this->exit) {
|
if (this->exit) {
|
||||||
gSaveContext.seqId = (u8)NA_BGM_DISABLED;
|
gSaveContext.seqId = (u8)NA_BGM_DISABLED;
|
||||||
gSaveContext.natureAmbienceId = 0xFF;
|
gSaveContext.natureAmbienceId = 0xFF;
|
||||||
gSaveContext.gameMode = 1;
|
gSaveContext.gameMode = GAMEMODE_TITLE_SCREEN;
|
||||||
this->state.running = false;
|
this->state.running = false;
|
||||||
SET_NEXT_GAMESTATE(&this->state, TitleSetup_Init, TitleSetupState);
|
SET_NEXT_GAMESTATE(&this->state, TitleSetup_Init, TitleSetupState);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue