Fix excluded location seed bleed

This commit is contained in:
aMannus
2025-10-21 20:29:35 +02:00
parent a8379cc758
commit 956188e7a5
2 changed files with 11 additions and 0 deletions

View File

@@ -438,6 +438,7 @@ void Context::ParseArchipelago() {
ParseArchipelagoItemsLocations(apClient.GetScoutedItems());
ParseArchipelagoOptions();
ParseArchipelagoTricks();
ParseArchipelagoExcludedLocations();
mEntranceShuffler->UnshuffleAllEntrances();
mDungeons->ResetAllDungeons();
mTrials->RemoveAllTrials();
@@ -758,6 +759,15 @@ void Context::ParseArchipelagoTricks() {
// See Context::ParseTricksJson for more info
}
void Context::ParseArchipelagoExcludedLocations() {
// Maybe eventually we can add locations that are excluded on AP's side.
// For now, remove all of them to prevent seed bleed from normal rando seeds.
const auto ctx = Rando::Context::GetInstance();
for (int count = 0; count < RC_MAX; count++) {
ctx->GetItemLocation(count)->SetExcludedOption(RO_GENERIC_OFF);
};
}
void Context::ParseArchipelagoItemsLocations(const std::vector<ArchipelagoClient::ApItem>& scouted_items) {
const std::string SlotName = ArchipelagoClient::GetInstance().GetSlotName();
nlohmann::json slotData = ArchipelagoClient::GetInstance().GetSlotData();

View File

@@ -139,6 +139,7 @@ class Context {
void ParseArchipelago();
void ParseArchipelagoOptions();
void ParseArchipelagoTricks();
void ParseArchipelagoExcludedLocations();
void ParseArchipelagoItemsLocations(const std::vector<ArchipelagoClient::ApItem>& slot_data);
/**