Unren.bat Bash port (Linux, macOS, *BSD) v1.0.11u

kirikirifan

Member
Jul 4, 2020
144
150
193
Someone may have already made an updated version of https://f95zone.to/threads/unren-for-macos-and-linux-v0-8-2.16887 but I wasn't able to find anything so I made one for myself.
Largely ported from batch using Gemini 3.0 Pro. Thanks Google and thanks Sam for Unren.bat.


Usage:
- Drop the script in the main game folder (Windows, Linux, FreeBSD)
- Run the script from anywhere and give it the game path, by ie. dragging and dropping the app/folder (MacOS + aforementioned)



RPYC decompilation works with Ren'Py 8.4 (8.5 untested) games thanks to and Madeddy.


To update the embedded unrpyc in the future, just clone/download the repo from GitHub, save in a zip unrenpyc.py and all files inside decompiler/ (without including the decompiler folder itself, all files must be in the "root" of the zip), get its base64 string, and replace the original defined at the top of UnRen.command in decompzip_py3.
no zip for rpatool, it's one file, just download rpatool.py and replace the base64 string.

This should work on Windows with Cygwin, MSYS2, WSL etc.

Dependencies: bash, unzip
Ren'Py versions tested: 8.4, 7.5 (the two most problematic)

Tested only on Linux, but it should work on macOS too now.
 
Last edited:

Lamantin

Newbie
May 4, 2018
90
50
197
Doesn't seem to work on Mac, or I'm doing something wrong.

Code:
base64: invalid argument /Users/XXX/Documents/Jeux/TownOfMagic.app/Contents/Resources/autorun/_rpatool.py.tmp
Usage:    base64 [-Ddh] [-b num] [-i in_file] [-o out_file]
  -b, --break    break encoded string into num character lines
  -Dd, --decode   decodes input
  -h, --help     display this message
  -i, --input    input file (default: "-" for stdin)
  -o, --output   output file (default: "-" for stdout)
base64: invalid argument /Users/XXX/Documents/Jeux/TownOfMagic.app/Contents/Resources/autorun/_rpatool2.py.tmp
Usage:    base64 [-Ddh] [-b num] [-i in_file] [-o out_file]
  -b, --break    break encoded string into num character lines
  -Dd, --decode   decodes input
  -h, --help     display this message
  -i, --input    input file (default: "-" for stdin)
  -o, --output   output file (default: "-" for stdout)
Working in: "/Users/weide/Documents/Jeux/TownOfMagic.app/Contents/Resources/autorun/game"
   + Unpacking "audio.rpa"
   + Unpacking "images1.rpa"
   + Unpacking "images2.rpa"
   + Unpacking "scripts.rpa"
Summary: (4) files newly unpacked

 ----------------------------------------------------

   Finished!
And when I check the game folder, nothing is unpacked
 

kirikirifan

Member
Jul 4, 2020
144
150
193
Doesn't seem to work on Mac, or I'm doing something wrong.

Code:
base64: invalid argument /Users/XXX/Documents/Jeux/TownOfMagic.app/Contents/Resources/autorun/_rpatool.py.tmp
Usage:    base64 [-Ddh] [-b num] [-i in_file] [-o out_file]
  -b, --break    break encoded string into num character lines
  -Dd, --decode   decodes input
  -h, --help     display this message
  -i, --input    input file (default: "-" for stdin)
  -o, --output   output file (default: "-" for stdout)
base64: invalid argument /Users/XXX/Documents/Jeux/TownOfMagic.app/Contents/Resources/autorun/_rpatool2.py.tmp
Usage:    base64 [-Ddh] [-b num] [-i in_file] [-o out_file]
  -b, --break    break encoded string into num character lines
  -Dd, --decode   decodes input
  -h, --help     display this message
  -i, --input    input file (default: "-" for stdin)
  -o, --output   output file (default: "-" for stdout)
Working in: "/Users/weide/Documents/Jeux/TownOfMagic.app/Contents/Resources/autorun/game"
   + Unpacking "audio.rpa"
   + Unpacking "images1.rpa"
   + Unpacking "images2.rpa"
   + Unpacking "scripts.rpa"
Summary: (4) files newly unpacked

----------------------------------------------------

   Finished!
And when I check the game folder, nothing is unpacked
oops base64 on macOS takes slightly different arguments. Let me know if this works.
 

poiuylkjhmnb

New Member
Nov 17, 2024
1
6
97
Someone may have already made an updated version of https://f95zone.to/threads/unren-for-macos-and-linux-v0-8-2.16887 but I wasn't able to find anything so I made one for myself.
Largely ported from batch using Gemini 3.0 Pro. Thanks Google and thanks Sam for Unren.bat.


Usage:
- Drop the script in the main game folder (Windows, Linux, FreeBSD)
- Run the script from anywhere and give it the game path, by ie. dragging and dropping the app/folder (MacOS + aforementioned)



RPYC decompilation works with Ren'Py 8.4 (8.5 untested) games thanks to and Madeddy.


To update the embedded unrpyc in the future, just clone/download the repo from GitHub, save in a zip unrenpyc.py and all files inside decompiler/ (without including the decompiler folder itself, all files must be in the "root" of the zip), get its base64 string, and replace the original defined at the top of UnRen.command in decompzip_py3.
no zip for rpatool, it's one file, just download rpatool.py and replace the base64 string.

This should work on Windows with Cygwin, MSYS2, WSL etc.

Dependencies: bash, unzip
Ren'Py versions tested: 8.4, 7.5 (the two most problematic)

Tested only on Linux, but it should work on macOS too now.
Holy cow this is a life saver. Thanks bro!