Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 35 additions & 0 deletions ports/raceintospace/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
## Notes

Thanks to the [Race into Space team](https://github.com/raceintospace/raceintospace) for keeping this free software recreation of Interplay's *Buzz Aldrin's Race into Space* alive, a deep turn-based strategy game where you run the US or Soviet space program head-to-head in the race to land on the Moon.

## Controls

| Button | Action |
|--|--|
| Left Analog | Move mouse cursor |
| A | Left click |
| B | Enter (confirm) |
| X | Slow mouse (precision aiming) |
| D-Pad | Arrow keys (menu navigation) |
| Start | Enter (confirm) |
| Back | Escape (cancel/back) |
| L2 | Toggle on-screen keyboard (for save/player name entry) |
| R1 | Cycle keyboard charset (while on-screen keyboard is open) |

## Compile

Install build dependencies:

sudo apt-get install cmake libsdl1.2-dev libboost-dev libboost-test-dev libpng-dev libjsoncpp-dev libogg-dev libvorbis-dev libtheora-dev libphysfs-dev libcereal-dev

Clone and build:

git clone --recurse-submodules https://github.com/raceintospace/raceintospace.git
cd raceintospace
cmake --preset linux-release -DPBEM=OFF -DCMAKE_C_FLAGS=-fsigned-char -DCMAKE_CXX_FLAGS=-fsigned-char
cmake --build --preset linux-release

`-fsigned-char` is required on AArch64: plain `char` is unsigned by default there (signed on x86_64), and
several `cereal`-serialized struct fields (e.g. `mStr::Alt`/`PCat` in `src/game/data.h`, loaded from
`data/gamedata/mission.json`) hold negative values, which crashes with a RapidJSON `GetUint()` assertion
failure on the very first mission-data read without this flag.
65 changes: 65 additions & 0 deletions ports/raceintospace/Race Into Space.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
#!/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/raceintospace
BINARY=raceintospace.${DEVICE_ARCH}

cd $GAMEDIR

> "$GAMEDIR/log.txt" && exec > >(tee "$GAMEDIR/log.txt") 2>&1

ARCHIVE_FILES=("data-part1.tar.gz" "data-part2.tar.gz")
if [[ -f "${ARCHIVE_FILES[0]}" || -f "${ARCHIVE_FILES[1]}" ]]; then
if [[ -d 'data/' ]]; then
pm_message "Removing old game data"
$ESUDO rm -fR 'data/'
fi
pm_message "Extracting game data, this can take a few minutes..."
if gunzip -c "${ARCHIVE_FILES[0]}" | tar xf - && gunzip -c "${ARCHIVE_FILES[1]}" | tar xf -; then
pm_message "Extraction successful."
$ESUDO rm -f "${ARCHIVE_FILES[@]}"
else
pm_message "Error: Extraction failed."
sleep 5
exit 1
fi
elif [ ! -d 'data/' ]; then
pm_message "Error: No data directory present and archive files not found."
sleep 5
exit 1
fi

mkdir -p "$GAMEDIR/saves"

export LD_LIBRARY_PATH="$GAMEDIR/libs.${DEVICE_ARCH}:$LD_LIBRARY_PATH"
export SDL_GAMECONTROLLERCONFIG="$sdl_controllerconfig"

export BARIS_DATA="$GAMEDIR/data"
export BARIS_SAVE="$GAMEDIR/saves"

export OMNI_MODE=buffered
export OMNI_EVENT_MODE=auto
export OMNI_EMIT_RETURN=0
export OMNI_FONT="$GAMEDIR/fonts/LiberationSans-Regular.ttf"
export OMNI_FONT_SIZE=24

$GPTOKEYB2 "raceintospace" -c "$GAMEDIR/raceintospace.ini" &

pm_platform_helper "$GAMEDIR/$BINARY"

LD_PRELOAD="$GAMEDIR/libs.${DEVICE_ARCH}/libomni_osk.so${LD_PRELOAD:+:$LD_PRELOAD}" ./$BINARY

pm_finish
13 changes: 13 additions & 0 deletions ports/raceintospace/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>./Race Into Space.sh</path>
<name>Race Into Space</name>
<desc>Free software recreation of Buzz Aldrin's Race into Space, a turn-based strategy game where you run the US or Soviet space program in the race to land on the Moon, originally released by Interplay in 1993 and later open-sourced.</desc>
<releasedate>20250327T000000</releasedate>
<developer>Strategic Visions / Race into Space Team</developer>
<publisher>Open Source</publisher>
<genre>Strategy</genre>
<image>./raceintospace/screenshot.png</image>
</game>
</gameList>
33 changes: 33 additions & 0 deletions ports/raceintospace/port.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
{
"version": 4,
"name": "raceintospace.zip",
"items": [
"Race Into Space.sh",
"raceintospace"
],
"items_opt": [],
"attr": {
"title": "Race Into Space",
"porter": [
"Cebion"
],
"desc": "Free software recreation of Buzz Aldrin's Race into Space, a turn-based strategy game where you run the US or Soviet space program in the race to land on the Moon.",
"desc_md": null,
"inst": "Ready to run, no additional files needed. Game data is extracted from data.tar.gz on first launch.",
"inst_md": null,
"genres": [
"strategy"
],
"image": null,
"rtr": true,
"exp": false,
"runtime": [],
"store": [],
"availability": "full",
"reqs": [],
"arch": [
"aarch64"
],
"min_glibc": ""
}
}
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.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading
Loading