Skip to content

Commit

Permalink
Use Everdrive style UTTD "U" save type detection
Browse files Browse the repository at this point in the history
  • Loading branch information
felixjones committed Nov 3, 2024
1 parent 6853080 commit ac6f3a3
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions src/gba/overrides.c
Original file line number Diff line number Diff line change
Expand Up @@ -432,6 +432,23 @@ void GBAOverrideApplyDefaults(struct GBA* gba, const struct Configuration* overr
GBAOverrideApply(gba, &override);
} else if (GBAOverrideFind(overrides, &override)) {
GBAOverrideApply(gba, &override);
} else {
// Apply Everdrive UTTD save detection
switch (override.id[0]) {
case '1':
override.savetype = SAVEDATA_EEPROM;
break;
case '2':
override.savetype = SAVEDATA_SRAM;
break;
case '3':
override.savetype = SAVEDATA_FLASH512;
break;
case '4':
override.savetype = SAVEDATA_FLASH1M;
break;
}
GBAOverrideApply(gba, &override);
}
}
}

0 comments on commit ac6f3a3

Please sign in to comment.