From 2cf3089d286b0a3cd72eee15b24e720cef0fe135 Mon Sep 17 00:00:00 2001 From: PurpleHato Date: Fri, 3 May 2024 20:25:24 +0200 Subject: [PATCH] Old cvar to new --- soh/src/code/z_actor.c | 2 +- soh/src/overlays/actors/ovl_En_Arrow/z_en_arrow.c | 2 +- soh/src/overlays/actors/ovl_En_Ba/z_en_ba.c | 2 +- soh/src/overlays/actors/ovl_En_Bigokuta/z_en_bigokuta.c | 2 +- soh/src/overlays/actors/ovl_En_Bom/z_en_bom.c | 2 +- soh/src/overlays/actors/ovl_En_Bombf/z_en_bombf.c | 2 +- soh/src/overlays/actors/ovl_En_Crow/z_en_crow.c | 6 +++--- soh/src/overlays/actors/ovl_En_Dekunuts/z_en_dekunuts.c | 2 +- soh/src/overlays/actors/ovl_En_Dh/z_en_dh.c | 2 +- soh/src/overlays/actors/ovl_En_Dha/z_en_dha.c | 2 +- soh/src/overlays/actors/ovl_En_Dodojr/z_en_dodojr.c | 2 +- soh/src/overlays/actors/ovl_En_Dodongo/z_en_dodongo.c | 4 ++-- soh/src/overlays/actors/ovl_En_Fw/z_en_fw.c | 4 ++-- soh/src/overlays/actors/ovl_En_Fz/z_en_fz.c | 4 ++-- soh/src/overlays/actors/ovl_En_GeldB/z_en_geldb.c | 2 +- soh/src/overlays/actors/ovl_En_Goma/z_en_goma.c | 2 +- soh/src/overlays/actors/ovl_En_Mb/z_en_mb.c | 2 +- .../actors/ovl_En_Okarina_Effect/z_en_okarina_effect.c | 2 +- soh/src/overlays/actors/ovl_En_Okuta/z_en_okuta.c | 2 +- soh/src/overlays/actors/ovl_En_Peehat/z_en_peehat.c | 6 +++--- .../overlays/actors/ovl_En_Po_Sisters/z_en_po_sisters.c | 2 +- soh/src/overlays/actors/ovl_En_Poh/z_en_poh.c | 2 +- soh/src/overlays/actors/ovl_En_Rr/z_en_rr.c | 8 ++++---- soh/src/overlays/actors/ovl_En_Skb/z_en_skb.c | 4 ++-- soh/src/overlays/actors/ovl_En_Sw/z_en_sw.c | 2 +- soh/src/overlays/actors/ovl_En_Test/z_en_test.c | 8 ++++---- soh/src/overlays/actors/ovl_En_Tite/z_en_tite.c | 2 +- .../overlays/actors/ovl_En_Weather_Tag/z_en_weather_tag.c | 4 ++-- soh/src/overlays/actors/ovl_En_Wf/z_en_wf.c | 4 ++-- soh/src/overlays/actors/ovl_En_Zf/z_en_zf.c | 2 +- 30 files changed, 46 insertions(+), 46 deletions(-) diff --git a/soh/src/code/z_actor.c b/soh/src/code/z_actor.c index 39870144fab..c9a797df1c6 100644 --- a/soh/src/code/z_actor.c +++ b/soh/src/code/z_actor.c @@ -3475,7 +3475,7 @@ Actor* Actor_Find(ActorContext* actorCtx, s32 actorId, s32 actorCategory) { * While the screen flashes, the game freezes. */ void Enemy_StartFinishingBlow(PlayState* play, Actor* actor) { - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { play->actorCtx.freezeFlashTimer = 5; } SoundSource_PlaySfxAtFixedWorldPos(play, &actor->world.pos, 20, NA_SE_EN_LAST_DAMAGE); diff --git a/soh/src/overlays/actors/ovl_En_Arrow/z_en_arrow.c b/soh/src/overlays/actors/ovl_En_Arrow/z_en_arrow.c index 215a22ff600..b89d25e8b86 100644 --- a/soh/src/overlays/actors/ovl_En_Arrow/z_en_arrow.c +++ b/soh/src/overlays/actors/ovl_En_Arrow/z_en_arrow.c @@ -315,7 +315,7 @@ void EnArrow_Fly(EnArrow* this, PlayState* play) { } if (this->actor.params == ARROW_NUT) { - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { iREG(50) = -1; } Actor_Spawn(&play->actorCtx, play, ACTOR_EN_M_FIRE1, this->actor.world.pos.x, diff --git a/soh/src/overlays/actors/ovl_En_Ba/z_en_ba.c b/soh/src/overlays/actors/ovl_En_Ba/z_en_ba.c index c1be800b450..cee1f027b1a 100644 --- a/soh/src/overlays/actors/ovl_En_Ba/z_en_ba.c +++ b/soh/src/overlays/actors/ovl_En_Ba/z_en_ba.c @@ -329,7 +329,7 @@ void func_809B7174(EnBa* this) { this->actor.colChkInfo.mass = MASS_IMMOVABLE; this->actor.speedXZ = 10.0f; Audio_PlayActorSound2(&this->actor, NA_SE_EN_BALINADE_HAND_DAMAGE); - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 255, 0, 12); } EnBa_SetupAction(this, EnBa_RecoilFromDamage); diff --git a/soh/src/overlays/actors/ovl_En_Bigokuta/z_en_bigokuta.c b/soh/src/overlays/actors/ovl_En_Bigokuta/z_en_bigokuta.c index 3659f22b120..0e91e0a238d 100644 --- a/soh/src/overlays/actors/ovl_En_Bigokuta/z_en_bigokuta.c +++ b/soh/src/overlays/actors/ovl_En_Bigokuta/z_en_bigokuta.c @@ -353,7 +353,7 @@ void func_809BD5E0(EnBigokuta* this) { this->unk_196 = 24; this->unk_19A = 0; this->cylinder[0].base.atFlags &= ~AT_ON; - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 255, 0, 24); } this->actionFunc = func_809BE180; diff --git a/soh/src/overlays/actors/ovl_En_Bom/z_en_bom.c b/soh/src/overlays/actors/ovl_En_Bom/z_en_bom.c index 35145510f81..03ffdbd33d3 100644 --- a/soh/src/overlays/actors/ovl_En_Bom/z_en_bom.c +++ b/soh/src/overlays/actors/ovl_En_Bom/z_en_bom.c @@ -321,7 +321,7 @@ void EnBom_Update(Actor* thisx, PlayState* play2) { } if ((this->timer < 100) && ((this->timer & (this->flashSpeedScale + 1)) != 0)) { - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Math_SmoothStepToF(&this->flashIntensity, 140.0f, 1.0f, 140.0f / this->flashSpeedScale, 0.0f); } else { Math_SmoothStepToF(&this->flashIntensity, 40.0f, 1.0f, 40.0f / this->flashSpeedScale, 0.0f); diff --git a/soh/src/overlays/actors/ovl_En_Bombf/z_en_bombf.c b/soh/src/overlays/actors/ovl_En_Bombf/z_en_bombf.c index de3362514cf..d695503116a 100644 --- a/soh/src/overlays/actors/ovl_En_Bombf/z_en_bombf.c +++ b/soh/src/overlays/actors/ovl_En_Bombf/z_en_bombf.c @@ -397,7 +397,7 @@ void EnBombf_Update(Actor* thisx, PlayState* play) { } if ((this->timer < 100) && ((this->timer & (this->flashSpeedScale + 1)) != 0)) { - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Math_SmoothStepToF(&this->flashIntensity, 150.0f, 1.0f, 150.0f / this->flashSpeedScale, 0.0f); } else { Math_SmoothStepToF(&this->flashIntensity, 50.0f, 1.0f, 50.0f / this->flashSpeedScale, 0.0f); diff --git a/soh/src/overlays/actors/ovl_En_Crow/z_en_crow.c b/soh/src/overlays/actors/ovl_En_Crow/z_en_crow.c index 6d84194f5f1..c9e4160b8b8 100644 --- a/soh/src/overlays/actors/ovl_En_Crow/z_en_crow.c +++ b/soh/src/overlays/actors/ovl_En_Crow/z_en_crow.c @@ -161,7 +161,7 @@ void EnCrow_SetupDamaged(EnCrow* this, PlayState* play) { Audio_PlayActorSound2(&this->actor, NA_SE_EN_KAICHO_DEAD); if (this->actor.colChkInfo.damageEffect == 3) { // Ice arrows - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0, 255, 0, 40); } for (i = 0; i < 8; i++) { @@ -172,7 +172,7 @@ void EnCrow_SetupDamaged(EnCrow* this, PlayState* play) { ((Rand_ZeroOne() * 0.15f) + 0.85f) * scale); } } else if (this->actor.colChkInfo.damageEffect == 2) { // Fire arrows and Din's Fire - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 255, 0, 40); } @@ -180,7 +180,7 @@ void EnCrow_SetupDamaged(EnCrow* this, PlayState* play) { EffectSsEnFire_SpawnVec3f(play, &this->actor, &this->actor.world.pos, 50.0f * scale, 0, 0, i); } } else { - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 255, 0, 40); } } diff --git a/soh/src/overlays/actors/ovl_En_Dekunuts/z_en_dekunuts.c b/soh/src/overlays/actors/ovl_En_Dekunuts/z_en_dekunuts.c index 6444b832bb4..e0faaefaa43 100644 --- a/soh/src/overlays/actors/ovl_En_Dekunuts/z_en_dekunuts.c +++ b/soh/src/overlays/actors/ovl_En_Dekunuts/z_en_dekunuts.c @@ -218,7 +218,7 @@ void EnDekunuts_SetupBeDamaged(EnDekunuts* this) { this->actor.speedXZ = 10.0f; Audio_PlayActorSound2(&this->actor, NA_SE_EN_NUTS_DAMAGE); Audio_PlayActorSound2(&this->actor, NA_SE_EN_NUTS_CUTBODY); - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, Animation_GetLastFrame(&gDekuNutsDamageAnim)); } else { Actor_SetColorFilter(&this->actor, 0, 0, 0, Animation_GetLastFrame(&gDekuNutsDamageAnim)); diff --git a/soh/src/overlays/actors/ovl_En_Dh/z_en_dh.c b/soh/src/overlays/actors/ovl_En_Dh/z_en_dh.c index 5c4d218887f..5b9b75dd0b5 100644 --- a/soh/src/overlays/actors/ovl_En_Dh/z_en_dh.c +++ b/soh/src/overlays/actors/ovl_En_Dh/z_en_dh.c @@ -485,7 +485,7 @@ void EnDh_CollisionCheck(EnDh* this, PlayState* play) { if (player->unk_844 != 0) { this->unk_258 = player->unk_845; } - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 8); } lastHealth = this->actor.colChkInfo.health; diff --git a/soh/src/overlays/actors/ovl_En_Dha/z_en_dha.c b/soh/src/overlays/actors/ovl_En_Dha/z_en_dha.c index 503a54cf377..9fd25f86218 100644 --- a/soh/src/overlays/actors/ovl_En_Dha/z_en_dha.c +++ b/soh/src/overlays/actors/ovl_En_Dha/z_en_dha.c @@ -386,7 +386,7 @@ void EnDha_UpdateHealth(EnDha* this, PlayState* play) { if (this->actor.colChkInfo.damageEffect == 0 || this->actor.colChkInfo.damageEffect == 6) { return; } else { - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 8); } if (Actor_ApplyDamage(&this->actor) == 0) { diff --git a/soh/src/overlays/actors/ovl_En_Dodojr/z_en_dodojr.c b/soh/src/overlays/actors/ovl_En_Dodojr/z_en_dodojr.c index 106af7367a3..a7fa3ab6226 100644 --- a/soh/src/overlays/actors/ovl_En_Dodojr/z_en_dodojr.c +++ b/soh/src/overlays/actors/ovl_En_Dodojr/z_en_dodojr.c @@ -579,7 +579,7 @@ void func_809F7B3C(EnDodojr* this, PlayState* play) { if (this->unk_1FC != 0) { if (this->actor.colorFilterTimer == 0) { - if (CVar_GetS32("gPhotosensitiveMode", 0)) { + if (CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 0, 0, 0); // Note: the explosion timer is also related to their blinking... } else { Actor_SetColorFilter(&this->actor, 0x4000, 200, 0, this->unk_1FC); diff --git a/soh/src/overlays/actors/ovl_En_Dodongo/z_en_dodongo.c b/soh/src/overlays/actors/ovl_En_Dodongo/z_en_dodongo.c index 131d373f78d..32fbf31c2a8 100644 --- a/soh/src/overlays/actors/ovl_En_Dodongo/z_en_dodongo.c +++ b/soh/src/overlays/actors/ovl_En_Dodongo/z_en_dodongo.c @@ -680,7 +680,7 @@ void EnDodongo_Death(EnDodongo* this, PlayState* play) { EnDodongo_SpawnBombSmoke(this, play); } } else if (this->actor.colorFilterTimer == 0) { - if (CVar_GetS32("gPhotosensitiveMode", 0)) { + if (CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 0, 0, 0); // Note: the explosion timer is also related to their blinking... } else { Actor_SetColorFilter(&this->actor, 0x4000, 0x78, 0, 4); @@ -734,7 +734,7 @@ void EnDodongo_CollisionCheck(EnDodongo* this, PlayState* play) { EnDodongo_SetupStunned(this); } } else { - if (CVar_GetS32("gPhotosensitiveMode", 0)) { + if (CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 0x78, 0, 8); } if (Actor_ApplyDamage(&this->actor) == 0) { diff --git a/soh/src/overlays/actors/ovl_En_Fw/z_en_fw.c b/soh/src/overlays/actors/ovl_En_Fw/z_en_fw.c index b9a38b1c316..5f759a5299a 100644 --- a/soh/src/overlays/actors/ovl_En_Fw/z_en_fw.c +++ b/soh/src/overlays/actors/ovl_En_Fw/z_en_fw.c @@ -254,7 +254,7 @@ void EnFw_Run(EnFw* this, PlayState* play) { Math_SmoothStepToF(&this->actor.scale.x, 0.024999999f, 0.08f, 0.6f, 0.0f); Actor_SetScale(&this->actor, this->actor.scale.x); if (this->actor.colorFilterTimer == 0) { - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 0xC8, 0, this->explosionTimer); } else { Actor_SetColorFilter(&this->actor, 0, 0, 0, this->explosionTimer); // Note: the explosion timer is also related to their blinking... @@ -276,7 +276,7 @@ void EnFw_Run(EnFw* this, PlayState* play) { } } else { if (!(this->actor.bgCheckFlags & 1) || this->actor.velocity.y > 0.0f) { - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 0xC8, 0, this->damageTimer); } else { Actor_SetColorFilter(&this->actor, 0, 0, 0, this->damageTimer); // Note: the damage timer is also related to their blinking... diff --git a/soh/src/overlays/actors/ovl_En_Fz/z_en_fz.c b/soh/src/overlays/actors/ovl_En_Fz/z_en_fz.c index 087b32f7ca4..654d8db18fb 100644 --- a/soh/src/overlays/actors/ovl_En_Fz/z_en_fz.c +++ b/soh/src/overlays/actors/ovl_En_Fz/z_en_fz.c @@ -348,7 +348,7 @@ void EnFz_ApplyDamage(EnFz* this, PlayState* play) { if (this->actor.colChkInfo.damageEffect != 2) { if (this->actor.colChkInfo.damageEffect == 0xF) { Actor_ApplyDamage(&this->actor); - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0x2000, 8); } if (this->actor.colChkInfo.health) { @@ -371,7 +371,7 @@ void EnFz_ApplyDamage(EnFz* this, PlayState* play) { } } else { Actor_ApplyDamage(&this->actor); - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0x2000, 8); } if (this->actor.colChkInfo.health == 0) { diff --git a/soh/src/overlays/actors/ovl_En_GeldB/z_en_geldb.c b/soh/src/overlays/actors/ovl_En_GeldB/z_en_geldb.c index 392461aafd3..34ed8a5176d 100644 --- a/soh/src/overlays/actors/ovl_En_GeldB/z_en_geldb.c +++ b/soh/src/overlays/actors/ovl_En_GeldB/z_en_geldb.c @@ -1376,7 +1376,7 @@ void EnGeldB_CollisionCheck(EnGeldB* this, PlayState* play) { EnGeldB_SetupStunned(this); } } else { - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 8); } if (Actor_ApplyDamage(&this->actor) == 0) { diff --git a/soh/src/overlays/actors/ovl_En_Goma/z_en_goma.c b/soh/src/overlays/actors/ovl_En_Goma/z_en_goma.c index c269d3016ee..7598b0c74e7 100644 --- a/soh/src/overlays/actors/ovl_En_Goma/z_en_goma.c +++ b/soh/src/overlays/actors/ovl_En_Goma/z_en_goma.c @@ -658,7 +658,7 @@ void EnGoma_UpdateHit(EnGoma* this, PlayState* play) { this->actor.colChkInfo.health -= swordDamage; EnGoma_SetupHurt(this, play); - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 255, 0, 5); } diff --git a/soh/src/overlays/actors/ovl_En_Mb/z_en_mb.c b/soh/src/overlays/actors/ovl_En_Mb/z_en_mb.c index 1ffbceac732..9346b4e1b5a 100644 --- a/soh/src/overlays/actors/ovl_En_Mb/z_en_mb.c +++ b/soh/src/overlays/actors/ovl_En_Mb/z_en_mb.c @@ -1439,7 +1439,7 @@ void EnMb_CheckColliding(EnMb* this, PlayState* play) { } } else { Actor_ApplyDamage(&this->actor); - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 0xFA, 0, 0xC); } if (this->actor.params == ENMB_TYPE_CLUB) { diff --git a/soh/src/overlays/actors/ovl_En_Okarina_Effect/z_en_okarina_effect.c b/soh/src/overlays/actors/ovl_En_Okarina_Effect/z_en_okarina_effect.c index 542f4df0e87..573344ad147 100644 --- a/soh/src/overlays/actors/ovl_En_Okarina_Effect/z_en_okarina_effect.c +++ b/soh/src/overlays/actors/ovl_En_Okarina_Effect/z_en_okarina_effect.c @@ -64,7 +64,7 @@ void EnOkarinaEffect_TriggerStorm(EnOkarinaEffect* this, PlayState* play) { if ((gWeatherMode != 0) || play->envCtx.unk_17 != 0) { play->envCtx.unk_DE = 1; } - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { play->envCtx.lightningMode = LIGHTNING_MODE_ON; } Environment_PlayStormNatureAmbience(play); diff --git a/soh/src/overlays/actors/ovl_En_Okuta/z_en_okuta.c b/soh/src/overlays/actors/ovl_En_Okuta/z_en_okuta.c index 5163ce71cdf..56fdf1c71b9 100644 --- a/soh/src/overlays/actors/ovl_En_Okuta/z_en_okuta.c +++ b/soh/src/overlays/actors/ovl_En_Okuta/z_en_okuta.c @@ -247,7 +247,7 @@ void EnOkuta_SetupShoot(EnOkuta* this, PlayState* play) { void EnOkuta_SetupWaitToDie(EnOkuta* this) { Animation_MorphToPlayOnce(&this->skelAnime, &gOctorokHitAnim, -5.0f); - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 0xB); } this->collider.base.acFlags &= ~AC_HIT; diff --git a/soh/src/overlays/actors/ovl_En_Peehat/z_en_peehat.c b/soh/src/overlays/actors/ovl_En_Peehat/z_en_peehat.c index 4818864fd03..89e654786db 100644 --- a/soh/src/overlays/actors/ovl_En_Peehat/z_en_peehat.c +++ b/soh/src/overlays/actors/ovl_En_Peehat/z_en_peehat.c @@ -801,7 +801,7 @@ void EnPeehat_Adult_SetStateDie(EnPeehat* this) { this->bladeRotVel = 0; this->isStateDieFirstUpdate = 1; this->actor.speedXZ = 0.0f; - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 255, 0, 8); } this->state = PEAHAT_STATE_DYING; @@ -909,7 +909,7 @@ void EnPeehat_Adult_CollisionCheck(EnPeehat* this, PlayState* play) { return; } else { Actor_ApplyDamage(&this->actor); - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 255, 0, 8); } Audio_PlayActorSound2(&this->actor, NA_SE_EN_PIHAT_DAMAGE); @@ -924,7 +924,7 @@ void EnPeehat_Adult_CollisionCheck(EnPeehat* this, PlayState* play) { pos.z = Rand_CenteredFloat(20.0f) + this->actor.world.pos.z; EffectSsEnFire_SpawnVec3f(play, &this->actor, &pos, 70, 0, 0, -1); } - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 200, 0, 100); } } diff --git a/soh/src/overlays/actors/ovl_En_Po_Sisters/z_en_po_sisters.c b/soh/src/overlays/actors/ovl_En_Po_Sisters/z_en_po_sisters.c index 1ca94cb26e3..8c7a5d3241b 100644 --- a/soh/src/overlays/actors/ovl_En_Po_Sisters/z_en_po_sisters.c +++ b/soh/src/overlays/actors/ovl_En_Po_Sisters/z_en_po_sisters.c @@ -322,7 +322,7 @@ void func_80AD95D8(EnPoSisters* this) { this->actor.speedXZ = 10.0f; } this->unk_199 &= ~0xB; - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 0x10); } this->actionFunc = func_80ADAAA4; diff --git a/soh/src/overlays/actors/ovl_En_Poh/z_en_poh.c b/soh/src/overlays/actors/ovl_En_Poh/z_en_poh.c index 40ac8a30b0d..5b96a82aaa7 100644 --- a/soh/src/overlays/actors/ovl_En_Poh/z_en_poh.c +++ b/soh/src/overlays/actors/ovl_En_Poh/z_en_poh.c @@ -304,7 +304,7 @@ void func_80ADE28C(EnPoh* this) { } this->colliderCyl.base.acFlags &= ~AC_ON; this->actor.speedXZ = 5.0f; - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 0x10); } this->actionFunc = func_80ADEECC; diff --git a/soh/src/overlays/actors/ovl_En_Rr/z_en_rr.c b/soh/src/overlays/actors/ovl_En_Rr/z_en_rr.c index dd22230f291..6a2335e0aad 100644 --- a/soh/src/overlays/actors/ovl_En_Rr/z_en_rr.c +++ b/soh/src/overlays/actors/ovl_En_Rr/z_en_rr.c @@ -453,7 +453,7 @@ void EnRr_CollisionCheck(EnRr* this, PlayState* play) { this->stopScroll = false; Actor_ApplyDamage(&this->actor); this->invincibilityTimer = 40; - if (CVar_GetS32("gPhotosensitiveMode", 0)) { + if (CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0x2000, this->invincibilityTimer); } else { Actor_SetColorFilter(&this->actor, 0, 0, 0, this->invincibilityTimer); @@ -472,7 +472,7 @@ void EnRr_CollisionCheck(EnRr* this, PlayState* play) { if (this->actor.colChkInfo.health == 0) { this->dropType = RR_DROP_RANDOM_RUPEE; } - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0x2000, 0x50); } this->effectTimer = 20; @@ -485,7 +485,7 @@ void EnRr_CollisionCheck(EnRr* this, PlayState* play) { } if (this->actor.colorFilterTimer == 0) { this->effectTimer = 20; - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0, 0xFF, 0x2000, 0x50); } } @@ -496,7 +496,7 @@ void EnRr_CollisionCheck(EnRr* this, PlayState* play) { if (this->actor.colChkInfo.health == 0) { this->dropType = RR_DROP_RUPEE_RED; } - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, -0x8000, 0xFF, 0x2000, 0x50); } EnRr_SetupStunned(this); diff --git a/soh/src/overlays/actors/ovl_En_Skb/z_en_skb.c b/soh/src/overlays/actors/ovl_En_Skb/z_en_skb.c index a341f8d5bc2..535bcc8eda3 100644 --- a/soh/src/overlays/actors/ovl_En_Skb/z_en_skb.c +++ b/soh/src/overlays/actors/ovl_En_Skb/z_en_skb.c @@ -458,7 +458,7 @@ void func_80AFD968(EnSkb* this, PlayState* play) { this->unk_281 = 0; if (this->actor.colChkInfo.damageEffect == 1) { if (this->unk_280 != 6) { - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0, 0x78, 0, 0x50); } Actor_ApplyDamage(&this->actor); @@ -477,7 +477,7 @@ void func_80AFD968(EnSkb* this, PlayState* play) { } phi_v1 = 25; } - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, phi_v1); } if (!Actor_ApplyDamage(&this->actor)) { diff --git a/soh/src/overlays/actors/ovl_En_Sw/z_en_sw.c b/soh/src/overlays/actors/ovl_En_Sw/z_en_sw.c index b16977b0bf8..d71b32a210b 100644 --- a/soh/src/overlays/actors/ovl_En_Sw/z_en_sw.c +++ b/soh/src/overlays/actors/ovl_En_Sw/z_en_sw.c @@ -347,7 +347,7 @@ s32 func_80B0C9F0(EnSw* this, PlayState* play) { if ((this->collider.base.acFlags & 2) || phi_v1) { this->collider.base.acFlags &= ~2; this->unk_392 = 0x10; - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 0xC8, 0, this->unk_392); } diff --git a/soh/src/overlays/actors/ovl_En_Test/z_en_test.c b/soh/src/overlays/actors/ovl_En_Test/z_en_test.c index d6457460ea5..40a9fc9392f 100644 --- a/soh/src/overlays/actors/ovl_En_Test/z_en_test.c +++ b/soh/src/overlays/actors/ovl_En_Test/z_en_test.c @@ -1215,7 +1215,7 @@ void func_80862154(EnTest* this) { Audio_PlayActorSound2(&this->actor, NA_SE_EN_STAL_DAMAGE); this->unk_7C8 = 8; this->actor.speedXZ = -2.0f; - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 8); } EnTest_SetupAction(this, func_808621D4); @@ -1259,7 +1259,7 @@ void func_80862398(EnTest* this) { Audio_PlayActorSound2(&this->actor, NA_SE_EN_STAL_DAMAGE); this->unk_7C8 = 9; this->actor.speedXZ = -2.0f; - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 0xFF, 0, 8); } EnTest_SetupAction(this, func_80862418); @@ -1303,11 +1303,11 @@ void EnTest_SetupStunned(EnTest* this) { this->actor.speedXZ = -4.0f; if (this->lastDamageEffect == STALFOS_DMGEFF_LIGHT) { - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, -0x8000, 0x78, 0, 0x50); } } else { - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0, 0x78, 0, 0x50); } diff --git a/soh/src/overlays/actors/ovl_En_Tite/z_en_tite.c b/soh/src/overlays/actors/ovl_En_Tite/z_en_tite.c index 26b9f3a99e7..4a075d94ce4 100644 --- a/soh/src/overlays/actors/ovl_En_Tite/z_en_tite.c +++ b/soh/src/overlays/actors/ovl_En_Tite/z_en_tite.c @@ -861,7 +861,7 @@ void EnTite_CheckDamage(Actor* thisx, PlayState* play) { // Otherwise apply damage and handle death where necessary } else { if ((thisx->colorFilterTimer == 0) || ((thisx->colorFilterParams & 0x4000) == 0)) { - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(thisx, 0x4000, 0xFF, 0, 8); } Actor_ApplyDamage(thisx); diff --git a/soh/src/overlays/actors/ovl_En_Weather_Tag/z_en_weather_tag.c b/soh/src/overlays/actors/ovl_En_Weather_Tag/z_en_weather_tag.c index 9e290e69753..e0412703167 100644 --- a/soh/src/overlays/actors/ovl_En_Weather_Tag/z_en_weather_tag.c +++ b/soh/src/overlays/actors/ovl_En_Weather_Tag/z_en_weather_tag.c @@ -271,7 +271,7 @@ void EnWeatherTag_EnabledRainLakeHylia(EnWeatherTag* this, PlayState* play) { void EnWeatherTag_DisabledCloudyRainThunderKakariko(EnWeatherTag* this, PlayState* play) { if (WeatherTag_CheckEnableWeatherEffect(this, play, 0, 1, 0, 4, 100, 5)) { Environment_PlayStormNatureAmbience(play); - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { play->envCtx.lightningMode = LIGHTNING_MODE_ON; } play->envCtx.unk_EE[0] = 30; @@ -305,7 +305,7 @@ void EnWeatherTag_DisabledRainThunder(EnWeatherTag* this, PlayState* play) { if (Actor_WorldDistXZToActor(&player->actor, &this->actor) < WEATHER_TAG_RANGE100(this->actor.params)) { Environment_PlayStormNatureAmbience(play); - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { play->envCtx.lightningMode = LIGHTNING_MODE_ON; } play->envCtx.unk_EE[0] = 25; diff --git a/soh/src/overlays/actors/ovl_En_Wf/z_en_wf.c b/soh/src/overlays/actors/ovl_En_Wf/z_en_wf.c index 93238ad042c..80ad1a665b2 100644 --- a/soh/src/overlays/actors/ovl_En_Wf/z_en_wf.c +++ b/soh/src/overlays/actors/ovl_En_Wf/z_en_wf.c @@ -1276,14 +1276,14 @@ void EnWf_UpdateDamage(EnWf* this, PlayState* play) { if ((this->actor.colChkInfo.damageEffect == ENWF_DMGEFF_STUN) || (this->actor.colChkInfo.damageEffect == ENWF_DMGEFF_UNDEF)) { if (this->action != WOLFOS_ACTION_STUNNED) { - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0, 120, 0, 80); } Actor_ApplyDamage(&this->actor); EnWf_SetupStunned(this); } } else { // LIGHT_MAGIC, FIRE, NONE - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 255, 0, 8); } diff --git a/soh/src/overlays/actors/ovl_En_Zf/z_en_zf.c b/soh/src/overlays/actors/ovl_En_Zf/z_en_zf.c index 5e5e7663fec..15109822d95 100644 --- a/soh/src/overlays/actors/ovl_En_Zf/z_en_zf.c +++ b/soh/src/overlays/actors/ovl_En_Zf/z_en_zf.c @@ -2001,7 +2001,7 @@ void EnZf_UpdateDamage(EnZf* this, PlayState* play) { } } else { Audio_PlayActorSound2(&this->actor, NA_SE_EN_RIZA_CRY); - if (!CVar_GetS32("gPhotosensitiveMode", 0)) { + if (!CVarGetInteger("gPhotosensitiveMode", 0)) { Actor_SetColorFilter(&this->actor, 0x4000, 255, 0, 8); }