diff genesis.c @ 2623:07faf0f5466f

Add option to force use of the default region
author Michael Pavone <pavone@retrodev.com>
date Sat, 22 Feb 2025 19:52:50 -0800
parents 251cc75574af
children 6068d32b756c
line wrap: on
line diff
--- a/genesis.c	Sat Feb 22 19:29:18 2025 -0800
+++ b/genesis.c	Sat Feb 22 19:52:50 2025 -0800
@@ -1920,7 +1920,9 @@
 {
 	if (!region) {
 		char * def_region = tern_find_path_default(config, "system\0default_region\0", (tern_val){.ptrval = "U"}, TVAL_PTR).ptrval;
-		if (!info->regions || (info->regions & translate_region_char(toupper(*def_region)))) {
+		char * force_region = tern_find_path_default(config, "system\0force_region\0", (tern_val){.ptrval = "off"}, TVAL_PTR).ptrval;
+		
+		if (!info->regions || (info->regions & translate_region_char(toupper(*def_region))) || !strcmp(force_region, "on")) {
 			region = translate_region_char(toupper(*def_region));
 		} else {
 			region = info->regions;