mirror of
https://github.com/Abdess/retroarch_system.git
synced 2026-10-10 21:43:23 -05:00
fix: an untagged bios serves every region
This commit is contained in:
1 parent
cea6e516a4
commit
7164e8a125
2 files changed
+20
-5
No files matched your search
+14
-5
@@ -255,16 +255,25 @@ def fallback_groups(
|
||||
index: dict[str, dict],
|
||||
requested: list[str],
|
||||
) -> list[str]:
|
||||
"""Group IDs where no candidate matched, so the whole group was kept."""
|
||||
"""Group IDs where no candidate matched, so the whole group was kept.
|
||||
|
||||
A world file, or one that declares no region at all, answers every
|
||||
region: the C64 kernal VICE loads by default is untagged, and a group
|
||||
holding it beside a Japanese and a Swedish kernal does have a BIOS for
|
||||
North America.
|
||||
"""
|
||||
if not requested:
|
||||
return []
|
||||
out: list[str] = []
|
||||
for group_id, members in groups.items():
|
||||
ranked = _competing_ranks(members, index, requested)
|
||||
has_world = any(
|
||||
WORLD in lookup_regions(index, destination, name)
|
||||
for destination, name in members
|
||||
served = any(
|
||||
not regions or WORLD in regions
|
||||
for regions in (
|
||||
lookup_regions(index, destination, name)
|
||||
for destination, name in members
|
||||
)
|
||||
)
|
||||
if ranked and not has_world and min(r for r, _ in ranked) == len(requested):
|
||||
if ranked and not served and min(r for r, _ in ranked) == len(requested):
|
||||
out.append(group_id)
|
||||
return sorted(out)
|
||||
Reference in new issue
Block a user