diff options
| author | Sirius902 <10891979+Sirius902@users.noreply.github.com> | 2022-07-08 20:06:11 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-07-08 23:06:11 -0400 |
| commit | 42383a1fe11dadd4fcdebae8396cc96219fb4fb8 (patch) | |
| tree | dfe4bc7dccceffc68402ee38555b48a2c45824da | |
| parent | 4371b582232ab034e2dd8b0f03ee21e3832b14ad (diff) | |
Equipment upgrade text fix and any pause slot enhancement fix (#620)
* Fix upgrade name text not rendering
* Use cvar and don't render equip help for empty item slots
* Fix rendering logic
* Fix incorrect item name rendered for one frame
* Reorder comparison
* Remove extra indent
* Remove accidental changes
| -rw-r--r-- | soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_scope_PAL.c | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_scope_PAL.c b/soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_scope_PAL.c index c126ec600..efb97f747 100644 --- a/soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_scope_PAL.c +++ b/soh/src/overlays/misc/ovl_kaleido_scope/z_kaleido_scope_PAL.c @@ -1817,13 +1817,8 @@ void KaleidoScope_DrawInfoPanel(GlobalContext* globalCtx) { } else { gDPSetPrimColor(POLY_KAL_DISP++, 0, 0, 255, 255, 255, 255); } - //TOOD CVAR - if (((CHECK_OWNED_EQUIP(pauseCtx->cursorY[PAUSE_EQUIP], pauseCtx->cursorX[PAUSE_EQUIP] - 1)) || - (pauseCtx->pageIndex != PAUSE_EQUIP) && (pauseCtx->cursorX[PAUSE_EQUIP] != 0)) && (pauseCtx->pageIndex != PAUSE_ITEM || - (gSaveContext.inventory.items[pauseCtx->cursorPoint[PAUSE_ITEM]] != ITEM_NONE))) { - POLY_KAL_DISP = KaleidoScope_QuadTextureIA4(POLY_KAL_DISP, pauseCtx->nameSegment, 128, 16, 0); - } + POLY_KAL_DISP = KaleidoScope_QuadTextureIA4(POLY_KAL_DISP, pauseCtx->nameSegment, 128, 16, 0); } if (pauseCtx->pageIndex == PAUSE_MAP && CVar_GetS32("gDebugEnabled", 0) != 0) { @@ -1929,7 +1924,7 @@ void KaleidoScope_DrawInfoPanel(GlobalContext* globalCtx) { } } } else { - if (!pauseCtx->pageIndex) { // pageIndex == PAUSE_ITEM + if (!pauseCtx->pageIndex && (!CVar_GetS32("gPauseAnyCursor", 0) || (gSaveContext.inventory.items[pauseCtx->cursorPoint[PAUSE_ITEM]] != ITEM_NONE))) { // pageIndex == PAUSE_ITEM pauseCtx->infoPanelVtx[16].v.ob[0] = pauseCtx->infoPanelVtx[18].v.ob[0] = WREG(49 + gSaveContext.language); @@ -2098,6 +2093,12 @@ void KaleidoScope_UpdateNamePanel(GlobalContext* globalCtx) { osCreateMesgQueue(&pauseCtx->loadQueue, &pauseCtx->loadMsg, 1); + if (CVar_GetS32("gPauseAnyCursor", 0) && + ((pauseCtx->pageIndex == PAUSE_EQUIP && pauseCtx->cursorX[PAUSE_EQUIP] != 0 && !CHECK_OWNED_EQUIP(pauseCtx->cursorY[PAUSE_EQUIP], pauseCtx->cursorX[PAUSE_EQUIP] - 1)) || + (pauseCtx->pageIndex == PAUSE_ITEM && gSaveContext.inventory.items[pauseCtx->cursorPoint[PAUSE_ITEM]] == ITEM_NONE))) { + pauseCtx->namedItem = PAUSE_ITEM_NONE; + } + if (pauseCtx->namedItem != PAUSE_ITEM_NONE) { if ((pauseCtx->pageIndex == PAUSE_MAP) && !sInDungeonScene) { if (gSaveContext.language) { |
