From 2edc36d41c69a459be2791ee02d27c308e0e8409 Mon Sep 17 00:00:00 2001 From: Rankyn Bass Date: Sun, 11 Dec 2022 22:40:42 -0800 Subject: [PATCH] update to work with latest rewor changes --- lib/FFXIVQuickLauncher | 2 +- .../Components/SettingsPage/Tabs/SettingsTabWine.cs | 5 ++++- src/XIVLauncher.Core/Configuration/ILauncherConfig.cs | 2 ++ src/XIVLauncher.Core/Program.cs | 5 +++-- 4 files changed, 10 insertions(+), 4 deletions(-) diff --git a/lib/FFXIVQuickLauncher b/lib/FFXIVQuickLauncher index 77115d3f..84b96375 160000 --- a/lib/FFXIVQuickLauncher +++ b/lib/FFXIVQuickLauncher @@ -1 +1 @@ -Subproject commit 77115d3f7d920179ce83f0708ec97ba2450ce795 +Subproject commit 84b9637578c7add03ebc1d35c947367e190cc801 diff --git a/src/XIVLauncher.Core/Components/SettingsPage/Tabs/SettingsTabWine.cs b/src/XIVLauncher.Core/Components/SettingsPage/Tabs/SettingsTabWine.cs index 9387df3d..4e68b528 100644 --- a/src/XIVLauncher.Core/Components/SettingsPage/Tabs/SettingsTabWine.cs +++ b/src/XIVLauncher.Core/Components/SettingsPage/Tabs/SettingsTabWine.cs @@ -49,7 +49,10 @@ public SettingsTabWine() } }, - new SettingsEntry("WINEDEBUG Variables", "Configure debug logging for wine. Useful for troubleshooting.", () => Program.Config.WineDebugVars ?? string.Empty, s => Program.Config.WineDebugVars = s) + new SettingsEntry("WINEDEBUG Variables", "Configure debug logging for wine. Useful for troubleshooting.", () => Program.Config.WineDebugVars ?? string.Empty, s => Program.Config.WineDebugVars = s), + new SettingsEntry("Use WineD3D (Disable DXVK)", + "Don't check this unless you know what you're doing.\nIf you check this, XIVLauncher will try to use WineD3D instead of DXVK, and nothing in the DXVK tab will work.\nCustom wine versions may not work (especially proton-based wine). This will also break GShade.", + () => Program.Config.WineD3DEnabled ?? false, b => Program.Config.WineD3DEnabled = b), }; } diff --git a/src/XIVLauncher.Core/Configuration/ILauncherConfig.cs b/src/XIVLauncher.Core/Configuration/ILauncherConfig.cs index a25536ad..6d63fcb3 100644 --- a/src/XIVLauncher.Core/Configuration/ILauncherConfig.cs +++ b/src/XIVLauncher.Core/Configuration/ILauncherConfig.cs @@ -66,6 +66,8 @@ public interface ILauncherConfig public bool? GameModeEnabled { get; set; } + public bool? WineD3DEnabled { get; set; } + public Dxvk.DxvkVersion DxvkVersion { get; set; } public bool? DxvkAsyncEnabled { get; set; } diff --git a/src/XIVLauncher.Core/Program.cs b/src/XIVLauncher.Core/Program.cs index fe8ef798..354eb7bb 100644 --- a/src/XIVLauncher.Core/Program.cs +++ b/src/XIVLauncher.Core/Program.cs @@ -107,12 +107,13 @@ private static void LoadConfig(Storage storage) Config.GlobalScale ??= 1.0f; Config.GameModeEnabled ??= false; + Config.WineD3DEnabled ??= false; Config.DxvkAsyncEnabled ??= true; Config.DxvkFrameRate ??= 0; Config.ESyncEnabled ??= true; Config.FSyncEnabled ??= false; Config.DxvkHudCustom ??= "fps,frametimes,gpuload,version"; - Config.DxvkMangoCustom ??= Environment.GetEnvironmentVariable("HOME") + "/.config/MangoHud/MangoHud.conf"; + Config.DxvkMangoCustom ??= Path.Combine(Environment.GetEnvironmentVariable("HOME"), ".config", "MangoHud", "MangoHud.conf"); Config.WineStartupType ??= WineStartupType.Managed; Config.WineBinaryPath ??= "/usr/bin"; @@ -278,7 +279,7 @@ public static void CreateCompatToolsInstance() var winePrefix = storage.GetFolder("wineprefix"); var wineSettings = new WineSettings(Config.WineStartupType, Config.WineBinaryPath, Config.WineDebugVars, wineLogFile, winePrefix, Config.ESyncEnabled, Config.FSyncEnabled); var toolsFolder = storage.GetFolder("compatibilitytool"); - var dxvkSettings = new DxvkSettings(Config.DxvkHudType, Config.DxvkHudCustom, Config.DxvkMangoCustom, Config.DxvkAsyncEnabled, Config.DxvkFrameRate, Config.DxvkVersion, storage.Root); + var dxvkSettings = new DxvkSettings(Config.DxvkHudType, storage.Root, Config.DxvkVersion, !Config.WineD3DEnabled ?? true, Config.DxvkHudCustom, new FileInfo(Config.DxvkMangoCustom), Config.DxvkAsyncEnabled ?? true, Config.DxvkFrameRate ?? 0); CompatibilityTools = new CompatibilityTools(wineSettings, dxvkSettings, Config.GameModeEnabled, toolsFolder); }