diff --git a/ports/brotato/Brotato.sh b/ports/brotato/Brotato.sh new file mode 100644 index 0000000000..07dd29e5d7 --- /dev/null +++ b/ports/brotato/Brotato.sh @@ -0,0 +1,64 @@ +#!/bin/bash + +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 + +[ -f "${controlfolder}/mod_${CFW_NAME}.txt" ] && source "${controlfolder}/mod_${CFW_NAME}.txt" + +get_controls + +GAMEDIR=/$directory/ports/brotato/ +CONFDIR="$GAMEDIR/conf/" + +# Ensure the conf directory exists +mkdir -p "$GAMEDIR/conf" + +# Set the XDG environment variables for config & savefiles +export XDG_CONFIG_HOME="$CONFDIR" +export XDG_DATA_HOME="$CONFDIR" +export SDL_GAMECONTROLLERCONFIG="$sdl_controllerconfig" + +cd $GAMEDIR +> "$GAMEDIR/log.txt" && exec > >(tee "$GAMEDIR/log.txt") 2>&1 + +runtime="frt_3.5.2" +if [ ! -f "$controlfolder/libs/${runtime}.squashfs" ]; then + # Check for runtime if not downloaded via PM + if [ ! -f "$controlfolder/harbourmaster" ]; then + pm_message "This port requires the latest PortMaster to run, please go to https://portmaster.games/ for more info." + sleep 5 + exit 1 + fi + + $ESUDO $controlfolder/harbourmaster --quiet --no-check runtime_check "${runtime}.squashfs" +fi + +# Setup Godot +godot_dir="$HOME/godot" +godot_file="$controlfolder/libs/${runtime}.squashfs" +$ESUDO mkdir -p "$godot_dir" +$ESUDO umount "$godot_file" || true +$ESUDO mount "$godot_file" "$godot_dir" +PATH="$godot_dir:$PATH" + +export FRT_NO_EXIT_SHORTCUTS=FRT_NO_EXIT_SHORTCUTS + +[ -f "./gamedata/Brotato.pck" ] && mv gamedata/Brotato.pck gamedata/brotato.pck + +$GPTOKEYB "$runtime" -c "./brotato.gptk" & +pm_platform_helper "$godot_dir/$runtime" +"$runtime" $GODOT_OPTS --main-pack "gamedata/brotato.pck" + +$ESUDO umount "$godot_dir" +pm_finish \ No newline at end of file diff --git a/ports/brotato/README.md b/ports/brotato/README.md new file mode 100644 index 0000000000..27ee7b5cc6 --- /dev/null +++ b/ports/brotato/README.md @@ -0,0 +1,14 @@ +## Notes + +Thanks to [Blobfish Games](https://www.blobfish.dev/) for making this wonderful roguelite. + +The DLC from Steam are not compatible with the Epic version of the game that is used in this port. +Brotato wont run good on anything lower than a rk3588 + +## Controls + +| Button | Action | +|--|--| +|DPad/Lstick|Movement| + + diff --git a/ports/brotato/brotato/brotato.gptk b/ports/brotato/brotato/brotato.gptk new file mode 100644 index 0000000000..d7d7fbb407 --- /dev/null +++ b/ports/brotato/brotato/brotato.gptk @@ -0,0 +1,15 @@ +start = escape +guide = enter + +a = enter +b = enter + +up = up +down = down +left = left +right = right + +left_analog_up = up +left_analog_down = down +left_analog_left = left +left_analog_right = right diff --git a/ports/brotato/cover.png b/ports/brotato/cover.png new file mode 100644 index 0000000000..31f443027c Binary files /dev/null and b/ports/brotato/cover.png differ diff --git a/ports/brotato/gameinfo.xml b/ports/brotato/gameinfo.xml new file mode 100644 index 0000000000..e509a551cf --- /dev/null +++ b/ports/brotato/gameinfo.xml @@ -0,0 +1,12 @@ + + + + ./Brotato.sh + Brotato + Brotato is a top-down arena shooter roguelite where you play as a potato wielding up to six weapons to fend off alien hordes. Customize traits and items to survive until help arrives. + 20230723T000000 + Blobfish Games + Rougelite/Shooter + ./brotato/cover.png + + \ No newline at end of file diff --git a/ports/brotato/port.json b/ports/brotato/port.json new file mode 100644 index 0000000000..d816ddd471 --- /dev/null +++ b/ports/brotato/port.json @@ -0,0 +1,31 @@ +{ + "version": 3, + "name": "brotato.zip", + "items": [ + "Brotato.sh", + "brotato" + ], + "items_opt": [], + "attr": { + "title": "Brotato", + "porter": [ + "Damian2809" + ], + "desc": "Brotato is a top-down arena shooter roguelite where you play as a potato wielding up to six weapons to fend off alien hordes. Customize traits and items to survive until help arrives.", + "desc_md": null, + "inst": "Buy and download the game of Epic https://store.epicgames.com/en-US/p/brotato-ed4097\nCopy the brotato.pck to brotato/gamedata folder", + "inst_md": null, + "genres": [ + "action" + ], + "image": null, + "rtr": false, + "exp": false, + "runtime": "frt_3.5.2.squashfs", + "reqs": [ + "ultra" + ], + "arch": [], + "min_glibc": "" + } +} \ No newline at end of file diff --git a/ports/brotato/screenshot.jpg b/ports/brotato/screenshot.jpg new file mode 100644 index 0000000000..58cc304cec Binary files /dev/null and b/ports/brotato/screenshot.jpg differ