mirror of
https://github.com/stenzek/duckstation.git
synced 2025-06-06 03:25:36 +00:00
System: Move cheat reload to Initialize()
This commit is contained in:
parent
57cb2f846e
commit
2cfc39e874
@ -1364,6 +1364,9 @@ void System::ReloadGameSettings(bool display_osd_messages)
|
||||
if (!IsValid() || !UpdateGameSettingsLayer())
|
||||
return;
|
||||
|
||||
if (!IsReplayingGPUDump())
|
||||
Cheats::ReloadCheats(false, true, false, true);
|
||||
|
||||
ApplySettings(display_osd_messages);
|
||||
}
|
||||
|
||||
@ -1508,10 +1511,6 @@ bool System::UpdateGameSettingsLayer()
|
||||
s_state.game_settings_interface = std::move(new_interface);
|
||||
|
||||
UpdateInputSettingsLayer(std::move(input_profile_name), lock);
|
||||
|
||||
if (!IsReplayingGPUDump())
|
||||
Cheats::ReloadCheats(false, true, false, true);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
@ -1928,6 +1927,9 @@ bool System::Initialize(std::unique_ptr<CDImage> disc, DiscRegion disc_region, b
|
||||
UpdateThrottlePeriod();
|
||||
UpdateMemorySaveStateSettings();
|
||||
|
||||
if (!IsReplayingGPUDump())
|
||||
Cheats::ReloadCheats(true, true, false, true);
|
||||
|
||||
PerformanceCounters::Clear();
|
||||
|
||||
return true;
|
||||
@ -4172,16 +4174,17 @@ void System::UpdateRunningGame(const std::string& path, CDImage* image, bool boo
|
||||
}
|
||||
}
|
||||
|
||||
UpdateGameSettingsLayer();
|
||||
|
||||
if (!IsReplayingGPUDump())
|
||||
{
|
||||
Achievements::GameChanged(s_state.running_game_path, image, booting);
|
||||
|
||||
// game layer reloads cheats, but only the active list, we need new files
|
||||
Cheats::ReloadCheats(true, false, false, true);
|
||||
// Cheats are loaded later in Initialize().
|
||||
if (!booting)
|
||||
Cheats::ReloadCheats(true, true, false, true);
|
||||
}
|
||||
|
||||
UpdateGameSettingsLayer();
|
||||
|
||||
ApplySettings(true);
|
||||
|
||||
if (s_state.running_game_serial != prev_serial)
|
||||
|
Loading…
x
Reference in New Issue
Block a user