Linux Gamers

xMentat

Newbie
Apr 14, 2018
73
71
Has anyone else noticed that games here, I guess mostly renpy ones, are stated to be "Windows" but when you download them, there is a perfectly good *.sh to run it in Linux? I only noticed because I'm interested in renpy and wondered what the difference for Windows installs was.

It would be nice if devs/mods could indicate if this is the case in OP.

I don't do Windows, BTW :)
 

xMentat

Newbie
Apr 14, 2018
73
71
A perfect example just popped up, "More than meets the eye" says it is Win/Mac but has a *.sh file which runs fine under Linux (I just downloaded and ran it). Why did the uploader not include a Linux tag?

*feels Linus Torvalds is being ignored*
 

GAB

Salty Montrealer
Donor
May 10, 2017
2,405
18,188
interesting take. have you checked if there are other games whit a .sh file too?

Users with the appropriate rank could edit the OP of games with and mark that it works with linux/windows
 
  • Like
Reactions: xMentat

Retro

Retired
Former Staff
Sep 7, 2017
3,217
18,849
A perfect example just popped up, "More than meets the eye" says it is Win/Mac but has a *.sh file which runs fine under Linux (I just downloaded and ran it). Why did the uploader not include a Linux tag?

*feels Linus Torvalds is being ignored*
Because if the dev isnt explicit in it being compatible for Linux we don't always know about it
 
  • Like
Reactions: xMentat

selectivepaperclip

Active Member
Modder
Donor
Respected User
Feb 19, 2017
537
3,505
Has anyone else noticed that games here, I guess mostly renpy ones, are stated to be "Windows" but when you download them, there is a perfectly good *.sh to run it in Linux?
When you build a distributable in RenPy, the default selected option is "PC: Windows and Linux" renpy_default.png
So pretty much any RenPy game that's exported for 'Windows' is likely to work on Linux as well, unless the dev deliberately checked 'Windows' instead of 'PC'.

The only real reason they might do that is to save the ~12MB of extra space that the packaged 32/64 bit Linux Python versions take up.

The majority of a RenPy game is cross-platform RenPy/Python script, so if a game doesn't have a .sh included you could probably Frankenstein it into working

 
  • Like
Reactions: SenMizeri

selectivepaperclip

Active Member
Modder
Donor
Respected User
Feb 19, 2017
537
3,505
It would be nice if devs/mods could indicate if this is the case in OP.
I think most uploaders don't bother to mention it because they (correctly, I think) assume that the Linux market is a very, very small percentage of players. But if you're a dedicated Linux user you should probably be able to handle workarounds like the stuff above :)

Having never run a RenPy game on Linux, I don't know how likely it's going to be for any given game that the author has managed to program something that doesn't work in Linux even though RenPy in general should be cross-platform. But I'm sure it's possible!
 

anne O'nymous

I'm not grumpy, I'm just coded that way.
Modder
Donor
Respected User
Jun 10, 2017
10,978
16,236
Has anyone else noticed that games here, I guess mostly renpy ones, are stated to be "Windows" but when you download them, there is a perfectly good *.sh to run it in Linux?
Er... Alright...

".sh" is a (useless, the shebang isn't here for dogs) default extension, initially used to mark scripts wrote for Bourne Shell, now extended for C shell and its successor tcsh. For Ren'py they are strict Bourne Shell scripts, which mean that you can make them run whatever the OS as long as you have a Bourne Shell, C Shell or TCSH interpreter. So, you can run then on Linux, any Unix and Unix-like (what MacOS X is), and Windows if you have the Win32 port of C Shell (or was it Bourne Shell ? I don't remember right now).
This said, to run a Ren'py game on Linux, what you need isn't a .sh script ; well, you need it since there's no ELF executable, but having it isn't enough. What you really need is that the libraries used by Ren'py (like LibPNG, libJPEG, etc) and the Python executable, were compiled for Linux. Which is obviously not the case for "windows only" distributions of a Ren'py Game. But, if you look closely, you'll see that really few Ren'py games are stated as "Win". The large majority of them are stated "Win/Linux" or, less frequently, "PC".
To know if it's a Windows only distribution or a Win/Linux one, just look at the end of the archive name. If it end with "-win", it's a Windows only distribution ; this one will never works on Linux even if you found a .sh file on it (which isn't the case anyway). But if it end with "-pc" it's a Win/Linux one, and so you can run it on Linux, as long as it itself run on an Intel architecture. On a side note, the presence of a .sh script isn't a good indicator, since both Linux and MacOS X distributions use the Bourne Shell script as launcher.

Oh, and by the way, don't invoke Linus, Bourne Shell was wrote in 1977, 14 years before the first release of Linux.
 

NandabaCanti

Active Member
Jan 4, 2018
677
754
I use Linux exclusively, and have for over a decade now, I can say that probably around 2/3rds of the Ren'Py based games I've snagged from here have had the Linux files intact, though many of them required me to go into the ./lib/linux-x86_64 dir and flag all 5 of the program files in there as executable. If by chance you are looking to use a Ren'Py game on Linux that was built without the Linux files or had them stripped out, you can check out a thread I started a while back explaining one way of restoring them:
 
  • Like
Reactions: nekdo and SenMizeri

Palanto

Active Member
Game Developer
Oct 4, 2017
964
1,841
Well or just go and ask someone to use unren on a renpy game and pack it as a linux game with the renpy launcher again tada...
 

NandabaCanti

Active Member
Jan 4, 2018
677
754
@Palanto Games & @selectivepaperclip - While both of your alternatives will work a fair amount of the time, neither accounts for the Ren'Py version used by the game, which can cause some issues for games that rely on older depreciated calls that your installed version of Ren'Py or one snagged from another game may no longer support.
 
  • Like
Reactions: Palanto

anne O'nymous

I'm not grumpy, I'm just coded that way.
Modder
Donor
Respected User
Jun 10, 2017
10,978
16,236
[...] which can cause some issues for games that rely on older depreciated calls that your installed version of Ren'Py or one snagged from another game may no longer support.
This is not a problem. Ren'py have a very high backward compatibility and there's almost not a single thing as "depreciated calls". My variable viewer (updated soon if I finally find some free time :( ) works whatever the version between 6.15.7 (June 2013) and the last 7.0 ; and if he don't works with previous version it's only because I was too lazy to add the alternate property to game which haven't it.
The real problem come from the changes in the GUI and themes which need pictures that aren't anymore part of the SDK. But if you make a hybrid version of the SDK you should be able to make works any game initially made with version 6.14 and upper, over a version 7.0. It should works with even older versions, but with perhaps some issues due to the fact that they works with a Python version older than the 2.7.
In the future it will not stay true since apparently the author want to switch to Python 3.x for the 8.0 version. It will not affect backward compatibility of Ren'py language, but obviously will cause a lot of problem with the Python code added to the game.
 

xMentat

Newbie
Apr 14, 2018
73
71
When you build a distributable in RenPy, the default selected option is "PC: Windows and Linux" View attachment 113221
So pretty much any RenPy game that's exported for 'Windows' is likely to work on Linux as well, unless the dev deliberately checked 'Windows' instead of 'PC'.

The only real reason they might do that is to save the ~12MB of extra space that the packaged 32/64 bit Linux Python versions take up.

The majority of a RenPy game is cross-platform RenPy/Python script, so if a game doesn't have a .sh included you could probably Frankenstein it into working

I've suspected that for a while but haven't checked it out. I'm new to these things, although not new to programming! Thanks.
 

xMentat

Newbie
Apr 14, 2018
73
71
Er... Alright...

".sh" is a (useless, the shebang isn't here for dogs) default extension, initially used to mark scripts wrote for Bourne Shell, now extended for C shell and its successor tcsh. For Ren'py they are strict Bourne Shell scripts, which mean that you can make them run whatever the OS as long as you have a Bourne Shell, C Shell or TCSH interpreter. So, you can run then on Linux, any Unix and Unix-like (what MacOS X is), and Windows if you have the Win32 port of C Shell (or was it Bourne Shell ? I don't remember right now).
This said, to run a Ren'py game on Linux, what you need isn't a .sh script ; well, you need it since there's no ELF executable, but having it isn't enough. What you really need is that the libraries used by Ren'py (like LibPNG, libJPEG, etc) and the Python executable, were compiled for Linux. Which is obviously not the case for "windows only" distributions of a Ren'py Game. But, if you look closely, you'll see that really few Ren'py games are stated as "Win". The large majority of them are stated "Win/Linux" or, less frequently, "PC".
To know if it's a Windows only distribution or a Win/Linux one, just look at the end of the archive name. If it end with "-win", it's a Windows only distribution ; this one will never works on Linux even if you found a .sh file on it (which isn't the case anyway). But if it end with "-pc" it's a Win/Linux one, and so you can run it on Linux, as long as it itself run on an Intel architecture. On a side note, the presence of a .sh script isn't a good indicator, since both Linux and MacOS X distributions use the Bourne Shell script as launcher.

Oh, and by the way, don't invoke Linus, Bourne Shell was wrote in 1977, 14 years before the first release of Linux.
 

xMentat

Newbie
Apr 14, 2018
73
71
Thanks for your reply. I'm well aware of the history and usage of Unix and it's various shells but simplified in my original post. I guess my big mistake was assuming "PC" meant "Windows" which, while not true, is the case for most people who assume Windows = PC. And, Linux is by far and away the most used Unix type OS these days, given that Android is essentially Linux, so I don't apologise for mentioning Linus. I'm probably in a small minority who use Linux on a desktop but, hey ho. :). Thanks again for the response!
 

xMentat

Newbie
Apr 14, 2018
73
71
I use Linux exclusively, and have for over a decade now, I can say that probably around 2/3rds of the Ren'Py based games I've snagged from here have had the Linux files intact, though many of them required me to go into the ./lib/linux-x86_64 dir and flag all 5 of the program files in there as executable. If by chance you are looking to use a Ren'Py game on Linux that was built without the Linux files or had them stripped out, you can check out a thread I started a while back explaining one way of restoring them:
I did work that one out eventually when some games wouldn't run, slow on the uptake here! Many thanks for the reply.
 
  • Like
Reactions: NandabaCanti

xMentat

Newbie
Apr 14, 2018
73
71
I use Linux exclusively, and have for over a decade now, I can say that probably around 2/3rds of the Ren'Py based games I've snagged from here have had the Linux files intact, though many of them required me to go into the ./lib/linux-x86_64 dir and flag all 5 of the program files in there as executable. If by chance you are looking to use a Ren'Py game on Linux that was built without the Linux files or had them stripped out, you can check out a thread I started a while back explaining one way of restoring them:
Yes, I worked that one out by reading the error messages I got! Thanks!
 
Nov 24, 2018
62
48
Pardon the late reply, while completely agreeing with the statement that Windows-only distributions won't ever work out-of-the-box on Linux due to the missing binaries, I just want to mention that the Windows builds of RenPy games do pretty much always run inside Wine. So if you are willing to install Wine on your Linux this is an option to play those. I've yet to encounter a RenPy game which does not start in Wine (but then again, I only use it if there is no natively running build). In Wine I only encountered some small inconveniences like window mode resizing resulting in unbearable flickering. And if you do use Wine, think about replacing the renpy saves folder inside your Wine AppData directory with a symlink to the Linux RenPy saves folder.