mirror of
https://github.com/HarbourMasters/Shipwright.git
synced 2024-11-26 03:12:18 -05:00
fix: process roms in consistent order (#2696)
This commit is contained in:
parent
fe71cdfbb6
commit
82b6c48497
@ -18,17 +18,14 @@ def chooseROM(verbose=False, non_interactive=False):
|
|||||||
return roms
|
return roms
|
||||||
|
|
||||||
if non_interactive:
|
if non_interactive:
|
||||||
romsToExtract = []
|
mq_rom = None
|
||||||
foundMq = False
|
non_mq_rom = None
|
||||||
foundOot = False
|
|
||||||
for rom in roms:
|
for rom in roms:
|
||||||
if rom.isMq and not foundMq:
|
if rom.isMq and mq_rom is None:
|
||||||
romsToExtract.append(rom)
|
mq_rom = rom
|
||||||
foundMq = True
|
elif not rom.isMq and non_mq_rom is None:
|
||||||
elif not rom.isMq and not foundOot:
|
non_mq_rom = rom
|
||||||
romsToExtract.append(rom)
|
return [rom for rom in [non_mq_rom, mq_rom] if rom is not None]
|
||||||
foundOot = True
|
|
||||||
return romsToExtract
|
|
||||||
|
|
||||||
print(f"{len(roms)} roms found, please select one by pressing 1-{len(roms)}")
|
print(f"{len(roms)} roms found, please select one by pressing 1-{len(roms)}")
|
||||||
print()
|
print()
|
||||||
|
Loading…
Reference in New Issue
Block a user