Allow picking WUA files for Cemu

This commit is contained in:
Mathieu Comandon 2024-03-28 19:42:06 -07:00
parent 8836eae836
commit 738bda4bb4
2 changed files with 8 additions and 3 deletions

View file

@ -496,7 +496,6 @@ class ConfigBox(VBox):
default_path=chooser_default_path,
shell_quoting=shell_quoting,
)
# file_chooser.set_size_request(200, 30)
if "default_path" in option:
chooser_default_path = self.lutris_config.system_config.get(option["default_path"])

View file

@ -24,7 +24,13 @@ class cemu(Runner):
"The directory in which the game lives. "
"If installed into Cemu, this will be in the mlc directory, such as mlc/usr/title/00050000/101c9500."
),
}
},
{
"option": "wua_rom",
"type": "file",
"label": _("Compressed ROM"),
"help": _("A game compressed into a single file (WUA format), only use if not using game directory"),
},
]
runner_options = [
{
@ -82,7 +88,7 @@ class cemu(Runner):
legacy = self.runner_config.get("legacy")
if legacy:
arguments.append("--legacy")
gamedir = self.game_config.get("main_file") or ""
gamedir = self.game_config.get("main_file") or self.game_config.get("wua_rom") or ""
if not system.path_exists(gamedir):
raise DirectoryNotFoundError(directory=gamedir)
arguments += ["-g", gamedir]