From 4eeb01905dbab89149bd11decfa6bc9cc5e2ceb8 Mon Sep 17 00:00:00 2001 From: Archez Date: Thu, 7 Nov 2024 11:52:21 -0500 Subject: pull in decomp updates for z_play (#4522) --- soh/include/attributes.h | 12 ++++++++++++ soh/include/functions.h | 8 ++++---- soh/include/variables.h | 2 +- soh/include/z64.h | 1 + soh/include/z64save.h | 2 +- 5 files changed, 19 insertions(+), 6 deletions(-) create mode 100644 soh/include/attributes.h (limited to 'soh/include') diff --git a/soh/include/attributes.h b/soh/include/attributes.h new file mode 100644 index 000000000..f58cc8122 --- /dev/null +++ b/soh/include/attributes.h @@ -0,0 +1,12 @@ +#ifndef ATTRIBUTES_H +#define ATTRIBUTES_H + +#if !defined(__GNUC__) && !defined(__attribute__) +#define __attribute__(x) +#endif + +#define UNUSED __attribute__((unused)) +#define FALLTHROUGH __attribute__((fallthrough)) +#define NORETURN __attribute__((noreturn)) + +#endif diff --git a/soh/include/functions.h b/soh/include/functions.h index 41b325236..8a1f6572c 100644 --- a/soh/include/functions.h +++ b/soh/include/functions.h @@ -1536,9 +1536,9 @@ void KaleidoScopeCall_Init(PlayState* play); void KaleidoScopeCall_Destroy(PlayState* play); void KaleidoScopeCall_Update(PlayState* play); void KaleidoScopeCall_Draw(PlayState* play); -void func_800BC490(PlayState* play, s16 point); -s32 func_800BC56C(PlayState* play, s16 arg1); -void func_800BC590(PlayState* play); +void Play_SetViewpoint(PlayState* play, s16 viewpoint); +s32 Play_CheckViewpoint(PlayState* play, s16 viewpoint); +void Play_SetShopBrowsingViewpoint(PlayState* play); void Gameplay_SetupTransition(PlayState* play, s32 arg1); Gfx* Play_SetFog(PlayState* play, Gfx* gfx); void Play_Destroy(GameState* thisx); @@ -1552,7 +1552,7 @@ u8 CheckLACSRewardCount(); s32 Play_InCsMode(PlayState* play); f32 func_800BFCB8(PlayState* play, MtxF* mf, Vec3f* vec); void* Play_LoadFile(PlayState* play, RomFile* file); -void Play_SpawnScene(PlayState* play, s32 sceneNum, s32 spawn); +void Play_SpawnScene(PlayState* play, s32 sceneId, s32 spawn); void func_800C016C(PlayState* play, Vec3f* src, Vec3f* dest); s16 Play_CreateSubCamera(PlayState* play); s16 Play_GetActiveCamId(PlayState* play); diff --git a/soh/include/variables.h b/soh/include/variables.h index 5c97b26b8..25fb304d3 100644 --- a/soh/include/variables.h +++ b/soh/include/variables.h @@ -120,7 +120,7 @@ extern "C" extern KaleidoMgrOverlay gKaleidoMgrOverlayTable[KALEIDO_OVL_MAX]; extern KaleidoMgrOverlay* gKaleidoMgrCurOvl; extern u8 gBossMarkState; - extern void* D_8012D1F0; + extern void* gDebugCutsceneScript; extern s32 gScreenWidth; extern s32 gScreenHeight; extern Mtx gMtxClear; diff --git a/soh/include/z64.h b/soh/include/z64.h index f4cec6e82..00a67c844 100644 --- a/soh/include/z64.h +++ b/soh/include/z64.h @@ -3,6 +3,7 @@ #include #include "unk.h" // this used to get pulled in via ultra64.h +#include "attributes.h" #include "z64save.h" #include "z64light.h" #include "z64bgcheck.h" diff --git a/soh/include/z64save.h b/soh/include/z64save.h index 0233819ce..bf0d20697 100644 --- a/soh/include/z64save.h +++ b/soh/include/z64save.h @@ -361,7 +361,7 @@ typedef enum { /* 4 */ SCENE_LAYER_CUTSCENE_FIRST } SceneLayer; -#define IS_CUTSCENE_LAYER (gSaveContext.sceneLayer >= SCENE_LAYER_CUTSCENE_FIRST) +#define IS_CUTSCENE_LAYER (gSaveContext.sceneSetupIndex >= SCENE_LAYER_CUTSCENE_FIRST) typedef enum { /* 0 */ LINK_AGE_ADULT, -- cgit v1.2.3