From fe6397c88c43f1b8a0791fb9ffe01f067b094798 Mon Sep 17 00:00:00 2001 From: Gymnasiast Date: Fri, 20 Sep 2024 20:42:35 +0200 Subject: [PATCH] Revert "Fix #22672: Loud sound effects on title screen" This reverts commit 4d2efa0edcffa89c21247219c0fd37d3c59c0c3e. --- src/openrct2-ui/windows/Main.cpp | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/src/openrct2-ui/windows/Main.cpp b/src/openrct2-ui/windows/Main.cpp index 6a725988e0..343d342028 100644 --- a/src/openrct2-ui/windows/Main.cpp +++ b/src/openrct2-ui/windows/Main.cpp @@ -36,9 +36,9 @@ namespace OpenRCT2::Ui::Windows widgets = _mainWidgets; ViewportCreate(this, windowPos, width, height, Focus(CoordsXYZ(0x0FFF, 0x0FFF, 0))); - if (viewport != nullptr) + if (viewport != nullptr && !(gScreenFlags & SCREEN_FLAGS_TITLE_DEMO)) { - SetViewportFlags(gScreenFlags & SCREEN_FLAGS_TITLE_DEMO); + SetViewportFlags(); viewport->rotation = 0; } gShowGridLinesRefCount = 0; @@ -53,14 +53,9 @@ namespace OpenRCT2::Ui::Windows } private: - void SetViewportFlags(bool isTitleWindow) + void SetViewportFlags() { viewport->flags |= VIEWPORT_FLAG_SOUND_ON; - if (isTitleWindow) - { - return; - } - if (Config::Get().general.InvisibleRides) { viewport->flags |= VIEWPORT_FLAG_INVISIBLE_RIDES;