From a943633e243e3eb4668b2e3c37afffbd88eccbce Mon Sep 17 00:00:00 2001 From: Shaun Inman Date: Sat, 25 Mar 2023 08:28:48 -0400 Subject: [PATCH] fixed disappearing in-game save data --- src/minarch/minarch.c | 2 ++ todo.txt | 17 +++++++++++++++++ 2 files changed, 19 insertions(+) diff --git a/src/minarch/minarch.c b/src/minarch/minarch.c index 3d6b369..8973628 100644 --- a/src/minarch/minarch.c +++ b/src/minarch/minarch.c @@ -3019,6 +3019,7 @@ void Menu_quit(void) { SDL_FreeSurface(menu.overlay); } void Menu_beforeSleep(void) { + SRAM_write(); State_autosave(); putFile(AUTO_RESUME_PATH, game.path + strlen(SDCARD_PATH)); POW_setCPUSpeed(CPU_SPEED_MENU); @@ -3836,6 +3837,7 @@ static void Menu_loop(void) { screen = GFX_resize(SCREEN_WIDTH,SCREEN_HEIGHT,SCREEN_PITCH); } + SRAM_write(); POW_warn(0); POW_setCPUSpeed(CPU_SPEED_MENU); // set Hz directly GFX_setVsync(VSYNC_STRICT); diff --git a/todo.txt b/todo.txt index 50e16f7..01dbf9c 100644 --- a/todo.txt +++ b/todo.txt @@ -5,14 +5,20 @@ Please see the README.txt in the zip file for installation and update instructions. **Base** +- fixed mistaking bare tag name folders as empty - removed incomplete hdmi support (won't support codepaths I won't use, ergonomics are all wrong) - restored low battery overlay +- fixed disappearing in-game save data that may occur after quicksave/auto-resume **Extras** - ------------------------------- +review the original Union for workflows + for building multiple platforms + from a single make call + bugs - @@ -106,3 +112,14 @@ keymon jack instead of manually polling once a second use poll()? +tired ramblings + why did I include the extension in save names? + the rare case where one core/TAG emulate multiple platforms with games of the same name but different extension + eg. picodrive + Sonic The Hedgehog (USA, Europe).md + Sonic The Hedgehog (USA, Europe).sms + the rare case you have two versions of the same game with different extensions? + eg. ffiii.fig / ffiii.sfc / ffiii.smc + concerns about removing too much of a filename when stripping the extension and creating collisions that way? + or was it just easier to not have to remove the extension when building paths + I mean yes but taken in aggregate I think the above issues justify the decision