summaryrefslogtreecommitdiff
path: root/src/code/z_kaleido_setup.c
diff options
context:
space:
mode:
authorfig02 <fig02srl@gmail.com>2022-05-21 14:23:43 -0400
committerGitHub <noreply@github.com>2022-05-21 14:23:43 -0400
commit2e6279bc8e528833704bc6b77635f0eeae6bbe44 (patch)
treed407e4462e1a07b22d11fd84c8013ab182153aaa /src/code/z_kaleido_setup.c
parent154f44b6da6e0b9be69886ec8d8a5a8ea2f4791e (diff)
PlayState Rename (#1231)
* global context -> play * fix PlayState* PlayState
Diffstat (limited to 'src/code/z_kaleido_setup.c')
-rw-r--r--src/code/z_kaleido_setup.c24
1 files changed, 12 insertions, 12 deletions
diff --git a/src/code/z_kaleido_setup.c b/src/code/z_kaleido_setup.c
index cb05b520e..bbc66d5bc 100644
--- a/src/code/z_kaleido_setup.c
+++ b/src/code/z_kaleido_setup.c
@@ -8,15 +8,15 @@ s16 sKaleidoSetupKscpPos1[] = { PAUSE_MAP, PAUSE_QUEST, PAUSE_EQUIP, PAUSE_ITEM
f32 sKaleidoSetupEyeX1[] = { -64.0f, 0.0f, 64.0f, 0.0f };
f32 sKaleidoSetupEyeZ1[] = { 0.0f, -64.0f, 0.0f, 64.0f };
-void KaleidoSetup_Update(GlobalContext* globalCtx) {
- PauseContext* pauseCtx = &globalCtx->pauseCtx;
- Input* input = &globalCtx->state.input[0];
+void KaleidoSetup_Update(PlayState* play) {
+ PauseContext* pauseCtx = &play->pauseCtx;
+ Input* input = &play->state.input[0];
- if (pauseCtx->state == 0 && pauseCtx->debugState == 0 && globalCtx->gameOverCtx.state == GAMEOVER_INACTIVE &&
- globalCtx->transitionTrigger == TRANS_TRIGGER_OFF && globalCtx->transitionMode == TRANS_MODE_OFF &&
- gSaveContext.cutsceneIndex < 0xFFF0 && gSaveContext.nextCutsceneIndex < 0xFFF0 && !Play_InCsMode(globalCtx) &&
- globalCtx->shootingGalleryStatus <= 1 && gSaveContext.unk_13F0 != 8 && gSaveContext.unk_13F0 != 9 &&
- (globalCtx->sceneNum != SCENE_BOWLING || !Flags_GetSwitch(globalCtx, 0x38))) {
+ if (pauseCtx->state == 0 && pauseCtx->debugState == 0 && play->gameOverCtx.state == GAMEOVER_INACTIVE &&
+ play->transitionTrigger == TRANS_TRIGGER_OFF && play->transitionMode == TRANS_MODE_OFF &&
+ gSaveContext.cutsceneIndex < 0xFFF0 && gSaveContext.nextCutsceneIndex < 0xFFF0 && !Play_InCsMode(play) &&
+ play->shootingGalleryStatus <= 1 && gSaveContext.unk_13F0 != 8 && gSaveContext.unk_13F0 != 9 &&
+ (play->sceneNum != SCENE_BOWLING || !Flags_GetSwitch(play, 0x38))) {
if (CHECK_BTN_ALL(input->cur.button, BTN_L) && CHECK_BTN_ALL(input->press.button, BTN_CUP)) {
if (BREG(0)) {
@@ -61,8 +61,8 @@ void KaleidoSetup_Update(GlobalContext* globalCtx) {
}
}
-void KaleidoSetup_Init(GlobalContext* globalCtx) {
- PauseContext* pauseCtx = &globalCtx->pauseCtx;
+void KaleidoSetup_Init(PlayState* play) {
+ PauseContext* pauseCtx = &play->pauseCtx;
u64 temp = 0; // Necessary to match
pauseCtx->state = 0;
@@ -114,8 +114,8 @@ void KaleidoSetup_Init(GlobalContext* globalCtx) {
pauseCtx->ocarinaSongIdx = -1;
pauseCtx->cursorSpecialPos = 0;
- View_Init(&pauseCtx->view, globalCtx->state.gfxCtx);
+ View_Init(&pauseCtx->view, play->state.gfxCtx);
}
-void KaleidoSetup_Destroy(GlobalContext* globalCtx) {
+void KaleidoSetup_Destroy(PlayState* play) {
}