[#1715] Fix crash when retrieving a merchant message while using fast file select (#1722)

This commit is contained in:
Garrett Cox 2022-10-10 02:40:52 -05:00 committed by GitHub
parent aa00cba76e
commit fd3872ae30
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 0 deletions

View File

@ -99,6 +99,7 @@ void SaveManager::LoadRandomizerVersion1() {
std::shared_ptr<Randomizer> randomizer = OTRGlobals::Instance->gRandomizer;
randomizer->LoadRandomizerSettings("");
size_t merchantPricesSize = 0;
if (randomizer->GetRandoSettingValue(RSK_SHUFFLE_SCRUBS) > 0) {
merchantPricesSize += NUM_SCRUBS;

View File

@ -307,6 +307,7 @@ void Title_Init(GameState* thisx) {
Randomizer_LoadSettings("");
Randomizer_LoadHintLocations("");
Randomizer_LoadItemLocations("", true);
Randomizer_LoadMerchantMessages("");
gSaveContext.gameMode = 0;
gSaveContext.magic = gSaveContext.magic;
SET_NEXT_GAMESTATE(&this->state, Gameplay_Init, GlobalContext);