diff --git a/soh/soh/Enhancements/randomizer/3drando/fill.cpp b/soh/soh/Enhancements/randomizer/3drando/fill.cpp index c86b7eff9..269ad23c0 100644 --- a/soh/soh/Enhancements/randomizer/3drando/fill.cpp +++ b/soh/soh/Enhancements/randomizer/3drando/fill.cpp @@ -164,7 +164,7 @@ static void ApplyAllAdvancmentItems(){ static void ValidateSphereZero(GetAccessibleLocationsStruct& gals){ auto ctx = Rando::Context::GetInstance(); // Condition for verifying everything required for sphere 0, expanding search to all locations - if (logic->CanEmptyBigPoes && gals.validatedStartingRegion && gals.foundTempleOfTime && gals.haveTimeAccess) { + if (logic->CouldEmptyBigPoes && gals.validatedStartingRegion && gals.foundTempleOfTime && gals.haveTimeAccess) { // Apply all items that are necessary for checking all location access ApplyAllAdvancmentItems(); // Reset access as the non-starting age @@ -565,7 +565,7 @@ void ValidateEntrances(bool checkPoeCollectorAccess, bool checkOtherEntranceAcce ctx->allLocationsReachable = false; if (checkPoeCollectorAccess){ - logic->CanEmptyBigPoes = false; + logic->CouldEmptyBigPoes = false; } if (checkOtherEntranceAccess){ diff --git a/soh/soh/Enhancements/randomizer/location_access/overworld/market.cpp b/soh/soh/Enhancements/randomizer/location_access/overworld/market.cpp index 8a6991301..384485730 100644 --- a/soh/soh/Enhancements/randomizer/location_access/overworld/market.cpp +++ b/soh/soh/Enhancements/randomizer/location_access/overworld/market.cpp @@ -35,7 +35,8 @@ void RegionTable_Init_Market() { areaTable[RR_MARKET_GUARD_HOUSE] = Region("Market Guard House", "Market Guard House", {}, NO_DAY_NIGHT_CYCLE, { //Events - EventAccess(&logic->CanEmptyBigPoes, []{return logic->IsAdult;}), + EventAccess(&logic->CouldEmptyBigPoes, []{return logic->IsAdult;}), + EventAccess(&logic->CanEmptyBigPoes, []{return logic->IsAdult;}), }, { //Locations LOCATION(RC_MARKET_10_BIG_POES, logic->IsAdult && logic->BigPoeKill), diff --git a/soh/soh/Enhancements/randomizer/logic.cpp b/soh/soh/Enhancements/randomizer/logic.cpp index b107ea939..48b4c0623 100644 --- a/soh/soh/Enhancements/randomizer/logic.cpp +++ b/soh/soh/Enhancements/randomizer/logic.cpp @@ -880,13 +880,26 @@ namespace Rando { uint8_t Logic::BottleCount() { uint8_t count = 0; - if (!CanEmptyBigPoes){ - return 0; - } - for (int i = SLOT_BOTTLE_1; i <= SLOT_BOTTLE_4; i++) { - uint8_t item = GetSaveContext()->inventory.items[i]; - if (item != ITEM_NONE && (item != ITEM_LETTER_RUTO || (item == ITEM_LETTER_RUTO && DeliverLetter))) { - count++; + if (CouldEmptyBigPoes){ + for (int i = SLOT_BOTTLE_1; i <= SLOT_BOTTLE_4; i++) { + uint8_t item = GetSaveContext()->inventory.items[i]; + switch (item) { + case ITEM_LETTER_RUTO: + if (DeliverLetter) { + count++; + } + break; + case ITEM_BIG_POE: + if (CanEmptyBigPoes) { + count++; + } + break; + case ITEM_NONE: + break; + default: + count++; + break; + } } } return count; diff --git a/soh/soh/Enhancements/randomizer/logic.h b/soh/soh/Enhancements/randomizer/logic.h index ec4b29899..3aff99d67 100644 --- a/soh/soh/Enhancements/randomizer/logic.h +++ b/soh/soh/Enhancements/randomizer/logic.h @@ -65,7 +65,10 @@ class Logic { // Bottle Count uint8_t Bottles = 0; uint8_t NumBottles = 0; - bool CanEmptyBigPoes = true; + //this event covers if the player can currently empty big poes in logic + bool CanEmptyBigPoes = false; + //this check covers if the generation has confirmed that it's possible to empty big poes if needed as adult + bool CouldEmptyBigPoes = true; // Drops and Bottle Contents Access bool NutPot = false;