Skip to content

Commit

Permalink
Merge pull request #878 from JeodC/deltarune
Browse files Browse the repository at this point in the history
  • Loading branch information
JeodC authored Oct 30, 2024
2 parents bab04d4 + aa53e03 commit 00127fa
Show file tree
Hide file tree
Showing 28 changed files with 949 additions and 0 deletions.
60 changes: 60 additions & 0 deletions ports/deltarune/Deltarune.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
XDG_DATA_HOME=${XDG_DATA_HOME:-$HOME/.local/share}

if [ -d "/opt/system/Tools/PortMaster/" ]; then
controlfolder="/opt/system/Tools/PortMaster"
elif [ -d "/opt/tools/PortMaster/" ]; then
controlfolder="/opt/tools/PortMaster"
elif [ -d "$XDG_DATA_HOME/PortMaster/" ]; then
controlfolder="$XDG_DATA_HOME/PortMaster"
else
controlfolder="/roms/ports/PortMaster"
fi

source $controlfolder/control.txt
export PORT_32BIT="Y"
[ -f "${controlfolder}/mod_${CFW_NAME}.txt" ] && source "${controlfolder}/mod_${CFW_NAME}.txt"
get_controls

# Variables
GAMEDIR="/$directory/ports/deltarune"

# Exports
export LD_LIBRARY_PATH="/usr/lib32:$GAMEDIR/libs32:$GAMEDIR/libs":$LD_LIBRARY_PATH
export PATCHER_FILE="$GAMEDIR/tools/patchscript"
export PATCHER_GAME="$(basename "${0%.*}")" # This gets the current script filename without the extension
export PATCHER_TIME="2 to 5 minutes"

export GMLOADER_DEPTH_DISABLE=1
export GMLOADER_SAVEDIR="$GAMEDIR/gamedata/"
export GMLOADER_PLATFORM="os_linux"

# CD and set permissions
cd $GAMEDIR
> "$GAMEDIR/log.txt" && exec > >(tee "$GAMEDIR/log.txt") 2>&1
$ESUDO chmod +x -R $GAMEDIR/*

# dos2unix in case we need it
dos2unix "$GAMEDIR/tools/gmKtool.py"
dos2unix "$GAMEDIR/tools/Klib/GMblob.py"
dos2unix "$GAMEDIR/tools/patchscript"

# Check if patchlog.txt to skip patching
if [ ! -f patchlog.txt ]; then
if [ -f "$controlfolder/utils/patcher.txt" ]; then
source "$controlfolder/utils/patcher.txt"
$ESUDO kill -9 $(pidof gptokeyb)
else
echo "This port requires the latest version of PortMaster." > $CUR_TTY
fi
else
echo "Patching process already completed. Skipping."
fi

# Run game
echo "Loading, please wait..." > $CUR_TTY
$GPTOKEYB "gmloader" -c "deltarune.gptk" &
pm_platform_helper "$GAMEDIR/game.apk"
./gmloader game.apk

# Cleanup
pm_finish
8 changes: 8 additions & 0 deletions ports/deltarune/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
## Installation
Download the Windows version from https://tobyfox.itch.io/deltarune and unzip to `ports/deltarune/gamedata`.

## Thanks
TobyFox -- The absolutely amazing game
JohnnyOnFlame -- GMLoader and TextureRepacker via UTMT
Cyril aka kotzebuedog -- GMTools audio patcher
Testers & Devs from the PortMaster Discord
Binary file added ports/deltarune/cover.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
14 changes: 14 additions & 0 deletions ports/deltarune/deltarune/deltarune.gptk
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
back = \"
start = \"
up = \"
down = \"
left = \"
right = \"
left_analog_up = \"
left_analog_down = \"
left_analog_left = \"
left_analog_right = \"
a = \"
b = \"
x = \"
y = \"
Binary file added ports/deltarune/deltarune/game.apk
Binary file not shown.
Binary file added ports/deltarune/deltarune/gamedata/splash.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added ports/deltarune/deltarune/gmloader
Binary file not shown.
Binary file added ports/deltarune/deltarune/libc++_shared.so
Binary file not shown.
Binary file added ports/deltarune/deltarune/libs/libFLAC.so.8
Binary file not shown.
Binary file added ports/deltarune/deltarune/libs/libcrypto.so.1.1
Binary file not shown.
Binary file added ports/deltarune/deltarune/libs/liblzma.so.5
Binary file not shown.
Binary file added ports/deltarune/deltarune/libs/libogg.so.0
Binary file not shown.
Binary file added ports/deltarune/deltarune/libs/libopenal.so.1
Binary file not shown.
Binary file added ports/deltarune/deltarune/libs/libvorbis.so.0
Binary file not shown.
Binary file added ports/deltarune/deltarune/libs/libvorbisenc.so.2
Binary file not shown.
Binary file added ports/deltarune/deltarune/libs/splash
Binary file not shown.
Binary file added ports/deltarune/deltarune/libs32/libcrypto.so.1.1
Binary file not shown.
Binary file added ports/deltarune/deltarune/libs32/libzip.so.5
Binary file not shown.
Loading

0 comments on commit 00127fa

Please sign in to comment.