summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorShishu the Dragon <183069616+ShishuTheDragon@users.noreply.github.com>2026-06-07 07:56:31 +1200
committerGitHub <noreply@github.com>2026-06-06 19:56:31 +0000
commitef014a35e62c1f2616ded73d1ebfb3644bc16969 (patch)
treea1997cabbba91b5e38e122b8d3685d72cb8a99dc
parent2d962bbb8c1edb4b8751f92193fd586f2ad349c3 (diff)
Enhancement to disable heat haze (#6663)
-rw-r--r--soh/soh/Enhancements/DisableHeatHaze.cpp8
-rw-r--r--soh/soh/Enhancements/game-interactor/vanilla-behavior/GIVanillaBehavior.h8
-rw-r--r--soh/soh/SohGui/SohMenuSettings.cpp4
-rw-r--r--soh/src/code/z_camera.c4
4 files changed, 23 insertions, 1 deletions
diff --git a/soh/soh/Enhancements/DisableHeatHaze.cpp b/soh/soh/Enhancements/DisableHeatHaze.cpp
new file mode 100644
index 000000000..0f49725cb
--- /dev/null
+++ b/soh/soh/Enhancements/DisableHeatHaze.cpp
@@ -0,0 +1,8 @@
+#include "soh/Enhancements/game-interactor/GameInteractor.h"
+#include "soh/ShipInit.hpp"
+
+void RegisterDisableHeatHaze() {
+ COND_VB_SHOULD(VB_HOT_ROOM_DISTORTION, CVarGetInteger(CVAR_SETTING("A11yNoHeatHaze"), 0), { *should = false; });
+}
+
+static RegisterShipInitFunc initFunc(RegisterDisableHeatHaze, { CVAR_SETTING("A11yNoHeatHaze") });
diff --git a/soh/soh/Enhancements/game-interactor/vanilla-behavior/GIVanillaBehavior.h b/soh/soh/Enhancements/game-interactor/vanilla-behavior/GIVanillaBehavior.h
index d1ed45341..d19a69858 100644
--- a/soh/soh/Enhancements/game-interactor/vanilla-behavior/GIVanillaBehavior.h
+++ b/soh/soh/Enhancements/game-interactor/vanilla-behavior/GIVanillaBehavior.h
@@ -1371,6 +1371,14 @@ typedef enum {
// ```
// #### `args`
// - None
+ VB_HOT_ROOM_DISTORTION,
+
+ // #### `result`
+ // ```c
+ // true
+ // ```
+ // #### `args`
+ // - None
VB_KALEIDO_UNPAUSE_CLOSE,
// #### `result`
diff --git a/soh/soh/SohGui/SohMenuSettings.cpp b/soh/soh/SohGui/SohMenuSettings.cpp
index b806da560..f37463d12 100644
--- a/soh/soh/SohGui/SohMenuSettings.cpp
+++ b/soh/soh/SohGui/SohMenuSettings.cpp
@@ -251,6 +251,10 @@ void SohMenu::AddMenuSettings() {
.CVar(CVAR_SETTING("A11yNoJabuWobble"))
.RaceDisable(false)
.Options(CheckboxOptions().Tooltip("Disable the geometry wobble and camera distortion inside Jabu."));
+ AddWidget(path, "Disable Heat Haze", WIDGET_CVAR_CHECKBOX)
+ .CVar(CVAR_SETTING("A11yNoHeatHaze"))
+ .RaceDisable(false)
+ .Options(CheckboxOptions().Tooltip("Disable the heat haze distortion effect in Death Mountain / Fire Temple."));
AddWidget(path, "EXPERIMENTAL", WIDGET_SEPARATOR_TEXT).Options(TextOptions().Color(Colors::Orange));
AddWidget(path, "ImGui Menu Scaling", WIDGET_CVAR_COMBOBOX)
.CVar(CVAR_SETTING("ImGuiScale"))
diff --git a/soh/src/code/z_camera.c b/soh/src/code/z_camera.c
index 0d30dcb2e..ff26cb436 100644
--- a/soh/src/code/z_camera.c
+++ b/soh/src/code/z_camera.c
@@ -8,6 +8,7 @@
#include "soh/frame_interpolation.h"
#include "soh/Enhancements/controls/Mouse.h"
+#include "soh/Enhancements/game-interactor/GameInteractor_Hooks.h"
s16 Camera_ChangeSettingFlags(Camera* camera, s16 setting, s16 flags);
s32 Camera_ChangeModeFlags(Camera* camera, s16 mode, u8 flags);
@@ -7363,7 +7364,8 @@ s32 Camera_UpdateWater(Camera* camera) {
s32 Camera_UpdateHotRoom(Camera* camera) {
camera->distortionFlags &= ~DISTORTION_HOT_ROOM;
- if (camera->play->roomCtx.curRoom.behaviorType2 == ROOM_BEHAVIOR_TYPE2_3) {
+ if (GameInteractor_Should(VB_HOT_ROOM_DISTORTION,
+ camera->play->roomCtx.curRoom.behaviorType2 == ROOM_BEHAVIOR_TYPE2_3)) {
camera->distortionFlags |= DISTORTION_HOT_ROOM;
}