fix: read fbalpha2012 hiscore.dat from save dir

HiscoreInit opens <g_save_dir>/hiscore.dat (hiscore.cpp:411). Without
load_from the entry was packed at bios/hiscore.dat and took the slot
mame2000 reads on RetroDECK, which now gets its sha1-pinned file.
This commit is contained in:
Abdessamad Derraz committed 2026-10-21 05:11:36 +02:00
1 parent 37a5bd05ff
commit 8931d738dc
3 files changed
+19

No files matched your search

+1
View File
@@ -56,6 +56,7 @@ notes: |
files:
- name: "hiscore.dat"
description: "High score persistence database"
load_from: save_dir
required: false
system: arcade
source_ref: "svn-current/trunk/src/burn/hiscore.cpp:386-394, 411, svn-current/trunk/src/burn/burn.cpp:619"
+1
View File
@@ -54,6 +54,7 @@ notes: |
files:
- name: "hiscore.dat"
description: "High score persistence database"
load_from: save_dir
required: false
source_ref: "svn-current/trunk/src/burn/hiscore.cpp:116-118"
note: "Loaded from save directory (g_save_dir)"
+17
View File
@@ -360,5 +360,22 @@ class ClkMasterSystemBios(unittest.TestCase):
self.assertEqual(drops, {"MasterSystem/japanese-bios.sms"})
class FbAlpha2012HiscoreFromSaveDir(unittest.TestCase):
"""HiscoreInit opens <g_save_dir>/hiscore.dat in the libretro build
(svn-current/trunk/src/burn/hiscore.cpp:411 at 0ce31536, and :116 of the
CPS-3 core at 57f8015c). Read as a system file, the entry took the
bios/hiscore.dat slot that MAME cores read on RetroDECK and RetroBat."""
def test_hiscore_is_not_a_system_file(self):
from validation import read_from_system_dir
for emulator in ("fbalpha2012", "fbalpha2012_cps3"):
with self.subTest(emulator=emulator):
entry = next(
f for f in _profile(emulator)["files"] if f["name"] == "hiscore.dat"
)
self.assertFalse(read_from_system_dir(entry))
if __name__ == "__main__":
unittest.main()