XIVLauncher.Core icon indicating copy to clipboard operation
XIVLauncher.Core copied to clipboard

Compatibility rework 2

Open rankynbass opened this issue 2 years ago • 1 comments

Replacement compatibility rework to go with PR https://github.com/goatcorp/FFXIVQuickLauncher/pull/1366.

This allows for the selecting of different wine versions, different dxvk versions, and hud options to all be managed on the XL.Core side. The values are then passed to CompatibilityTools. This primarily allows for updating wine or dxvk without touching XL.Common.Unix.

Replaces https://github.com/goatcorp/XIVLauncher.Core/pull/59

Here's a flatpak of the launcher, for testing: https://github.com/rankynbass/XIVLauncher.Core/releases/tag/compatrework-v2

rankynbass avatar Jul 26 '23 15:07 rankynbass

Wine folders can now be dropped in compatibilitytools/wine and dxvk folders can be dropped in compatibilitytool/dxvk, and they will now appear in the drop down lists. This basically replaces an enum with a dictionary, which is a lot more flexible and requires a lot fewer switch statements. Should be easier to update when new versions of wine or dxvk are released. xlcore-custom-wine-versions-2

rankynbass avatar Sep 14 '23 02:09 rankynbass

Updated for the XL.Common.Unix merge.

rankynbass avatar Nov 07 '24 01:11 rankynbass

Honestly, OSInfo could just be renamed DistroInfo, because that's all it's really doing. Yeah, it has checks for other OSes, but those aren't actually used for anything. It could just as easily be an IsLinux bool instead of an a platform enum. As for the flatpak bool, tbh it's not used for anything either. I mainly added it just in case, but never found any reason to use it in CompatibilityTools. All of the flatpak stuff has to be worked out before it gets passed to CompatibilityTools anyway.

rankynbass avatar Nov 07 '24 16:11 rankynbass

If the Flatpak bool is truly not needed, then it should probably just be removed honestly.

But even as DistroInfo it does make much more sense to have it conceptually there (and could for example greatly simplify MangoHudIsInstalled).

In this MR as it is right now, it is used however much more like a more advanced OSVersion.

marzent avatar Nov 07 '24 16:11 marzent

I've moved OSInfo into XL.Common.Unix and renamed it LinuxInfo. I've also added library paths to LinuxInfo, so that there's a List of paths to search for common library files. I've adjusted the MangoHudIsInstalled function to make use of it, and plan to use it for finding DLSS libraries in the future, when that gets added.

I've also added Snap handling, since it's possible XLCore will be run inside of Snap Steam using XLM on Ubuntu distros.

rankynbass avatar Nov 09 '24 23:11 rankynbass