From c758f1ad8459aa8d2e6a3416f14a4f45c11d788d Mon Sep 17 00:00:00 2001 From: Malkierian Date: Sun, 22 Mar 2026 10:52:53 -0700 Subject: [PATCH] Add option to mute notification sounds altogether. (#6390) --- soh/soh/Notification/Notification.cpp | 2 +- soh/soh/SohGui/SohMenuSettings.cpp | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/soh/soh/Notification/Notification.cpp b/soh/soh/Notification/Notification.cpp index c70841960..5b6039cf8 100644 --- a/soh/soh/Notification/Notification.cpp +++ b/soh/soh/Notification/Notification.cpp @@ -131,7 +131,7 @@ void Emit(Options notification) { notification.remainingTime = CVarGetFloat(CVAR_SETTING("Notifications.Duration"), 10.0f); } notifications.push_back(notification); - if (!notification.mute) { + if (!notification.mute && !CVarGetInteger(CVAR_SETTING("Notifications.Mute"), 0)) { Audio_PlaySoundGeneral(NA_SE_SY_METRONOME, &gSfxDefaultPos, 4, &gSfxDefaultFreqAndVolScale, &gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb); } diff --git a/soh/soh/SohGui/SohMenuSettings.cpp b/soh/soh/SohGui/SohMenuSettings.cpp index b11dc01ce..b806da560 100644 --- a/soh/soh/SohGui/SohMenuSettings.cpp +++ b/soh/soh/SohGui/SohMenuSettings.cpp @@ -520,6 +520,10 @@ void SohMenu::AddMenuSettings() { }); }) .Options(ButtonOptions().Tooltip("Displays a test notification.")); + AddWidget(path, "Mute Notification Sound", WIDGET_CVAR_CHECKBOX) + .CVar(CVAR_SETTING("Notifications.Mute")) + .RaceDisable(false) + .Options(CheckboxOptions().Tooltip("Prevent notifications from playing a sound.")); // Mod Menu path.sidebarName = "Mod Menu";