Port Enable Cheats to the new config system

This commit is contained in:
JosJuice
2021-08-11 13:52:08 +02:00
parent 67c06cfc55
commit fa0525f826
9 changed files with 19 additions and 20 deletions

View File

@ -415,14 +415,14 @@ void Settings::ResetNetPlayServer(NetPlay::NetPlayServer* server)
bool Settings::GetCheatsEnabled() const
{
return SConfig::GetInstance().bEnableCheats;
return Config::Get(Config::MAIN_ENABLE_CHEATS);
}
void Settings::SetCheatsEnabled(bool enabled)
{
if (SConfig::GetInstance().bEnableCheats != enabled)
if (Config::Get(Config::MAIN_ENABLE_CHEATS) != enabled)
{
SConfig::GetInstance().bEnableCheats = enabled;
Config::SetBaseOrCurrent(Config::MAIN_ENABLE_CHEATS, enabled);
emit EnableCheatsChanged(enabled);
}
}