emulators.arcade_cores
Pick the libretro core for one ROM on a platform whose entry has `core_rules`.
Pick the libretro core for one ROM on a platform whose entry has core_rules.
Only arcade opts in today. A romset boots on FBNeo when FBNeo knows the set
and on MAME otherwise, since a set FBNeo does not emulate never boots there.
pick_core settles it per launch, first match wins:
requested: thecoreRomM sent. RomM sends one when its config.yml names a core for the platform or, throughcore_overrides, for this set.fbneo_list: the romset is in the platform's shipped set list, so the platform's own core runs it.fallback: everything else boots on the table'sfallback.
A platform without core_rules, or a ROM path no romset can be read from,
answers platform_default (or requested when RomM sent a core), which is
exactly what the launch did before this module existed.
The romset is the ROM path's base name minus its last suffix, lowercased. It is read from the string alone and never touches the filesystem, so the cores and import-spec routes can ask before the ROM is mounted anywhere.
attributelog= logging.getLogger(__name__)attributeCORE_RULES_KEYS= frozenset({'set_list', 'fallback'})The keys a platform entry's core_rules must carry, no more and no fewer.
attributeROM_PATH_MAX= 4096Longest ROM path the cores and import-spec routes take.