aboutsummaryrefslogtreecommitdiff
path: root/games/chexquest3/chexquest3.sh
diff options
context:
space:
mode:
Diffstat (limited to 'games/chexquest3/chexquest3.sh')
-rw-r--r--games/chexquest3/chexquest3.sh27
1 files changed, 27 insertions, 0 deletions
diff --git a/games/chexquest3/chexquest3.sh b/games/chexquest3/chexquest3.sh
new file mode 100644
index 0000000000000..9c374ef939f98
--- /dev/null
+++ b/games/chexquest3/chexquest3.sh
@@ -0,0 +1,27 @@
+#!/bin/bash
+
+# Wrapper script for chexquest3, part of the SlackBuilds.org project.
+# Finds a usable Doom engine and uses it to run the game.
+
+# The IWAD. Actually, for some reason, its header defines it as a PWAD.
+# But it really is an IWAD. Go figure.
+WAD=/usr/share/games/doom/chex3.wad
+
+# The list is restricted to engines that (a) are on SBo, and (b) can
+# actually play Chex Quest 3.
+
+# These were tested, and don't work:
+# chocolate-doom crispy-doom odamex prboom prboom-plus doomretro doomsday
+
+# These were tested, and do work... though skulltag has issues.
+ENGINES="gzdoom zdoom skulltag"
+
+# And we're off to the races...
+for eng in $ENGINES; do
+ if /bin/which $eng &>/dev/null; then
+ exec $eng -iwad $WAD "$@"
+ fi
+done
+
+echo "Can't find any of $ENGINES, can't run game." 1>&2
+exit 1