diff --git a/soh/soh/Enhancements/randomizer/3drando/menu.cpp b/soh/soh/Enhancements/randomizer/3drando/menu.cpp index adc0a9040..752984032 100644 --- a/soh/soh/Enhancements/randomizer/3drando/menu.cpp +++ b/soh/soh/Enhancements/randomizer/3drando/menu.cpp @@ -46,6 +46,7 @@ bool GenerateRandomizer(std::set excludedLocations, std::set{}(ctx->GetSettings()->GetSeedString()); ctx->GetSettings()->SetSeed(seedHash & 0xFFFFFFFF); + ctx->ClearItemLocations(); int ret = Playthrough::Playthrough_Init(ctx->GetSettings()->GetSeed(), excludedLocations, enabledTricks); if (ret < 0) { if (ret == -1) { // Failed to generate after 5 tries diff --git a/soh/soh/Enhancements/randomizer/context.cpp b/soh/soh/Enhancements/randomizer/context.cpp index 82a001024..3c3e72f35 100644 --- a/soh/soh/Enhancements/randomizer/context.cpp +++ b/soh/soh/Enhancements/randomizer/context.cpp @@ -226,6 +226,12 @@ std::vector Context::GetLocations(const std::vector(i))->ResetVariables(); + } +} + void Context::ItemReset() { for (const RandomizerCheck il : allLocations) { GetItemLocation(il)->ResetVariables(); diff --git a/soh/soh/Enhancements/randomizer/context.h b/soh/soh/Enhancements/randomizer/context.h index ccea76d98..d477ef3eb 100644 --- a/soh/soh/Enhancements/randomizer/context.h +++ b/soh/soh/Enhancements/randomizer/context.h @@ -50,6 +50,7 @@ class Context { Category categoryInclude, Category categoryExclude = Category::cNull); void AddExcludedOptions(); void LocationReset(); + void ClearItemLocations(); void ItemReset(); void HintReset(); void CreateItemOverrides();