Flatpak runners on Flatpak Lutris

Hello,

I would like to play CorsixTH (engine port for Theme Hospital) on Flatpak Lutris. Now, the installation script for CorsixTH tries to install the CorsixTH Flatpak, which doesn’t work, because Flatpak Lutris cannot access the system Flatpak installation. I have tried installing CorsixTH as a Flatpak manually, but Lutris still tries installing CorsixTH itself and fails due to not finding a local Flatpak installation. Now, is this some kind of bug with this installation script, or is it simply so that Flatpak Lutris cannot handle Flatpak runners, even when these are installed manually?

Thanks in advance.

You can still use Flatseal to give Lutris more rights and access

I enabled filesystem=host for Lutris but that unfortunately did not solve the issue.

The script won’t work within Lutris Flatpak without something Flatpak-land–specific like:

  - execute:
      command: flatpak-spawn --host flatpak install flathub --system -y --noninteractive com.corsixth.corsixth

But, this is a bit of a hack that makes an assumption about --system vs --user install preference, and relies upon flatpak-spawn to pass commands to the host. With due respect to legluondunet, the current “runner: linux” script is a bit of a hack, regardless – Lutris.net doesn’t seem to currently support uploading “runner: flatpak” scripts. Such a script would have a format more like:

  game:
    appid: <flatpak_id>
    arch: 'x86_64'
    branch: 'stable'
    args: --<gamedata-location>=$GAMEDIR

Regardless, you would then still have to whitelist the Lutris $GAMEDIR for the app in question (can be done as another command, like):

flatpak-spawn --host flatpak override --user --filesystem=$GAMEDIR com.corsixth.corsixth

But note, even the above is a hack. Ideally, Lutris itself would support passing variables at runtime (so as not to mess with a user’s Flatpak permissions store), like so (currently unimplemented):

flatpak run --filesystem=$GAMEDIR com.corsixth.corsixTH

Also I looked, but couldn’t find a valid commandline option to pass the game data directory to CorsixTH. Otherwise, that could also be passed as an args: under game: (as above)

All that to say, Flatpak support doesn’t yet seem well integrated into Lutris.

1 Like