From 98f53221f3baa6702fdb487e7d5b1a83a891601f Mon Sep 17 00:00:00 2001 From: Daniel Johnson Date: Tue, 18 Jun 2024 16:58:33 -0400 Subject: [PATCH] Re-arrange code and add a hack so that wineexec() will work with GE-Proton (Latest) It needs to recognize that oddball "path" that is not a path, and in that case substitute the proper UMU script and *not* set PROTONPATH, since we don't know what that is. Seems to work, still super ugly though. Resolves #5519 --- lutris/runners/commands/wine.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/lutris/runners/commands/wine.py b/lutris/runners/commands/wine.py index 84f637877..72c52174e 100644 --- a/lutris/runners/commands/wine.py +++ b/lutris/runners/commands/wine.py @@ -338,7 +338,11 @@ def wineexec( if proton.is_proton_path(wine_path): game = None wineenv["GAMEID"] = proton.get_game_id(game) - wineenv["PROTONPATH"] = proton.get_proton_path_from_bin(wine_path) + + if wine_path == GE_PROTON_LATEST: + wine_path = proton.get_umu_path() + else: + wineenv["PROTONPATH"] = proton.get_proton_path_from_bin(wine_path) locale = env.get("LC_ALL") host_locale = env.get("HOST_LC_ALL") if locale and not host_locale: @@ -348,9 +352,6 @@ def wineexec( baseenv.update(wineenv) baseenv.update(env) - if proton.is_proton_path(wine_path): - wine_path = proton.get_umu_path() - command_parameters = [wine_path] if executable: command_parameters.append(executable)