From fd696b5e52f0e471f03938e9d9d5b79ab18b9eb8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Philip=20Dub=C3=A9?= <159546+serprex@users.noreply.github.com> Date: Mon, 22 Jun 2026 05:08:49 +0000 Subject: [PATCH] Fix ganondorf hint (#6789) Location indexes need to be aligned, so rather than try erase them, just avoid RC_UNKNOWN_CHECK crash by stubbing it to "an isolated place" --- soh/soh/Enhancements/randomizer/3drando/hints.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/soh/soh/Enhancements/randomizer/3drando/hints.cpp b/soh/soh/Enhancements/randomizer/3drando/hints.cpp index 6330b1193e..99ab971e52 100644 --- a/soh/soh/Enhancements/randomizer/3drando/hints.cpp +++ b/soh/soh/Enhancements/randomizer/3drando/hints.cpp @@ -757,12 +757,10 @@ void CreateStaticItemHint(RandomizerHint hintKey, std::vector locations = FindItemsAndMarkHinted(items, hintChecks); - locations.erase( - std::remove_if(locations.begin(), locations.end(), [](const auto rc) { return rc == RC_UNKNOWN_CHECK; })); std::vector areas; areas.reserve(locations.size()); for (auto loc : locations) { - areas.push_back(ctx->GetItemLocation(loc)->GetRandomArea()); + areas.push_back(loc == RC_UNKNOWN_CHECK ? RA_NONE : ctx->GetItemLocation(loc)->GetRandomArea()); } ctx->AddHint(hintKey, Hint(hintKey, HINT_TYPE_AREA, hintTextKeys, locations, areas, {}, yourPocket)); }