Fix save bleed bug with Silver Rupee Counts.

This commit is contained in:
Christopher Leggett 2024-04-16 20:07:44 -04:00
parent f02cb56d0c
commit 7876d9e91d
No known key found for this signature in database
GPG Key ID: 7093AE5FF7037D79
3 changed files with 7 additions and 0 deletions

View File

@ -23,6 +23,7 @@ int Playthrough_Init(uint32_t seed, std::set<RandomizerCheck> excludedLocations,
CustomMessages::ClearMessages();
ctx->ItemReset();
ctx->HintReset();
ctx->SilverRupeeReset();
ctx->GetLogic()->Reset();
Areas::AccessReset();

View File

@ -279,6 +279,11 @@ void Context::HintReset() {
}
}
void Context::SilverRupeeReset() {
mSilverRupees.reset();
mSilverRupees = std::make_shared<SilverRupees>();
}
void Context::CreateItemOverrides() {
SPDLOG_DEBUG("NOW CREATING OVERRIDES\n\n");
for (RandomizerCheck locKey : allLocations) {

View File

@ -58,6 +58,7 @@ class Context {
void ClearItemLocations();
void ItemReset();
void HintReset();
void SilverRupeeReset();
void CreateItemOverrides();
bool IsSeedGenerated() const;
void SetSeedGenerated(bool seedGenerated = true);