Theme editor

  • RequestStream Movies, TV shows and anime streaming • 1 week trial

Running games on linux.

  • Thread starter Thread starter KTrash
  • Start date Start date
  • Replies Replies 39
  • Views Views 4K
Have you guys tried UMU launcher? It seems to be a fork of the "Steam Runtime Tools" and "Steam Linux Runtime" so you can use proton without adding the game to steam.
 
Thank you guys for this thread!
I have seen some Ren'Py games without the .sh script, and no linux-x86_64 folder. It works OK launching the .exe using Wine (it even uses the default linux .renpy folder for savegames, so backups are a breeze), but is annoying nonetheless. Other than asking the developer to compile also for Linux, I assume there is no workaround other than Wine, isn't there?
For renpy, you can easily create a linux version yourself. For this you need:
  1. Find out the version of renpy. One of the options is to look in the game/script_version.txt file.
  2. Download the required version of renpy SDK from the official website.
  3. Unpack and add 'game' folder from the game there... or delete everything except 'game' folder from the game and unpack the missing files from renpy SDK ('lib' folder, 'renpy' folder and two files 'renpy.sh' and 'renpy.py')
  4. Run the game with 'renpy.sh'
 
it will just run using proton
until it doesn't :) i find that wine with Bottles gives you more flexibility and debugging options, if game doesn't run you can choose to run it in the emulated terminal and see exactly what went wrong(missing libraries, files, etc.). if the game crashes in proton you have no way of knowing what caused the crash and no way to fix it because proton is self contained (unless i'm missing something of course).
 
Thread owner
until it doesn't :) i find that wine with Bottles gives you more flexibility and debugging options, if game doesn't run you can choose to run it in the emulated terminal and see exactly what went wrong(missing libraries, files, etc.). if the game crashes in proton you have no way of knowing what caused the crash and no way to fix it because proton is self contained (unless i'm missing something of course).
if you run steam from terminal youll get some more info :P
 
The only thing I couldn't get to run properly were Unreal Engine games. Renpy sometimes has a few hickups, but with the respective SDK it usually works. Unity games run ok under vanilla Wine on my machine, the same as games with labeling "other".
I still haven't had the time to try regular games, that usually only run on windows. Hopefully they will work too.
 
I still haven't had the time to try regular games, that usually only run on windows.
Check out if you haven't already, will save you a lot of time
 
Check out if you haven't already, will save you a lot of time
Yeah, like I said, I didn't have time so far for that. But what I can already say is, that my games are strictly offline. So no Steam or the like for me. :)
 
This is crazy interesting information, thanks!

I have dabbled with wine, but usually run into problems I do not understand. "XYZ32.DLL is missing" *following instructions on how to add it* "XYZ32.DLL is wrong version"...

I do not quite wish to add porn games to Steam, mostly because I run them in a VM to sandbox from the rest of the system. Also because I do not want those games to appear anywhere in my regular system. I mean, I share my library,...

Lutris, Bottles and UMU Launcher are new to me. Will check those out.

May I be so bold as to ask for an example case? If I want to run say LustNfarm v.2.7, what steps should I take?
 
This is crazy interesting information, thanks!

I have dabbled with wine, but usually run into problems I do not understand. "XYZ32.DLL is missing" *following instructions on how to add it* "XYZ32.DLL is wrong version"...

I do not quite wish to add porn games to Steam, mostly because I run them in a VM to sandbox from the rest of the system. Also because I do not want those games to appear anywhere in my regular system. I mean, I share my library,...

Lutris, Bottles and UMU Launcher are new to me. Will check those out.

May I be so bold as to ask for an example case? If I want to run say LustNfarm v.2.7, what steps should I take?
for me, it is simple - just extract and run wine in a terminal. no special wrapper needed. though, i probably have forgotten tweaks to my wine setup after a few years of fiddling with things :LOL:
i have wine vanilla 9.22 (not proton) with a recent-ish version of DXVK on gentoo.

Bash:
$ ls LustnFarm_2.7_uncensored.rar
LustnFarm_2.7_uncensored.rar
$ mkdir LustnFarm_2.7_uncensored
$ cd LustnFarm_2.7_uncensored
$ 7z x ../LustnFarm_2.7_uncensored.rar > /dev/null
$ wine ./LustnFarm

from here the game appears to run fine and i can go through the intro dialogue.

one problem you may run into with a VM is lack of hardware 3d graphics acceleration. i think if you run a linux vm on linux you can get opengl acceleration in VMs, but unsure if other combinations (linux vm on windows, windows vm on linux) work with any 3d acceleration.
 
Yes, the lack of 3D acceleration is a recurring issue. I sometimes move over to a grimy old laptop because it has nominal 3D hardware, and I regularly wipe it clean anyway since I use it for testing different Linux distributions.

$ 7z x ../LustnFarm_2.7_uncensored.rar > /dev/null

That was the weirdest thing I ever saw. It doesn't even work in Linux Mint, I get a load of ERROR: Unsupported Method : <file name>...
What is wrong with right-clicking the archive and choosing Extract Here..? :D

But it worked with wine! This is awesome, because I have tried before and it failed then. Wonder what I have changed since then...?

Thanks, I would not have tried were it not for you. :)
 
Yes, the lack of 3D acceleration is a recurring issue. I sometimes move over to a grimy old laptop because it has nominal 3D hardware, and I regularly wipe it clean anyway since I use it for testing different Linux distributions.

$ 7z x ../LustnFarm_2.7_uncensored.rar > /dev/null

That was the weirdest thing I ever saw. It doesn't even work in Linux Mint, I get a load of ERROR: Unsupported Method : <file name>...
What is wrong with right-clicking the archive and choosing Extract Here..? :D

But it worked with wine! This is awesome, because I have tried before and it failed then. Wonder what I have changed since then...?

Thanks, I would not have tried were it not for you. :)

your 7z build on mint doesn't have rar support. probably need `7zip-rar` package or something.
nothing wrong - i simply use the terminal for everything, not gui.

glad to hear it.
 
I learned something new! Thanks!
 
found this recently, a much more complete guide that rolls up a lot of the tips here.



as a bonus, the site also has a page on using freebsd.. but my masochism has limits.
 
Here are some hints for Ren'Py. Specifics of what you need to do on the desktop may depend on the desktop environment used, such as GNOME or KDE. I am assuming here the default GNOME environment for a modern Ubuntu. Other desktop environments will be similar but not identical. GameName stands for the technical name the developer chose for the game, which is often the GamesFullName in CamelCase without spaces or special characters, but may also be an abbreviation such as gfn or something completely different, e.g. based on the game's previous name.
  • Practically all Ren'Py games that are advertised as being for PC run perfectly on Linux. Just unzip, open the top-level folder, and run GameName.sh like a program. If double clicking opens an editor instead of running the script, right click and select "Run as a program".
  • If GameName.sh exists but the option "Run as a program" is not present, then the problem is the missing executable bit. (This problem is typical for Ren'Py games advertised as being for Windows but having "pc" not "win" in the filename, and for Ren'Py games packaged with RAR instead of ZIP.) You can set this bit by right-clicking, selecting "Properties" and then under "Permissions" selecting "Executable as Program". Alternatively, in the shell, enter chmod a+x GameName.sh. However, if the shell script misses the executable bit, then the same is practically always the case for a second file located in your relevant linux subfolder of the lib subfolder. The file is a binary file that always has exactly the same name as the shell script, only without the file extension .sh. In the example, it would be named GameName. So for example you could do chmod a+x lib/linux-x86_64/GameName in the shell. The linux-x86_64 part is for a 64-bit Linux distribution (standard nowadays) and varies with the Ren'Py version. If such subfolders with "linux" in them, you can just do it for each of them.
  • Some developers export a game specifically for Windows only rather than for Windows and Linux. I don't now why. Perhaps to save a few bytes or because they are not familiar with Linux and don't want to be asked questions related to running the game on Linux. Fortunately this problem can be solved as follows. In the subfolder lib of the game's folder, there will be a subfolder named python2.7 or python3.9 or similar. (If there are subfolders python3.9 and python3.11, you can just delete or ignore python3.11.) Find another Ren'Py game that works on Linux and has a sub-subfolder with the same name, i.e. with the same python version number. Copy the subfolder linux-x86_64 (or similar) of lib from that other (working) game to the subfolder lib of this (defective) game. Finally you must rename the two files that sometimes have a missing executable bit. The correct name for this game is the one from the Windows executable ThisGameName.exe. Make a copy of OtherGameName.sh in this game and rename it to ThisGameName.sh . Also rename lib/linux-x86_64/OtherGameName (which we already copied earlier) to lib/linux-x86_64/ThisGameName.
  • In my experience, my advice in the previous paragraph always works. But it is admittedly a bit sloppy because it ignores the issue of Ren'Py versions and just looks at the Python version. If it doesn't work, you may have more luck using a different Ren'Py game with the same Python version as the donor. If that still fails, you can find elsewhere instructions on doing this correctly by installing the Ren'Py development environment.
  • In at least one case, a game was shipped or repackaged with Linux executables that were defective in some way. I managed to fix it by replacing the broken files with working ones from a compatible different game (again a folder and two files) just as described before.
  • If for some reason you only have the MacOS version of a Ren'Py game, there are some differences in file structure, but you should be able to figure out how to make it work with the same method I described. (I have not yet had reason to test this.) I am not sure if this is also possible with Ren'Py games packaged for Android.
Of course Windows users can use similar methods to turn a Linux version of a Ren'Py game into a Windows version. But the necessity for this is much rarer.
 
Last edited:
Nice tips and hints.
Although I never had to rename/copy over any libs. After changing the rights to executable, everything worked.
But sometimes I started the games via the RenPy SDK. Maybe thats why.
 
Some great tips in here thanks! Going to switch to linux later in year from Win10 - not going to Win11!
 
Nice tips and hints.
Although I never had to rename/copy over any libs. After changing the rights to executable, everything worked.
But sometimes I started the games via the RenPy SDK. Maybe thats why.
Yes, I could have made it clearer that you almost never need this. In my defense, the very point of my post was to explain in a thread where people will look for it what you can do in the rare cases when setting the executable bit is not enough. The well known part about the executable bit was just for completeness plus to explain precisely what needs to be fixed at a minimum. (The Linux version has executable bits on several other files that don't absolutely need it.)

----

While I am here: a deeper dive

The reason why it's all so easy is that all the variable parts of a normal Ren'Py game are system independent except for the fact that certain file names of game-independent files are by default set to what I will call the game's technical name for the purposes of this discussion.

Here is what happens under Linux. Under Windows it's similar.

When you execute the shell script GameName.sh, it asks the operating system what its name is (namely GameName.sh) and extracts the game's technical name, GameName, from this. Then it looks for a file lib/linux-.../GameName and tries to execute it. This first step fails if you rename one of the two files but not the other. So the shell script is just for convenience so you need not drill down to find the executable file.

Now the executable file is a very similar case. It asks the operating system for its own name, which it assumes is the game's technical name: GameName in the example. Then it goes two folders up (back to the top level of the game folder, where we found GameName.sh) and basically runs the python interpreter which is located next to itself on the system independent Python script GameName.py which it finds there. This second step fails if you rename one of these two files but not the other.

Finally, the game-independent and system-independent Python script GameName.py runs under the Python interpreter. These three files GameName.sh, GameName and GameName.py are identical for different games created with the same version of Ren'Py. Only their names vary between games.

The names of these three flies actually don't seem to matter at all so long as they all agree. In particular, while it is typically the case that the second copy of the save files (in addition to the one in game/saves) is in .renpy/GameName or in .renpy/GameName-[somenumber], that is not necessarily the case and we can't change the save file location by renaming the files used to run the game.
 
Last edited:
I have failed using lutris time and time again, if wine does not run the game i want, then lutris usually fails as well... the best failsafe way i have come up with is to use steam as game loader :p
necropost but someone might come across it, you probably forgot to change the runner to proton, lutris uses wine itself by default and doesn't use proton-ge unless specified.
 
Back
Top Bottom