Can't get past game selection in protontricks

I’m trying to use protontricks to install gdiplusfor the game Hellsinker. (Steam app ID 1067720), but when I run the command protontricks -v -v 1067720 gdiplus, it produces this uninformative error message:

warning: /home/USERNAME/.cache/protontricks/proton/Proton Experimental/bin/wine cmd.exe /c echo ‘%AppData%’ returned empty string, error message “protontricks - wine 8088: Checking for running wineserver instance
protontricks - wine 8088: Setting default env: WINEFSYNC=1
protontricks - wine 8088: Setting default env: WINEESYNC=1
protontricks - wine 8088: Starting Wine process directly, Steam runtime: off
fsync: up and running.”

Running the GUI lets me select a game, but it crashes shortly afterwards with an identical error message.

I’m not sure why this fails, exactly; my best guess is that protontricks or winetricks is tripping over some unconventional filesystem thing that NixOS does. Does anyone else have any ideas?

Might want to delete that cache. If %AppData% is empty I suspect either wine itself isn’t running at all (perhaps because it is dynamically linked against FHS paths), or for some reason your environment variables are empty, which I’m pretty sure is impossible.

How did you install protontricks?

I installed it declaratively, with the option programs.steam.protontricks.enable.

Deleting .cache/protontricks doesn’t seem to do anything; when I run protontricks again, it’s regenerated with the same contents.

For what it’s worth, I was able to install gdiplus by running winetricks within a nix-shell as follows:

nix-shell -p wineWow64Packages.stable winetricks
  export WINEPREFIX="$HOME/.steam/steam/steamapps/compatdata/1067720/pfx"
  winetricks gdiplus

(where the last two commands are run within the shell environment).

This didn’t work in an environment with wine alone (it complained about the prefix being 64-bit), nor did it work with wine64 (it returned an error like the one mentioned in the first post). My guess is that winetricks assumes that Wine is set up in whatever way the package wineWow64Packages.stable does it, and the declarative installation of protontricks doesn’t take responsibility for ensuring that it is set up in that way.

I’m writing this in case someone else encounters this issue, but I’m not marking this as a solution, because it seems like there should be a way to do this via the “native” protontricks.

Bonus points if someone comes up with a declarative way to do this! It would be nice to be able to specify, for each game, the dependencies that should be installed via winetricks or protontricks.