From 9307d8abde91d1fea518486c0eb848e9ae28db2a Mon Sep 17 00:00:00 2001 From: CraftyBoss Date: Wed, 3 Jun 2026 16:47:04 -0700 Subject: [PATCH] dont throw on failed to obtain item name, fix getTempleKeysFound not checking flag correctly --- src/dusk/imgui/ImGuiMenuRandomizer.cpp | 2 +- src/dusk/randomizer/game/tools.cpp | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/dusk/imgui/ImGuiMenuRandomizer.cpp b/src/dusk/imgui/ImGuiMenuRandomizer.cpp index 1b30b5dbcd..d5b79837a4 100644 --- a/src/dusk/imgui/ImGuiMenuRandomizer.cpp +++ b/src/dusk/imgui/ImGuiMenuRandomizer.cpp @@ -510,7 +510,7 @@ namespace dusk { LocationTrackerInfo info { .locationName = location->GetName(), .logicStr = location->GetComputedRequirement().to_string(), - .locationItem = itemId >= 0 ? world->GetItem(itemId)->GetName() : "Unknown", + .locationItem = itemId >= 0 ? world->GetItem(itemId, true)->GetName() : "Unknown", .accessible = m_currentSearch._visitedLocations.contains(location) }; diff --git a/src/dusk/randomizer/game/tools.cpp b/src/dusk/randomizer/game/tools.cpp index e235686f1b..c1b976eaff 100644 --- a/src/dusk/randomizer/game/tools.cpp +++ b/src/dusk/randomizer/game/tools.cpp @@ -168,10 +168,11 @@ int getTempleKeysFound(int stage) { }; int count = dComIfGs_getKeyNum(stage); + int saveId = getStageSaveId(stage); // Add number of unlocked key doors for this dungeon to current key count for (auto flag : keyDoorFlags[stage]) { - if (dComIfGs_isSwitch(stage, flag)) { + if (tracker_isStageSwitch(saveId, flag)) { count += 1; } }