Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support UMU-Launcher #622

Draft
wants to merge 8 commits into
base: master
Choose a base branch
from

Conversation

GB609
Copy link
Collaborator

@GB609 GB609 commented Nov 28, 2024

Description

This code change introduces a dropdown in preference giving a choice between 'Wine' and 'UMU-Launcher' as windows game runner.
I've introduced a helper, wine_utils, to handle everything about wine: environment variables, locating the executable etc. There were quite a few other code changes/refactorings as well, partly for maintenance, partly to actually use the new utils.

I also started revising the entire install strategy for windows games as a lot of issues i can see here stem from the different ways to install and that they both seem to have issues.

I'm in favor of using the conventional install within wine over innoextract.
The main reason is that innoextract is basically just like unzip, it doesn't perform any post-file-copy steps, nor does it execute the installer scripts. This leaves the 'installations' in a potentially undefined intermediate state where a lot of additional code is needed to 'make it work'. That's why i temporarily disabled innoextract hard-coded in my branch. Therefore the system installation won't matter. The revised installer does not utilize a temporary directory (with file moving around afterwards) anymore. instead it configures the installer to use a well-known pre-defined directory within the wineprefix.

If there is a desire to still keep innoextract even when the changed installation proves to be stable, i also have a few other changes in stock to make this an option, allowing to toggle between innoextract and regular install without having to remove inno from the system.

I'm putting this up as a draft PR here already (although it is in a bit of an early stage with lots of broken tests) because i need some help. I need information about games and 'constellations':

1. Test of game installations, both with regular wine and umu
I don't own too many windows games on GOG yet and my wallet is not infinite.
I'm mostly interested in the following things:

  1. Does the installation itself work?
  2. A file listing of the install directory in case of success, as well as the content of goggame-*.info file (if any). However, please try to only report if it is not the most trivial case imaginable (later more on that)
  3. In case of failure, any console output, message dialog error etc is helpful.
  4. In all cases: I configured the installer to write its setup configuration to gamedirectory/prefix/drive_c/setup.inf. I'm currently considering whether this file contains any reliable input usable to make workingdir and executable detection easier.

2. Running games
Installation should basically work for all games, since the working directories and installer executables are well known.
This does not apply when running a game, however. Even before my code changes, minigalaxy had quite some logic to try and detect the game's exe file.
There's some try to parse the goggame-*.info file (these appear to be optional), then a direct search for the first exe to found in the game's install dir (some games place their exe in a subdir like bin).
But all installers generate desktop shortcuts. It might be possible to leverage them instead.

That's why i need input on games that install, but don't launch. These are most likely not simple cases.

3. Protonfixes
Some games require winetricks etc.
The folks from UMU started to track this in a database UMU-DB
UMU-Launcher requires a variable named 'GAMEID', which can be arbitrary, but should correspond to value of UMU_ID for a game in that database (if it is there). I've implemented a lookup function and what i need to know is if it actually retrieves the right values for games with protonfixes. This requires a working internet connection. Without internet, the lookup will generate a reasonable default and try again the next time anything within that game's prefix is launched with umu.
I added a tempory dirty log statement to see the full wine launch commands on installation, including GAMEID= when umu is chosen as runner.
So, if anyone owns a game that appears in the database, under store gog, steam or none, please let me know if the value of GAMEID matches what is in that table for UMU_ID.

4. Simple case
A 'simple' case either:

  • has only one executable (other than the unins000.exe) in it's root directory
  • or several, but a parsable goggame-*.info file giving info about which one to use
  • and does not require to step into any other working directory. Determining this is a bit harder. When there is a goggame-*.info file, but it does not contain any 'workingDir' property, it should be ok. Without this file, all we can do is try to start and check the output for errors.

5. Savegames / home pollution
This is something that i have not touched, but it is related to wine configuration.
Regular Wine normally tries to integrate windows applications as seamlessly as possible into the desktop environment. As such, it will link windows user folders like 'Documents' or 'Downloads' to those in /home/user. Depending on the game, it will start putting stuff there. I think it's arguable whether this is desired and this behavior can be changed. When this integration is disabled, the 'Documents' etc will just be regular folders nested somewhere deep within the game's wineprefix directories. The question here is, shall Minigalaxy provide a default configuration or leave it to the users to configure each and every game installation by themselves regarding that?
This is also roughly related to cloud saves or similar. But to achieve this, a uniform and well known save location is necessary which is very hard to do when running games from stone age vs brand new ones for more recent windows versions. But i'm not going on elaborating this here, since this is going off track.

The sandboxing/pollution issue might not apply the same way in UMU since it uses the isolated proton stuff.

The changes to the installer potentially impact or fix:
#618, #605, #602, #512, #506
#289 - i did an adjustment to the /VERYSILENT argument in the wine installer. I found not having any visual feedback at all during a long-running installation makes me feel impatient or that there's something wrong. So i changed the flag to /SILENT which only shows the installation progress, but no configuration options dialog. Potential candidate to go into preferences.

The wine_env configuration might fix:
#117, #313 - i have disabled the winemenubuilder in all prefixes managed by minigalaxy, so shortcuts from within wine are not automatically added to the linux desktop. Only applies on new installations. If there already are shortcuts, they need to be removed manually.

The enhancement of preferences to pick a wine variant opens up the possibility to work on:
#288

Checklist

  • CHANGELOG.md was updated (format: - Change made (thanks to github_username))

@GB609
Copy link
Collaborator Author

GB609 commented Nov 30, 2024

Ok, i'll start.
I've got the following Windows games which i'll try to install and run:

  • Rise Eterna
  • Outcast - Second Contact
  • Severed Steel
  • Star Trek(TM): Voyager - Elite Force
  • Trepang² Demo
  • Genesis: Alpha One Deluxe Edition
  • Lethis - Path of Progress
  • Guild of Ascension
  • Hard Reset Redux
  • Technomancer

I will update the following table as i go one (cant test all at once, takes too much time).
All tests are done with regular wine first.
I'm running Archlinx. I run the games with umu 1.1.4 from time to time, but native wine seems to work better for now because the latest proton (9.0.3) downloaded by umu is missing some gstreamer plugins/codecs.

Game Install Works? starts Simple case? has parseable gog.info requires different workdir? Notes diag files
Rise Eterna yes yes yes yes has 2 exes, but a simple gog.info
Severed Steel yes starts, but freezes on intro. havent debugged for the reason yet yes* gog.info is there, but primary is of type "launcher" tasks Only one *.exe in root which is a launcher, BUT primary info in gog.info defines additional args for this ls_severed_steel.txt info_severed_steel.txt
Star Trek yes yes yes yes multiple exe, but has primary gametask -
Genesis install worked after changes to _exe_cmd yes yes yes not for primary task download progress bar toggles back and forth, probably because several larger files are downloaded in parallel. -
Outcast TBD - - - - -
Trepang TBD - - - - -
Lethis TBD - - - - - -
Guild of A. yes yes yes yes no First launch asks for installation of UE4 in wine. Had some fullscreen resolution issues first. -
Hard Reset TBD - - - - - -
Technomancer TBD - - - - - -

@GB609 GB609 force-pushed the feature/umu-launcher-basic branch from 91a9db5 to 1794328 Compare December 1, 2024 10:01
GB609 added 5 commits December 1, 2024 10:18
completely reworked wine installer to get rid of errors once and for all
tested manually with 'Rise Eterna' which has a simple setup:
1. has goggame.info file
2. no workingDir adjustment
3. only one game executable

Unit tests are still broken, a lot of method signatures were changed.
@GB609 GB609 force-pushed the feature/umu-launcher-basic branch from 1794328 to a484c4b Compare December 1, 2024 10:20
@GB609 GB609 force-pushed the feature/umu-launcher-basic branch from f284efa to 9463ea5 Compare December 2, 2024 10:40
@GB609 GB609 mentioned this pull request Dec 2, 2024
6 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant