aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorneonloop2021-08-28 17:11:29 +0000
committerneonloop2021-08-28 17:11:29 +0000
commitaa7a05f54990d7f1c4733885424303533421ade8 (patch)
treee5ca3240ec50ce84930f4596174e00266dcc4a7a
parentff09bde3b0ba9de1068f29b9d0dc2f9f437cae88 (diff)
downloadpicoarch-aa7a05f54990d7f1c4733885424303533421ade8.tar.gz
picoarch-aa7a05f54990d7f1c4733885424303533421ade8.tar.bz2
picoarch-aa7a05f54990d7f1c4733885424303533421ade8.zip
Fixes config override detection after loading new game
-rw-r--r--core.c3
-rw-r--r--main.c1
-rw-r--r--overrides/gambatte.h3
3 files changed, 3 insertions, 4 deletions
diff --git a/core.c b/core.c
index 1a92c28..500145b 100644
--- a/core.c
+++ b/core.c
@@ -710,6 +710,8 @@ finish:
}
void core_unload_content(void) {
+ sram_write();
+
current_core.retro_unload_game();
if (temp_rom[0]) {
remove(temp_rom);
@@ -729,7 +731,6 @@ void core_unload(void) {
PA_INFO("Unloading core...\n");
if (current_core.initialized) {
- sram_write();
core_unload_content();
current_core.retro_deinit();
current_core.initialized = false;
diff --git a/main.c b/main.c
index d5091a6..c1df689 100644
--- a/main.c
+++ b/main.c
@@ -240,6 +240,7 @@ static void alloc_config_buffer(char **config_ptr) {
char config_filename[MAX_PATH];
FILE *config_file;
size_t length;
+ config_override = 0;
config_file_name(config_filename, MAX_PATH, 1);
config_file = fopen(config_filename, "rb");
diff --git a/overrides/gambatte.h b/overrides/gambatte.h
index 7803760..1482d27 100644
--- a/overrides/gambatte.h
+++ b/overrides/gambatte.h
@@ -294,9 +294,6 @@ me_bind_action gambatte_ctrl_actions[] =
{ "B TURBO ", 1 << RETRO_DEVICE_ID_JOYPAD_Y },
{ "START ", 1 << RETRO_DEVICE_ID_JOYPAD_START },
{ "SELECT ", 1 << RETRO_DEVICE_ID_JOYPAD_SELECT },
- { "L BUTTON ", 1 << RETRO_DEVICE_ID_JOYPAD_L },
- { "R BUTTON ", 1 << RETRO_DEVICE_ID_JOYPAD_R },
- /* { "FAST FWD ", 1 << RETRO_DEVICE_ID_JOYPAD_R2 }, */
{ NULL, 0 }
};