Skip to content

Commit

Permalink
Merge pull request PortsMaster#1163 from tabreturn/tiny-world-racing
Browse files Browse the repository at this point in the history
Tiny World Racing
  • Loading branch information
JanTrueno authored Jan 9, 2025
2 parents c080bec + 9ef4114 commit 1683217
Show file tree
Hide file tree
Showing 22 changed files with 873 additions and 0 deletions.
14 changes: 14 additions & 0 deletions ports/tinyworldracing/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
Thanks to [Chequered Ink](https://ci.itch.io) for creating this fantastic game, which you can get at [itch.io](https://ci.itch.io/tiny-world-racing)

*If you plan to purchase this, consider buying their bundle for $10, which includes several other ports.*


# Controls

| Button | Action |
| ------------- | ---------- |
| D-PAD/L-STICK | Steer |
| B/R1 | Accelerate |
| A/L1 | Brake |
| X/Y | Use item |
| START | Pause |
55 changes: 55 additions & 0 deletions ports/tinyworldracing/Tiny World Racing.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
#!/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

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

# CD and set permissions
cd $GAMEDIR
> "$GAMEDIR/log.txt" && exec > >(tee "$GAMEDIR/log.txt") 2>&1
$ESUDO chmod +x $GAMEDIR/gmloadernext.aarch64
$ESUDO chmod +x $GAMEDIR/tools/splash

# Exports
export LD_LIBRARY_PATH="$GAMEDIR/libs.aarch64:$LD_LIBRARY_PATH"
export SDL_GAMECONTROLLERCONFIG="$sdl_controllerconfig"

# Check if there are any audio files in the ./gamedata directory
if [ -n "$(ls ./gamedata/*.ogg 2>/dev/null)" ]; then
mkdir -p ./assets
mv ./gamedata/*.ogg ./assets/ 2>/dev/null
pm_message "Moved .ogg files from ./gamedata to ./assets/"
zip -r -0 ./tinyworldracing.port ./assets/
pm_message "Zipped contents to .port file"
rm -Rf ./assets/
fi

# Delete unneeded files and rename data.win
rm -f gamedata/*.{dll,exe}
[ -f "./gamedata/data.win" ] && mv gamedata/data.win gamedata/game.droid

# Display loading splash
$ESUDO ./tools/splash "splash.png" 2000 &

# Assign configs and load the game
$GPTOKEYB "gmloadernext.aarch64" -c "tinyworldracing.gptk" &
pm_platform_helper "$GAMEDIR/gmloadernext.aarch64"
./gmloadernext.aarch64 -c gmloader.json

# Cleanup
pm_finish
13 changes: 13 additions & 0 deletions ports/tinyworldracing/gameinfo.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<?xml version="1.0" encoding="utf-8"?>
<gameList>
<game>
<path>./Tiny World Racing.sh</path>
<name>Tiny World Racing</name>
<desc>Blast your way through a variety of environments in 20 tracks across 5 different tournaments. From crumbling castles to volcanic islands, you'll need to master all kinds of terrain to become the world's best racer.</desc>
<releasedate>20201127T000000</releasedate>
<developer>Chequered Ink</developer>
<publisher>Self-published</publisher>
<genre>Racing</genre>
<image>./tinyworldracing/screenshot.png</image>
</game>
</gameList>
28 changes: 28 additions & 0 deletions ports/tinyworldracing/port.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
{
"version": 3,
"name": "tinyworldracing.zip",
"items": [
"Tiny World Racing.sh",
"tinyworldracing"
],
"items_opt": null,
"attr": {
"title": "Tiny World Racing",
"porter": [
"tabreturn"
],
"desc": "Blast your way through a variety of environments in 20 tracks across 5 different tournaments. From crumbling castles to volcanic islands, you'll need to master all kinds of terrain to become the world's best racer.",
"desc_md": null,
"inst": "Purchase the full game at itch.io (https://ci.itch.io/tiny-world-racing). Download and extract the 'Tiny World Racing - as a compressed ZIP' version, and copy the game files to this port's gamedata folder.",
"inst_md": "Purchase the full game at [itch.io](https://ci.itch.io/tiny-world-racing). Download and extract the *Tiny World Racing - as a compressed ZIP* version, and copy the game files to this port's *gamedata* folder.",
"genres": [
"racing"
],
"image": {},
"rtr": false,
"exp": false,
"runtime": null,
"reqs": [],
"arch": ["aarch64"]
}
}
Binary file added ports/tinyworldracing/screenshot.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Empty file.
7 changes: 7 additions & 0 deletions ports/tinyworldracing/tinyworldracing/gmloader.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"save_dir" : "gamedata",
"apk_path" : "tinyworldracing.port",
"show_cursor" : false,
"disable_controller" : false,
"force_platform" : "os_windows"
}
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading

0 comments on commit 1683217

Please sign in to comment.