Add gPlayState

This commit is contained in:
Garrett Cox 2024-01-05 23:33:13 -06:00
parent fd7e53e7bf
commit 13a369e871
2 changed files with 14 additions and 0 deletions

View File

@ -1758,5 +1758,9 @@ extern GfxMasterList D_0E000000;
extern Mtx D_01000000;
extern u16 D_0F000000[];
// #region 2S2H [General]
extern PlayState* gPlayState;
// #endregion
#endif

View File

@ -38,6 +38,10 @@ u8 sMotionBlurStatus;
s32 gDbgCamEnabled = false;
u8 D_801D0D54 = false;
// #region 2S2H [General] Making gPlayState available
PlayState* gPlayState;
// #endregion
typedef enum {
/* 0 */ MOTION_BLUR_OFF,
/* 1 */ MOTION_BLUR_SETUP,
@ -429,6 +433,9 @@ void Play_Destroy(GameState* thisx) {
KaleidoScopeCall_Destroy(this);
KaleidoManager_Destroy();
ZeldaArena_Cleanup();
// #region 2S2H [General] Making gPlayState available
gPlayState = NULL;
// #endregion
}
#define PLAY_COMPRESS_BITS 5
@ -2090,6 +2097,9 @@ void Play_FillScreen(GameState* thisx, s16 fillScreenOn, u8 red, u8 green, u8 bl
void Play_Init(GameState* thisx) {
PlayState* this = (PlayState*)thisx;
// #region 2S2H [General] Making gPlayState available
gPlayState = this;
// #endregion
GraphicsContext* gfxCtx = this->state.gfxCtx;
s32 pad;
uintptr_t zAlloc;