mirror of
https://github.com/zeldaret/oot.git
synced 2024-11-10 19:20:13 +00:00
parent
53b0114464
commit
e48cdaf598
3 changed files with 20 additions and 16 deletions
|
@ -80,9 +80,10 @@ void KaleidoManager_Destroy(void) {
|
||||||
void* KaleidoManager_GetRamAddr(void* vram) {
|
void* KaleidoManager_GetRamAddr(void* vram) {
|
||||||
KaleidoMgrOverlay* iter = gKaleidoMgrCurOvl;
|
KaleidoMgrOverlay* iter = gKaleidoMgrCurOvl;
|
||||||
KaleidoMgrOverlay* ovl = iter;
|
KaleidoMgrOverlay* ovl = iter;
|
||||||
u32 i;
|
|
||||||
|
|
||||||
if (ovl == NULL) {
|
if (ovl == NULL) {
|
||||||
|
u32 i;
|
||||||
|
|
||||||
iter = &gKaleidoMgrOverlayTable[0];
|
iter = &gKaleidoMgrOverlayTable[0];
|
||||||
for (i = 0; i < ARRAY_COUNT(gKaleidoMgrOverlayTable); i++) {
|
for (i = 0; i < ARRAY_COUNT(gKaleidoMgrOverlayTable); i++) {
|
||||||
if (((uintptr_t)vram >= (uintptr_t)iter->vramStart) && ((uintptr_t)iter->vramEnd >= (uintptr_t)vram)) {
|
if (((uintptr_t)vram >= (uintptr_t)iter->vramStart) && ((uintptr_t)iter->vramEnd >= (uintptr_t)vram)) {
|
||||||
|
|
|
@ -56,19 +56,25 @@ void KaleidoScopeCall_Update(PlayState* play) {
|
||||||
KaleidoMgrOverlay* kaleidoScopeOvl = &gKaleidoMgrOverlayTable[KALEIDO_OVL_KALEIDO_SCOPE];
|
KaleidoMgrOverlay* kaleidoScopeOvl = &gKaleidoMgrOverlayTable[KALEIDO_OVL_KALEIDO_SCOPE];
|
||||||
PauseContext* pauseCtx = &play->pauseCtx;
|
PauseContext* pauseCtx = &play->pauseCtx;
|
||||||
|
|
||||||
if (IS_PAUSED(pauseCtx)) {
|
if (IS_PAUSED(&play->pauseCtx)) {
|
||||||
if (pauseCtx->state == PAUSE_STATE_WAIT_LETTERBOX) {
|
if (pauseCtx->state == PAUSE_STATE_WAIT_LETTERBOX) {
|
||||||
if (Letterbox_GetSize() == 0) {
|
if (Letterbox_GetSize() == 0) {
|
||||||
|
#if OOT_DEBUG
|
||||||
R_HREG_MODE = HREG_MODE_UCODE_DISAS;
|
R_HREG_MODE = HREG_MODE_UCODE_DISAS;
|
||||||
R_UCODE_DISAS_LOG_MODE = 3;
|
R_UCODE_DISAS_LOG_MODE = 3;
|
||||||
|
#endif
|
||||||
|
|
||||||
R_PAUSE_BG_PRERENDER_STATE = PAUSE_BG_PRERENDER_SETUP;
|
R_PAUSE_BG_PRERENDER_STATE = PAUSE_BG_PRERENDER_SETUP;
|
||||||
pauseCtx->mainState = PAUSE_MAIN_STATE_IDLE;
|
pauseCtx->mainState = PAUSE_MAIN_STATE_IDLE;
|
||||||
pauseCtx->unk_1EC = 0;
|
pauseCtx->unk_1EC = 0;
|
||||||
pauseCtx->state = (pauseCtx->state & 0xFFFF) + 1; // PAUSE_STATE_WAIT_BG_PRERENDER
|
pauseCtx->state = (pauseCtx->state & 0xFFFF) + 1; // PAUSE_STATE_WAIT_BG_PRERENDER
|
||||||
}
|
}
|
||||||
} else if (pauseCtx->state == PAUSE_STATE_8) {
|
} else if (pauseCtx->state == PAUSE_STATE_8) {
|
||||||
|
#if OOT_DEBUG
|
||||||
R_HREG_MODE = HREG_MODE_UCODE_DISAS;
|
R_HREG_MODE = HREG_MODE_UCODE_DISAS;
|
||||||
R_UCODE_DISAS_LOG_MODE = 3;
|
R_UCODE_DISAS_LOG_MODE = 3;
|
||||||
|
#endif
|
||||||
|
|
||||||
R_PAUSE_BG_PRERENDER_STATE = PAUSE_BG_PRERENDER_SETUP;
|
R_PAUSE_BG_PRERENDER_STATE = PAUSE_BG_PRERENDER_SETUP;
|
||||||
pauseCtx->mainState = PAUSE_MAIN_STATE_IDLE;
|
pauseCtx->mainState = PAUSE_MAIN_STATE_IDLE;
|
||||||
pauseCtx->unk_1EC = 0;
|
pauseCtx->unk_1EC = 0;
|
||||||
|
|
|
@ -20,7 +20,7 @@ void KaleidoSetup_Update(PlayState* play) {
|
||||||
(play->sceneId != SCENE_BOMBCHU_BOWLING_ALLEY || !Flags_GetSwitch(play, 0x38))) {
|
(play->sceneId != SCENE_BOMBCHU_BOWLING_ALLEY || !Flags_GetSwitch(play, 0x38))) {
|
||||||
|
|
||||||
if (CHECK_BTN_ALL(input->cur.button, BTN_L) && CHECK_BTN_ALL(input->press.button, BTN_CUP)) {
|
if (CHECK_BTN_ALL(input->cur.button, BTN_L) && CHECK_BTN_ALL(input->press.button, BTN_CUP)) {
|
||||||
if (BREG(0)) {
|
if (OOT_DEBUG && BREG(0)) {
|
||||||
pauseCtx->debugState = 3;
|
pauseCtx->debugState = 3;
|
||||||
}
|
}
|
||||||
} else if (CHECK_BTN_ALL(input->press.button, BTN_START)) {
|
} else if (CHECK_BTN_ALL(input->press.button, BTN_START)) {
|
||||||
|
@ -65,23 +65,20 @@ void KaleidoSetup_Update(PlayState* play) {
|
||||||
|
|
||||||
void KaleidoSetup_Init(PlayState* play) {
|
void KaleidoSetup_Init(PlayState* play) {
|
||||||
PauseContext* pauseCtx = &play->pauseCtx;
|
PauseContext* pauseCtx = &play->pauseCtx;
|
||||||
u64 temp = 0; // Necessary to match
|
|
||||||
|
|
||||||
pauseCtx->state = PAUSE_STATE_OFF;
|
pauseCtx->state = PAUSE_STATE_OFF;
|
||||||
pauseCtx->debugState = 0;
|
pauseCtx->debugState = 0;
|
||||||
pauseCtx->alpha = 0;
|
|
||||||
pauseCtx->unk_1EA = 0;
|
|
||||||
pauseCtx->mainState = PAUSE_MAIN_STATE_IDLE;
|
|
||||||
pauseCtx->mode = 0;
|
|
||||||
pauseCtx->pageIndex = PAUSE_ITEM;
|
|
||||||
|
|
||||||
pauseCtx->unk_1F4 = 160.0f;
|
pauseCtx->eye.x = pauseCtx->eye.y = 0.0f;
|
||||||
pauseCtx->unk_1F8 = 160.0f;
|
|
||||||
pauseCtx->unk_1FC = 160.0f;
|
|
||||||
pauseCtx->unk_200 = 160.0f;
|
|
||||||
pauseCtx->eye.z = 64.0f;
|
pauseCtx->eye.z = 64.0f;
|
||||||
pauseCtx->unk_1F0 = 936.0f;
|
pauseCtx->unk_1F0 = 936.0f;
|
||||||
pauseCtx->eye.x = pauseCtx->eye.y = 0.0f;
|
pauseCtx->unk_1F4 = pauseCtx->unk_1F8 = pauseCtx->unk_1FC = pauseCtx->unk_200 = 160.0f;
|
||||||
|
|
||||||
|
pauseCtx->alpha = 0;
|
||||||
|
|
||||||
|
// mainState = PAUSE_MAIN_STATE_IDLE , pageIndex = PAUSE_ITEM
|
||||||
|
pauseCtx->unk_1EA = pauseCtx->mainState = pauseCtx->mode = pauseCtx->pageIndex = 0;
|
||||||
|
|
||||||
pauseCtx->unk_204 = -314.0f;
|
pauseCtx->unk_204 = -314.0f;
|
||||||
|
|
||||||
pauseCtx->cursorPoint[PAUSE_ITEM] = 0;
|
pauseCtx->cursorPoint[PAUSE_ITEM] = 0;
|
||||||
|
@ -94,8 +91,8 @@ void KaleidoSetup_Init(PlayState* play) {
|
||||||
pauseCtx->cursorY[PAUSE_ITEM] = 0;
|
pauseCtx->cursorY[PAUSE_ITEM] = 0;
|
||||||
pauseCtx->cursorX[PAUSE_MAP] = 0;
|
pauseCtx->cursorX[PAUSE_MAP] = 0;
|
||||||
pauseCtx->cursorY[PAUSE_MAP] = 0;
|
pauseCtx->cursorY[PAUSE_MAP] = 0;
|
||||||
pauseCtx->cursorX[PAUSE_QUEST] = temp;
|
pauseCtx->cursorX[PAUSE_QUEST] = 0;
|
||||||
pauseCtx->cursorY[PAUSE_QUEST] = temp;
|
pauseCtx->cursorY[PAUSE_QUEST] = 0;
|
||||||
pauseCtx->cursorX[PAUSE_EQUIP] = 1;
|
pauseCtx->cursorX[PAUSE_EQUIP] = 1;
|
||||||
pauseCtx->cursorY[PAUSE_EQUIP] = 0;
|
pauseCtx->cursorY[PAUSE_EQUIP] = 0;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue