From e88084fe6539f0fa98a3e90055dccb8cf0407498 Mon Sep 17 00:00:00 2001 From: inspectredc <78732756+inspectredc@users.noreply.github.com> Date: Sun, 9 Jun 2024 19:43:15 +0100 Subject: [PATCH] Fix LensMode Enum Names (#1954) --- include/z64.h | 4 ++-- src/code/z_actor.c | 6 +++--- src/overlays/actors/ovl_Bg_Haka_Megane/z_bg_haka_megane.c | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/include/z64.h b/include/z64.h index 2fcf7b889c..194d95721c 100644 --- a/include/z64.h +++ b/include/z64.h @@ -225,8 +225,8 @@ typedef struct { } GameOverContext; // size = 0x2 typedef enum { - /* 0 */ LENS_MODE_HIDE_ACTORS, // lens actors are visible by default, and hidden by using lens (for example, fake walls) - /* 1 */ LENS_MODE_SHOW_ACTORS // lens actors are invisible by default, and shown by using lens (for example, invisible enemies) + /* 0 */ LENS_MODE_SHOW_ACTORS, // lens actors are invisible by default, and shown by using lens (for example, invisible enemies) + /* 1 */ LENS_MODE_HIDE_ACTORS // lens actors are visible by default, and hidden by using lens (for example, fake walls) } LensMode; typedef enum { diff --git a/src/code/z_actor.c b/src/code/z_actor.c index 214fa7138d..6afae4f1fd 100644 --- a/src/code/z_actor.c +++ b/src/code/z_actor.c @@ -2452,7 +2452,7 @@ void Actor_DrawLensActors(PlayState* play, s32 numInvisibleActors, Actor** invis gDPPipeSync(POLY_XLU_DISP++); - if (play->roomCtx.curRoom.lensMode == LENS_MODE_HIDE_ACTORS) { + if (play->roomCtx.curRoom.lensMode == LENS_MODE_SHOW_ACTORS) { // Update both the color frame buffer and the z-buffer gDPSetOtherMode(POLY_XLU_DISP++, G_AD_DISABLE | G_CD_MAGICSQ | G_CK_NONE | G_TC_FILT | G_TF_BILERP | G_TT_NONE | G_TL_TILE | @@ -2501,7 +2501,7 @@ void Actor_DrawLensActors(PlayState* play, s32 numInvisibleActors, Actor** invis // "Magic lens invisible Actor display END" gDPNoOpString(POLY_OPA_DISP++, "魔法のメガネ 見えないActor表示 END", numInvisibleActors); - if (play->roomCtx.curRoom.lensMode != LENS_MODE_HIDE_ACTORS) { + if (play->roomCtx.curRoom.lensMode != LENS_MODE_SHOW_ACTORS) { // Draw the lens overlay to the color frame buffer gDPNoOpString(POLY_OPA_DISP++, "青い眼鏡(外側)", 0); // "Blue spectacles (exterior)" @@ -2596,7 +2596,7 @@ void func_800315AC(PlayState* play, ActorContext* actorCtx) { if (!OOT_DEBUG || (HREG(64) != 1) || ((HREG(65) != -1) && (HREG(65) != HREG(66))) || (HREG(71) == 0)) { if ((actor->init == NULL) && (actor->draw != NULL) && (actor->flags & (ACTOR_FLAG_5 | ACTOR_FLAG_6))) { if ((actor->flags & ACTOR_FLAG_REACT_TO_LENS) && - ((play->roomCtx.curRoom.lensMode == LENS_MODE_HIDE_ACTORS) || play->actorCtx.lensActive || + ((play->roomCtx.curRoom.lensMode == LENS_MODE_SHOW_ACTORS) || play->actorCtx.lensActive || (actor->room != play->roomCtx.curRoom.num))) { ASSERT(invisibleActorCounter < INVISIBLE_ACTOR_MAX, "invisible_actor_counter < INVISIBLE_ACTOR_MAX", "../z_actor.c", 6464); diff --git a/src/overlays/actors/ovl_Bg_Haka_Megane/z_bg_haka_megane.c b/src/overlays/actors/ovl_Bg_Haka_Megane/z_bg_haka_megane.c index b7d3248962..39082dcb64 100644 --- a/src/overlays/actors/ovl_Bg_Haka_Megane/z_bg_haka_megane.c +++ b/src/overlays/actors/ovl_Bg_Haka_Megane/z_bg_haka_megane.c @@ -89,7 +89,7 @@ void func_8087DB24(BgHakaMegane* this, PlayState* play) { this->dyna.actor.objectSlot = this->requiredObjectSlot; this->dyna.actor.draw = BgHakaMegane_Draw; Actor_SetObjectDependency(play, &this->dyna.actor); - if (play->roomCtx.curRoom.lensMode != LENS_MODE_HIDE_ACTORS) { + if (play->roomCtx.curRoom.lensMode != LENS_MODE_SHOW_ACTORS) { CollisionHeader* colHeader; CollisionHeader* collision;