DavidoTek / ProtonUp-Qt

Install and manage GE-Proton, Luxtorpeda & more for Steam and Wine-GE & more for Lutris with this graphical user interface.
https://davidotek.github.io/protonup-qt
GNU General Public License v3.0
1.25k stars 40 forks source link

Heroic: Add D8VK #245

Closed sonic2kk closed 1 year ago

sonic2kk commented 1 year ago

This PR adds support for installing D8VK for Heroic, as requested in #208.

Heroic stores DXVK versions in its tools directory, under the dxvk folder. The folder structure of DXVK versions that it expects matches Lutris and so no change was needed to the extraction logic. It simply expects a folder in the tools directory with the name of the tool, and then the x32 folder for the required DLLs.

Though this PR Is for *D8VK*, this project is a fork of DXVK and operates similarly, so from Heroic's perspective D8VK would be treated as a separate DXVK "version" :-)

Two main changes were needed for this PR:

  1. Updating ctmod_d8vk to check which directory to extract into using some checks in the current launcher's path. For Heroic and Lutris we have two different extraction directories, so we infer the launcher type in the ctmod and use that to determine where to extract to. This is essentially the approached I mentioned in https://github.com/DavidoTek/ProtonUp-Qt/discussions/208#discussioncomment-5754955
  2. Update the main UI to display DXVK and vkd3d runtimes. This was not done previously because ProtonUp-Qt doesn't give the ability to install anything except a handful of Wine/Proton versions for Heroic. However this PR implements a DXVK runtime, and also, Heroic allows you to download custom DXVK versions I believe, so giving users the visibility into these tools (and cleanup/remove them) is useful in general :smile:

The ctmod was updated to include heroicproton and heroicwine as sources. It is more common for Wine to not include a DXVK runtime, but as far as I know, selecting a DXVK version with Heroic will override the DLLs and force that DXVK version. It is also still possible to get builds of Proton without DXVK, such as Kron4ek Wine (not (yet) available for Heroic with ProtonUp-Qt), so this change should be applicable for both Heroic Wine and Heroic Proton.

I have tested this change with Heroic AppImage and Heroic Flatpak, so I was able to confirm that both config directories worked as expected.


This was implemented as kind of a proof-of-concept, but the logic here would also apply to DXVK and vkd3d (Proton and vkd3d from Lutris). This would cover the "others" mentioned in #208. I didn't want to include those in this PR, at least initially, in case there are any reservations around adding this functionality or anything that needs ironed out first :-)

Thanks!

DavidoTek commented 1 year ago

Thanks! I will do some testing

Update the main UI to display DXVK and vkd3d runtimes

Does the remove logic work with the current implementation?

selecting a DXVK version with Heroic will override the DLLs and force that DXVK version

Okay, that is good.

"others" mentioned in https://github.com/DavidoTek/ProtonUp-Qt/discussions/208. I didn't want to include those in this PR, at least initially, in case there are any reservations around adding this functionality or anything that needs ironed out first :-)

Yeah, we can do them in later PRs if everything works out.

sonic2kk commented 1 year ago

Does the remove logic work with the current implementation?

Yup, it even works for DXVK and vkd3d in my tests (I had a few installed unrelated to this PR). I don't remember if I tested removing D8VK and a Wine/Proton version together but I think that would work too.