From 039ddff5a722d6312c39de0a0d290c87a4010081 Mon Sep 17 00:00:00 2001 From: aMannus Date: Sat, 6 Jan 2024 20:06:31 +0100 Subject: [PATCH] Add proper check tracker entry exclusion --- .../randomizer/randomizer_check_tracker.cpp | 31 ++++++++++++++++--- 1 file changed, 26 insertions(+), 5 deletions(-) diff --git a/soh/soh/Enhancements/randomizer/randomizer_check_tracker.cpp b/soh/soh/Enhancements/randomizer/randomizer_check_tracker.cpp index 8e4bc590a..8c85b93b8 100644 --- a/soh/soh/Enhancements/randomizer/randomizer_check_tracker.cpp +++ b/soh/soh/Enhancements/randomizer/randomizer_check_tracker.cpp @@ -64,7 +64,8 @@ bool showKokiriSword; bool showMasterSword; bool showWeirdEgg; bool showGerudoCard; -bool showPots; +bool showOverworldPots; +bool showDungeonPots; bool showFrogSongRupees; bool showStartingMapsCompasses; bool showKeysanity; @@ -1095,9 +1096,6 @@ void LoadSettings() { showGerudoCard = IS_RANDO ? OTRGlobals::Instance->gRandomizer->GetRandoSettingValue(RSK_SHUFFLE_GERUDO_MEMBERSHIP_CARD) == RO_GENERIC_YES : true; - showPots = IS_RANDO ? - OTRGlobals::Instance->gRandomizer->GetRandoSettingValue(RSK_SHUFFLE_POTS) != RO_SHUFFLE_POTS_OFF - : false; showFrogSongRupees = IS_RANDO ? OTRGlobals::Instance->gRandomizer->GetRandoSettingValue(RSK_SHUFFLE_FROG_SONG_RUPEES) == RO_GENERIC_YES : false; @@ -1147,9 +1145,30 @@ void LoadSettings() { showDungeonTokens = false; break; } + + switch (OTRGlobals::Instance->gRandomizer->GetRandoSettingValue(RSK_SHUFFLE_POTS)) { + case RO_SHUFFLE_POTS_ALL: + showOverworldPots = true; + showDungeonPots = true; + break; + case RO_SHUFFLE_POTS_OVERWORLD: + showOverworldPots = true; + showDungeonPots = false; + break; + case RO_SHUFFLE_POTS_DUNGEONS: + showOverworldPots = false; + showDungeonPots = true; + break; + default: + showOverworldPots = false; + showDungeonPots = false; + break; + } } else { // Vanilla showOverworldTokens = true; showDungeonTokens = true; + showOverworldPots = false; + showDungeonPots = false; } fortressFast = false; @@ -1198,8 +1217,10 @@ bool IsVisibleInCheckTracker(RandomizerCheck rc) { (showOverworldTokens && RandomizerCheckObjects::AreaIsOverworld(loc->GetArea())) || (showDungeonTokens && RandomizerCheckObjects::AreaIsDungeon(loc->GetArea())) ) && + (loc->GetRCType() != RCTYPE_POT || + (showOverworldPots && RandomizerCheckObjects::AreaIsOverworld(loc->GetArea())) || + (showDungeonPots && RandomizerCheckObjects::AreaIsDungeon(loc->GetArea()))) && (loc->GetRCType() != RCTYPE_COW || showCows) && - (loc->GetRCType() != RCTYPE_POT || showPots) && (loc->GetRCType() != RCTYPE_ADULT_TRADE || showAdultTrade || rc == RC_KAK_ANJU_AS_ADULT || // adult trade checks that are always shuffled