From 1791a0c52ccf8ed885210268ca4509dd58edc904 Mon Sep 17 00:00:00 2001 From: Malkierian Date: Thu, 10 Apr 2025 06:49:21 -0700 Subject: [PATCH 1/4] Fix input viewer's first-open position calculation. (#5376) --- soh/soh/Enhancements/controls/InputViewer.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/soh/soh/Enhancements/controls/InputViewer.cpp b/soh/soh/Enhancements/controls/InputViewer.cpp index 3ae3bc1ba..1d6695d25 100644 --- a/soh/soh/Enhancements/controls/InputViewer.cpp +++ b/soh/soh/Enhancements/controls/InputViewer.cpp @@ -151,7 +151,7 @@ void InputViewer::DrawElement() { } ImVec2 mainPos = ImGui::GetWindowPos(); - ImVec2 size = ImGui::GetContentRegionAvail(); + ImVec2 size = ImGui::GetMainViewport()->WorkSize; #ifdef __WIIU__ const float scale = CVarGetFloat(CVAR_INPUT_VIEWER("Scale"), 1.0f) * 2.0f; From 9783f918d2b231c3138f3a5d83150fa79b59ad3b Mon Sep 17 00:00:00 2001 From: Malkierian Date: Thu, 10 Apr 2025 06:50:35 -0700 Subject: [PATCH 2/4] Add `ImGuiWindowFlags_NoSavedSettings` to notification windows to prevent cluttering the imgui.ini (#5380) --- soh/soh/Notification/Notification.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/soh/soh/Notification/Notification.cpp b/soh/soh/Notification/Notification.cpp index 4ba779e54..14873b068 100644 --- a/soh/soh/Notification/Notification.cpp +++ b/soh/soh/Notification/Notification.cpp @@ -61,7 +61,7 @@ void Window::Draw() { ImGuiWindowFlags_AlwaysAutoResize | ImGuiWindowFlags_NoNav | ImGuiWindowFlags_NoFocusOnAppearing | ImGuiWindowFlags_NoResize | ImGuiWindowFlags_NoDocking | ImGuiWindowFlags_NoTitleBar | ImGuiWindowFlags_NoScrollWithMouse | ImGuiWindowFlags_NoInputs | ImGuiWindowFlags_NoMove | - ImGuiWindowFlags_NoScrollbar); + ImGuiWindowFlags_NoScrollbar | ImGuiWindowFlags_NoSavedSettings); ImGui::SetWindowFontScale(CVarGetFloat(CVAR_SETTING("Notifications.Size"), 1.8f)); // Make this adjustable From a93917bb4a431485741db0c54f52e789e5ad97c0 Mon Sep 17 00:00:00 2001 From: Eric Hoey <121978037+A-Green-Spoon@users.noreply.github.com> Date: Thu, 10 Apr 2025 17:14:25 -0400 Subject: [PATCH 3/4] Fix Adult Fishing as Child Softlock (#5377) * pass a pointer not a pointer to a pointer * update GIVanillaBehavior comment * also drop this --- .../game-interactor/vanilla-behavior/GIVanillaBehavior.h | 2 +- soh/src/overlays/actors/ovl_Fishing/z_fishing.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/soh/soh/Enhancements/game-interactor/vanilla-behavior/GIVanillaBehavior.h b/soh/soh/Enhancements/game-interactor/vanilla-behavior/GIVanillaBehavior.h index 6c18a6edb..d57d5029a 100644 --- a/soh/soh/Enhancements/game-interactor/vanilla-behavior/GIVanillaBehavior.h +++ b/soh/soh/Enhancements/game-interactor/vanilla-behavior/GIVanillaBehavior.h @@ -951,7 +951,7 @@ typedef enum { // false // ``` // #### `args` - // - '*Fishing' (&this) + // - '*Fishing' VB_GIVE_RANDO_GLITCH_FISHING_PRIZE, // #### `result` diff --git a/soh/src/overlays/actors/ovl_Fishing/z_fishing.c b/soh/src/overlays/actors/ovl_Fishing/z_fishing.c index 94d7e15ca..4d42de65f 100644 --- a/soh/src/overlays/actors/ovl_Fishing/z_fishing.c +++ b/soh/src/overlays/actors/ovl_Fishing/z_fishing.c @@ -5170,7 +5170,7 @@ void Fishing_HandleOwnerDialog(Fishing* this, PlayState* play) { if (Actor_HasParent(&this->actor, play)) { this->stateAndTimer = 24; } else { - if (!GameInteractor_Should(VB_GIVE_RANDO_GLITCH_FISHING_PRIZE, false, &this)) { + if (!GameInteractor_Should(VB_GIVE_RANDO_GLITCH_FISHING_PRIZE, false, this)) { Actor_OfferGetItem(&this->actor, play, GI_SCALE_GOLDEN, 2000.0f, 1000.0f); } } From 05e96f310d28af3817369484999abda4fed2843e Mon Sep 17 00:00:00 2001 From: Christopher Leggett Date: Fri, 11 Apr 2025 10:15:31 -0400 Subject: [PATCH 4/4] Fix Fishing-related checks location pool (again) (#5378) --- soh/soh/Enhancements/randomizer/context.cpp | 2 ++ soh/soh/Enhancements/randomizer/fishsanity.cpp | 5 +---- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/soh/soh/Enhancements/randomizer/context.cpp b/soh/soh/Enhancements/randomizer/context.cpp index 4127ab21a..fa755325e 100644 --- a/soh/soh/Enhancements/randomizer/context.cpp +++ b/soh/soh/Enhancements/randomizer/context.cpp @@ -180,6 +180,8 @@ void Context::GenerateLocationPool() { location.GetRandomizerCheck() == RC_HF_DEKU_SCRUB_GROTTO)) || (location.GetRCType() == RCTYPE_ADULT_TRADE && mOptions[RSK_SHUFFLE_ADULT_TRADE].Is(RO_GENERIC_OFF)) || (location.GetRCType() == RCTYPE_COW && mOptions[RSK_SHUFFLE_COWS].Is(RO_GENERIC_OFF)) || + (location.GetRandomizerCheck() == RC_LH_HYRULE_LOACH && + mOptions[RSK_FISHSANITY].IsNot(RO_FISHSANITY_HYRULE_LOACH)) || (location.GetRCType() == RCTYPE_FISH && !mFishsanity->GetFishLocationIncluded(&location)) || (location.GetRCType() == RCTYPE_POT && mOptions[RSK_SHUFFLE_POTS].Is(RO_SHUFFLE_POTS_OFF)) || (location.GetRCType() == RCTYPE_GRASS && mOptions[RSK_SHUFFLE_GRASS].Is(RO_SHUFFLE_GRASS_OFF)) || diff --git a/soh/soh/Enhancements/randomizer/fishsanity.cpp b/soh/soh/Enhancements/randomizer/fishsanity.cpp index 8d4435f9a..99636d1a4 100644 --- a/soh/soh/Enhancements/randomizer/fishsanity.cpp +++ b/soh/soh/Enhancements/randomizer/fishsanity.cpp @@ -74,13 +74,10 @@ Fishsanity::~Fishsanity() { bool Fishsanity::GetFishLocationIncluded(Rando::Location* loc, FishsanityOptionsSource optionsSource) { auto [mode, numFish, ageSplit] = GetOptions(optionsSource); - if (loc->GetRCType() != RCTYPE_FISH || mode == RO_FISHSANITY_OFF) { + if (loc->GetRCType() != RCTYPE_FISH || mode == RO_FISHSANITY_OFF || mode == RO_FISHSANITY_HYRULE_LOACH) { return false; } RandomizerCheck rc = loc->GetRandomizerCheck(); - if (mode == RO_FISHSANITY_HYRULE_LOACH && rc != RC_LH_HYRULE_LOACH) { - return false; - } // Are pond fish enabled, and is this a pond fish location? if (mode != RO_FISHSANITY_OVERWORLD && numFish > 0 && loc->GetScene() == SCENE_FISHING_POND && loc->GetActorID() == ACTOR_FISHING) {