Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
systems:ports [2022/11/11 01:29] – Update FFLNSU info about V04 maionisystems:ports [2026/06/22 22:44] (current) – Added a GOG game installer example lbrpdx
Line 55: Line 55:
 </file> </file>
  
-Refresh the game list, and then launch your game. Most 3D games will spend some time generating shader caches when first booting up, so be patient at least on the first launch. For sanity's sake, you can check that your system has not frozen by moving your mouse around (if you have one connected). Shader compilation should not take longer than five minutes at most.+Save this script to the ''roms/ports'' folder, refresh the game list, and then launch the game. Most 3D games will spend some time generating shader caches when first booting up, so be patient at least on the first launch. For sanity's sake, you can check that your system has not frozen by moving your mouse around (if you have one connected). Shader compilation should not take longer than five minutes at most. 
 + 
 +<WRAP center round important> 
 +If using the [[:disk_image_compression#squashfs|SquashFS]] compression, this script file must be named ''run.sh'' and included in the root folder of the game's data itself in the ''.squashfs'' archive. 
 +</WRAP>
  
 If you'd like to see the actual files, you can install some native Linux ports in the [[:content_downloader|content downloader]]. Read below for some setup examples: If you'd like to see the actual files, you can install some native Linux ports in the [[:content_downloader|content downloader]]. Read below for some setup examples:
Line 86: Line 90:
 </WRAP> </WRAP>
  
 +==== Self-contained popular musical game: Clone Hero ====
 +
 +[[https://clonehero.net|Clone Hero]] is a free, but not opensource, Guitar Hero/Rock Band clone that works with many accessories. They provide a build for Linux x86_64, you won't be able to install it on a Raspberry Pi or other ARM-based boards.
 +
 +  - Go to the download page and download it on your Batocera machine.
 +  - Once downloaded, extract the '.tar' archive into ''roms/ports/CloneHero'' and you will end up with all the files installed into ''roms/ports/CloneHero/Standalone''.
 +  - Make sure the main app is exectuable (''chmod +x /userdata/roms/ports/CloneHero/Standalone/clonehero'')
 +  - Download the following script and save it to ''roms/ports/CloneHero.sh'': <file bash CloneHero.sh>
 +DIR="$(dirname "$(readlink -f "$0")")"
 +
 +cd "${DIR}/CloneHero/Standalone"
 +
 +unclutter-remote -s
 +./clonehero
 +unclutter-remote -h
 +</file> 
 +
 +<WRAP center round tip>
 +The ''unclutter-remote -s'' and ''unclutter-remote -h'' commands are to **s**how and **h**ide the mouse cursor respectively.
 +You will need a mouse to accept the initial terms the initial setup (guitar/controller configuration). Once your controller is correctly configured, you won't need a mouse any more to play Clone Hero.
 +</WRAP>
 +
 +  - Press ''[START]'' -> **GAME SETTINGS** -> **REFRESH GAMELISTS**.
 +  - Navigate to the "Ports" system, then launch "CloneHero".
 +
 +===FAQ Clone Hero for Batocera===
 +  * //Can I use a PS2 guitar?// Yes you can. I have a female PS2 connector to USB adapter and I just plugged my PS2 Guitar Hero controller into Batocera. Clone Hero could detect it, I just had to select the right controller and remap the buttons from there.
 +  * //Can I add my own songs?// You can add your own songs into the folder ''/userdata/system/.clonehero/Songs/''. If your /userdata partition support symbolic links, it's a good idea to link it to a more obvious directory. Once the songs are added, go to the menu ''SETTINGS'' -> ''GENERAL'' -> ''SCAN SONGS'' from there.
 +  * //Why can't I see my ''.mp4'' video backgrounds on Batocera why they work on Windows?// For licensing reasons, ''.mp4'' video backgrounds are not supported on Linux. To get around this, you can convert them to ''.webm'' with ''ffmpeg'', installed on your Batocera machine. Connect through SSH and CD to the directory then run the following command to convert ''video.mp4'' into ''video.webm'':<code>
 +ffmpeg -i video.mp4 -c:v libvpx -crf 10 -b:v 1M -c:a libvorbis video.webm
 +</code>
 +===Known compatible guitars and other music controllers===
 +^ Music controller ^ Original platform ^ Description ^
 +| React RTPS26 | PS2 with a generic PS2/PC USB converter | Tested on Batocera 43 with CH 1.1.0.6085 |
 +| Guitar Hero Live guitar | PS4 (blue USB dongle) | Tested on Batocera 43 with CH 1.1.0.6085 |
 +| Guitar Hero Live guitar | XBox 360 (green USB dongle) | Tested on Batocera 43 with CH 1.1.0.6085 |
 +| Guitar Hero/Band Hero guitar for Xbox360 (model 95905.805)| XBox 360 with a generic Xbox 360/PC USB converter | Tested on Batocera 43 with CH 1.1.0.6085 |
 ==== Complicated itch.io game example: Celeste ==== ==== Complicated itch.io game example: Celeste ====
  
Line 135: Line 176:
 </WRAP> </WRAP>
  
-<code bash TNMT.sh>+<code bash TMNT.sh>
 #!/bin/bash #!/bin/bash
 export LC_ALL=C export LC_ALL=C
Line 148: Line 189:
  
 Make the script executable: Make the script executable:
-<code>chmod +x /userdata/roms/ports/TNMTSR/TNMT.sh</code>+<code>chmod +x /userdata/roms/ports/TMNTSR/TMNT.sh</code>
 Update the gamelist and start the game via the ES its "Ports" section. Update the gamelist and start the game via the ES its "Ports" section.
  
Line 204: Line 245:
  
 Update gamelists and launch! Update gamelists and launch!
 +
 +==== Old 32-bit game ====
 +
 +For games which require 32-bit libraries and can't find them on their own:
 +
 +<file bash run.sh>
 +#!/bin/sh
 +cd "$(dirname "$(readlink -f "$0")")"
 + 
 +unclutter-remote -h
 +export LD_LIBRARY_PATH=/lib32
 +export LIBGL_DRIVERS_PATH=/lib32/dri
 +export SPA_PLUGIN_DIR="/lib32/spa-0.2:/usr/lib/spa-0.2"
 +export PIPEWIRE_MODULE_DIR="/lib32/pipewire-0.3:/usr/lib/pipewire-0.3"
 +exec ./start.sh
 +</file>
 +
 +==== Old Game Maker Studio game: Maldita Castilla ====
 +
 +Games written in older versions of Game Maker Studio will depend on a collection of 32-bit libraries not included with Batocera. (If the game's executable is just named ''runner'', that's a good sign that you have a GMS game... though some developers will rename it.)
 +
 +More broadly, if the ''file'' command on a more general-purpose Linux setup says that the game executable is an ''ELF 32-bit LSB executable, Intel 80386'', then these instructions will likely get it working, though they may be overkill.
 +
 +[[https://namethattech.wordpress.com/2020/09/04/from-gamemaker-to-ubuntu-14-16-18-and-beyond/|This blog post]] details how to build the required library bundle and includes a mention that, if you trust the author, you can just grab the ''lib'' folder and adapt the wrapper script from their [[https://juanitogan.itch.io/river-raid-squadron|River Raid Squadron]] game on Itch.io.
 +
 +(If both of those links die, you can just build the libraries the error messages complain about one-by-one until the game works.)
 +
 +If you place the ''lib'' folder inside the game folder, a suitable SH file will look something like this:
 +
 +<file sh Maldita Castilla.sh>
 +#!/bin/sh
 +DIR="$(dirname "$(readlink -f "$0")")"
 +
 +cd "${DIR}/.data/MalditaCastilla"
 +
 +unclutter-remote -h
 +export LD_LIBRARY_PATH=./lib:/lib32
 +export LIBGL_DRIVERS_PATH=/lib32/dri
 +export SPA_PLUGIN_DIR="/lib32/spa-0.2:/usr/lib/spa-0.2"
 +export PIPEWIRE_MODULE_DIR="/lib32/pipewire-0.3:/usr/lib/pipewire-0.3"
 +./runner
 +</file>
  
 ===== Installing the Java runtime environment ===== ===== Installing the Java runtime environment =====
Line 300: Line 383:
  
 Batocera's libraries are stored in ''/usr/lib/'', some games may also be hard-coding their paths and try searching in ''/lib'' for instance, necessitating changing the path told to the game to be inside of ''/usr'' instead. Batocera's libraries are stored in ''/usr/lib/'', some games may also be hard-coding their paths and try searching in ''/lib'' for instance, necessitating changing the path told to the game to be inside of ''/usr'' instead.
 +
 +==== I can't install GOG Linux native games ====
 +
 +Many GOG games come as a ''.sh'' installer, made for the usual Linux desktop distros. The installer expects to install desktop shortcuts and other utilities that don't exist in Batocera - and even if you specify to **not** install game shortcuts, some other dependencies can make the installer fail and delete all the previously installed game files. You need to stop the installer before it deletes those files.
 +
 +For example, let's install World of Goo. Read the license, agree to the terms and choose the default install path proposed as ''/userdata/system/GOG Games/World of Goo''. The install starts, files are getting copied until you face the error message below. 
 +
 +Once you see the "Failed to install desktop menu item" message, hit ''[CTRL][C]'' on your session to kill the installer. This signal is trapped and you need to press ''[ENTER]'' to quit the installer when prompted. With that, the game files are still installed on your system.
 +
 +<code>
 +(....)
 +gog_com-World_of_Goo_1.desktop: 100% (total progress: 99%)
 +NOTICE: Failed to install desktop menu item
 +[hit enter]
 +^C    <---- Hit [CTRL][C] in your session to kill the installer
 +NOTICE: BUG: fatal() called more than once!
 +[hit enter]   <---- Now hit [ENTER]
 +</code>
 +
 +Once the game files are installed, you can create a ''World_of_Goo.sh'' start up script in the Ports section:
 +<file sh /userdata/roms/ports/World_of_Goo.sh>
 +#!/bin/bash
 +cd "/userdata/system/GOG Games/World of Goo"
 +./start.sh
 +</file>
 +
 +
 +==== Other Known Bugs in Old Humble Bundle Linux Releases ====
 +
 +  * Some games (eg. Wizorb) will crash on startup if more than four joystick devices are present. (eg. If you have two dual-port controller adapters with one controller plugged into each, plus an X-Box 360 controller, and the adapters always make their ports visible to the host whether or not a controller is actually connected.)
 +  * Some games (eg. Jamestown) which include both 32-bit and 64-bit executables will require you specifically use the 32-bit version as the 64-bit binary crashes with no known fix.
 +  * If your game is XNA-based and you're getting a crash with the following error on startup, add an ''export TERM=vt100'' line to the SH file. <code>
 +System.TypeInitializationException: The type initializer for 'System.Console' threw an exception. ---> System.TypeInitializationException: The type initializer for 'System.ConsoleDriver' threw an exception. ---> System.Exception: Magic number is wrong: 542</code> The terminal type database's format got extended at some point and that error means that your game is too old to understand the extended-format entries that your terminal emulator is using to announce its capabilities.
  
 ==== I'm stuck and I can't quit the game! ==== ==== I'm stuck and I can't quit the game! ====
  • systems/ports.1668130163.txt.gz
  • Last modified: 4 years ago
  • by maioni