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.22k stars 40 forks source link

Lutris: Add Basic Games List #192

Closed sonic2kk closed 1 year ago

sonic2kk commented 1 year ago

This PR adds a Games List for Lutris, adjusting the data displayed to be relevant to Lutris games :smile: It displays games from all runners except Steam (as we already display Steam games in the Steam games list dialog), and also has full sorting support to match the Steam games list. Because I really wanted a change of pace from writing Bash :sweat_smile:

I implemented this in pupgui2gameslistdialog.py. There was some logic there already in preparation for a Lutris games list it seems. I'm a bit undecided if this is "better" than having a separate dialog, but the ctinfo dialog is shared, and as mentioned there was already some prep work for a Lutris games list, so I figured it was fine at least for now :-)

image

Overview

Instead of displaying the compatibility tool, Deck compatibility, Anti-Cheat status, and ProtonDB rating, we instead display the following:

The fifth column that the Steam games list has is hidden. The "Apply" button was also changed to "Close", since there is nothing to Apply in this menu.

I chose to put the Wine information in a tooltip because I figured it would be useful to show a "complete" Lutris games list, minus Steam games only because we already display that for the Steam runner. Since not all Lutris runners will have Wine information, I chose to put it in the tooltip when the runner is Wine.

There is the option of only showing Lutris games that have a Wine runner, and then we show the Wine version/DXVK version/vkd3d version in that column (in that fallback order, in case one is missing, and show the rest in the tooltip). In the case where there is no Wine version (yep, that can be a scenario...) we could display "Unknown". I am personally slightly more in favour of the approach I took but only because my personal preference is seeing a "full" Lutris game list.

Unlike the Steam dialog though, there is no way to "change" a compatibility tool, there is no dropdown in the Lutris list like its Steam counterpart, and there are a couple of reasons for this:

Other Changes

I made a couple of other changes along the way to implement this.

I have only tested this on my main PC, which only has a selection of Lutris games. Further testing is, of course, very welcome here to make sure this works for more than my setup :-)


I decided to try and implement this on a whim, after I noticed the commented out lines to show the games list button for Lutris games. So I wanted to see if it would be feasible to implement a Lutris Games List. I don't use Lutris very much so it was just a bit of an experiment that could potentially end up being useful :-)

At the very least, I hope that this could serve as a "proof-of-concept" for a future Lutris games list implementation (perhaps similar to what I described with the Wine/etc comboboxes), if this simplistic "game information only" approach is not desirable.

Thanks!

DavidoTek commented 1 year ago

I implemented this in pupgui2gameslistdialog.py. There was some logic there already in preparation for a Lutris games list it seems. I'm a bit undecided if this is "better" than having a separate dialog

Okay. If there are some fundamental changes to the Lutris game list in the future, we can always separate it from the Steam game list.

we instead display the following: Game Name, Runner, Install Location, Install Date

Looks good to me

Since not all Lutris runners will have Wine information, I chose to put it in the tooltip when the runner is Wine.

Yeah, I think that is fine. If we ever decide to add functionality for changing the Wine version, we may utilize the fifth column for that. But as you pointed out, users may also want to change DXVK/vkd3d versions. That can be done easily in Lutris own settings.

seeing a "full" Lutris game list

Agreed

[Feature Request] Use a symlink to help auto update wine-ge #162 or DXVK Updater #139.

Agreed

In lutrisutil.get_lutris_game_list, some extra logic was added to fetch the install path of a game and store it in install_dir

That's good. Even if the path may not be exactly correct, it should be good for users to get a rough idea where the game is stored and that's enough.

Remove the vertical header from the games list, as it doesn't appear to be used anywhere

It was originally used for showing game ids, but that feature was eventually removed (can't remember when and why).


Thanks for the effort to implement this. I think it is much better than the current situation: no game list :smile:. Adding this "game information only" list may encurrage users to think about more usecases for the dialog. Also, the "always non-empty install directory feature" is quite nice to have :smile: I will do some testing and merge it in the next days.

sonic2kk commented 1 year ago

users may also want to change DXVK/vkd3d versions. That can be done easily in Lutris own settings.

I think this is a good compromise, and using the fifth column for the Wine version is a good idea. The column is just hidden, so if we ever need to use it, it's just a case of removing self.ui.tableGames.setColumnHidden(4, True).

Or another possibility is removing the install time data and replacing it with the Wine version. Install time information could be moved somewhere else, maybe the tooltip for the game name or install path.

Adding this "game information only" list may encurrage users to think about more usecases for the dialog

Great point! I'm not a huge Lutris user so I'm sure Lutris users will have good ideas on improving it :-)