Undertale on RG351P and RG351M

Last updated: 13MAY2021 (see Changelog for details)

Today we’re going to install and play Undertale on the RG351P and RG351M thanks to the AnberPorts app. Installing this game is a little tricky, because it uses assets from the Linux version of Undertale. In this guide I’ll show you how to extract those Linux files using a Windows PC.

** Update (13MAY2021): Some people smarter than me in the community figured out an even easier way to install this game, see the “Simple conversion process” section below. **

Purchase and download Undertale

In order to run Undertale on your favorite retro device, you need to have the retail game assets. I recommend purchasing the game from GOG.com, where you can easily grab the Linux installer file, which has the exact assets you need. You cannot extract the correct assets from the PC or Mac versions of the game, you need the Linux version. I have also been told that the Humble Store version of the game is already pre-extracted, which is even easier, but I have not tested this myself.

Once you have purchased the game from GOG.com, it will show up in your library. Go into the Games section on your profile, and click the arrow at the bottom-right of your Undertale game, and select “View Downloads”. Change the system to Linux, and then click on the link under “Download Game Installers”. It will be a 128MB file in .sh format. Save that onto your PC.

Install AnberPorts and prep the Undertale port

If you don’t have AnberPorts already, go to this page and download the zip file. You can’t miss it, it’s a big ‘ole button. Unzip this file, and inside you’ll find an AnberPorts folder and an anberports.sh file.

Put your RG351P or RG351M microSD card into your PC. On the EASYROMS (ArkOS) or GAMES (351ELEC) partition of your device’s SD card, find the “ports” folder, and place these two AnberPorts files in there. Place the SD card back into your device, and power it on.

Navigate to the Ports section, then launch AnberPorts. While connected to WiFi, select the “Update” option and go through the prompts. It’ll kick you out of AnberPorts, go back into it, and then go to the “Games” section. There you will see a list of all sorts of ports you can install. If you’re interested in installing any of these other ports, check out this page from the AnberPorts wiki page which will show you the exact retail files you need in order to run each game.

Head to the Undertale section, and then press “A” to download and install the game launcher. You’ll need to be connected to WiFi for this step, too. Now that we have a means to run the game, we need to add the Undertale game assets.

Simple conversion process (new as of 13MAY2021)

In the video above (and the instructions below), I show you how to install the Linux version of the game on your Windows PC so that you can extract the assets. Turns out that the process is even easier. Thanks to Christian_Haitian (ArkOS developer) for turning me on to this fix.

  • Take the Linux game install file from GOG.com (the one in .sh format that is 128MB), and change the file extension from .sh to .gz.
  • Next, use 7zip to open the file, and to to the \data\noarch\game\assets folder and copy all of its contents to your /roms/ports/undertale/assets folder.
  • Proceed directly to the “Success!” section below, you’re done!

Install Debian for Windows 10 (old version)

This is the old method, and it still works, and it’s a little fun. But at this point, it’s unecessary thanks to the fix highlighted above. If you still want to learn how to install Linux on your Windows PC and “install” a Linux game on your PC, here you go:

On your PC, go to the Microsoft Store, and then search for “Debian“. Install this free app, and then try and launch it. It will tell you that you need a Windows Subsystem for Linux (WSL). Head to this page, and in the “Manual Installation Steps” section, you’ll see the following code:

dism.exe /online /enable-feature /featurename:VirtualMachinePlatform /all /norestart

Go ahead and copy this code. Next, in your Windows Start Menu, search for the word “Powershell” and when the app pops up, right-click on it and select “Run as Administrator” and confirm the prompts. Inside PowerShell, paste that code above, and hit Enter. Once that is done, close out your windows and restart your PC.

Once you’ve rebooted, start up Debian again, and this time it will launch and install. It will prompt you to create a username and password.

Extract the Undertale assets

Open up the folder where you installed the Linux version of Undertale (the 128mb .sh file), and keep that window open and handy. Open up Debian and type the following:

/mnt/c/

Next, grab that .sh file and drag it into the Debian window. It will populate the rest of the code with the location of the .sh file, but you need to make some alterations to it. Change all of the backslashes to forward slashes, and remove the “C:/” from the code. Your final code will look something like this (assuming you put the .sh file in a folder named “undertale” on your Desktop):

/mnt/c/Users/(username)/Desktop/undertale/undertale_en_1_08_18328.sh

Hit Enter and you’ll be greeted by the user license. You will need to confirm “Y” that you want to see 21 more lines, just keep hitting Y and Enter until you’re at the bottom, when it asks you to accept the license. Next it will ask you to confirm the destination. Just press “1” and Enter. It will then ask you to create shortcuts, press “1” and Enter and then “2” and Enter to deselect these. Finally, press Enter to finish the install.

Now you need to find the installed files so you can grab those assets. Note that you will need to enable hidden files in order to find the “AppData” folder. Here is the file path of your assets:

This PC / Local Disk / Users / (username) / AppData / Local / Packages / TheDebianProject… / LocalState / rootfs / home / user / GOG Games / Undertale / game

Inside that folder you will find an “assets” folder and a “runner” file. Copy these files over to the ports/Undertale folder on your device’s SD card (within the EASYROMS or GAMES partition).

Success!

You, my friend, have now installed Undertale onto your device. All you have to do is put the SD card back into your device, navigate to the Ports section, and launch Undertale. Here are some keys:

SELECT = exit game
(hold) START = exit game (but doesn't really work)

Notes

I’ve been told that if you purchase Undertale via the Humble Store, it comes with a Linux version that is already extracted (meaning that you can skip the Debian/extract steps above). I haven’t personally tested this, but I have verified that other Linux versions of games do have the extracted files.

It is also possible to use the Windows version of Undertale on your RG351 device, but results will vary based on the game version you have installed. I haven’t tested this myself. This assumes that you have already installed AM2R via AnberPorts on your device. Here are the steps

  • copy runner from /roms/ports/am2r folder over to /roms/ports/undertale folder
  • create /roms/ports/undertale/assets subfolder and put all .ogg files in there
  • rename mus_bgflameA.ogg to mus_bgflamea.ogg for case sensitivity
  • and finally rename data.win to game.unx

Changelog

13MAY2021
– added simple conversion process for Linux file

22MAR2021
– published guide
– added notes about Humble Store and Windows extract based on feedback

12 thoughts on “Undertale on RG351P and RG351M

  1. Wow! I have the Steam version, but I also use Linux for gaming so I assume I would be able to extract the assets via my installed Linux version. I’ll try later, thanks for the guide! By the way if anyone wants to try running Linux on your computer, it’s not that scary πŸ™‚ and you can still keep Windows around for a few things if needed.

    Like

  2. You might be able to extract the assets without going through WSL, specifically rename the .sh file to .gz and open it in 7-Zip, the assets should be under \data\noarch\game\, I don’t own the game on GOG so I can’t double check this.

    For Steam you can open the console via Win+R, type the following: steam://open/console
    A console tab should show up in the Steam client, where you can enter the command: download_depot 391540 391544
    Expect the following output:
    Downloading depot 391544 (119 MB) ..
    Depot download complete : “C:\Program Files (x86)\Steam\steamapps\content\app_391540\depot_391544” (227 files, manifest 5730345506996883260)

    the assets can be found in the folder Steam supplied, which might be on a different drive depending on your settings

    Like

    1. Great tip. Changing the extension and unpacking with 7-zip is much easier and more user friendly way of getting the assets.

      Like

  3. This is great! For anyone else wondering, steam console syntax is download_depot . So if you look up a game like Stardew Valley on steamdb.info, you can see the app_id in the URL (413150) and the Linux depot ID by checking the depots on the left side (413153).

    I still don’t have my device, so hopefully I’ll be able to test if this works soon…

    Like

  4. Anyone managed to make it work on 351ELEC ? I have anberports installed and assets extracted but everytime i try to run Undertale is shows the “Downloading,…” screen and goes back to list of games at Anberports.

    Like

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s