ams_mitm: Implement system settings mitm

This commit is contained in:
Michael Scire
2019-11-26 20:58:39 -08:00
committed by SciresM
parent 55610694c8
commit c10ba67973
25 changed files with 655 additions and 30 deletions

View File

@@ -191,14 +191,13 @@ namespace ams::dmnt::cheat::impl {
/* Learn whether we should enable cheats by default. */
{
u64 size_out;
u8 en = 0;
if (R_SUCCEEDED(setsysGetSettingsItemValue("atmosphere", "dmnt_cheats_enabled_by_default", &en, sizeof(en), &size_out))) {
if (settings::fwdbg::GetSettingsItemValue(&en, sizeof(en), "atmosphere", "dmnt_cheats_enabled_by_default") == sizeof(en)) {
this->enable_cheats_by_default = (en != 0);
}
en = 0;
if (R_SUCCEEDED(setsysGetSettingsItemValue("atmosphere", "dmnt_always_save_cheat_toggles", &en, sizeof(en), &size_out))) {
if (settings::fwdbg::GetSettingsItemValue( &en, sizeof(en), "atmosphere", "dmnt_always_save_cheat_toggles") == sizeof(en)) {
this->always_save_cheat_toggles = (en != 0);
}
}