Table of Contents

RUN.SH

Utility script to run the game in MAME from a menu to test 5 different video modes

CODE

This code is an incomplete snapshot of a project in progress.

#!/bin/bash
export MAMEOPTS='-nodebug -window -nomouse -keepaspect -skip_gameinfo -resolution 2800x2000 -screen0 rgb' 
# Release Version
while [ "$CHOICE" != "q" ]
do
RNDELAY=$((RANDOM % 11))
echo "
[0] Build
[1] CoCo 1/2/2B with MC6847
[2] CoCo 1/2/2B with MC6847T1
[3] CoCo 1/2/2B with CoCoVGA
[4] CoCo 1/2/2B in RG6
[5] CoCo 3
[Q] Quit
Choose: "
read CHOICE
case "$CHOICE" in
0) ./build.sh ;;
1) mametrs cocoe  ${MAMEOPTS} -autoboot_delay $RNDELAY -autoboot_command 'POKE255,1\nLOADM"NOSTROMO.BIN":EXEC\n' -flop1 NOSTROMO.DSK ;;
2) mametrs coco2b ${MAMEOPTS} -autoboot_delay $RNDELAY -autoboot_command 'POKE255,2\nLOADM"NOSTROMO.BIN":EXEC\n' -flop1 NOSTROMO.DSK ;;
3) mametrs coco2b ${MAMEOPTS} -autoboot_delay $RNDELAY -autoboot_command 'POKE255,3\nLOADM"NOSTROMO.BIN":EXEC\n' -flop1 NOSTROMO.DSK ;;
4) mametrs coco2b ${MAMEOPTS} -autoboot_delay $RNDELAY -autoboot_command 'POKE255,4\nLOADM"NOSTROMO.BIN":EXEC\n' -flop1 NOSTROMO.DSK ;;
5) mametrs coco3h ${MAMEOPTS} -ramsize 2048k -autoboot_delay $RNDELAY -autoboot_command 'RGB\nPOKE255,5\nLOADM"NOSTROMO.BIN":EXEC\n' -flop1 NOSTROMO.DSK ;;
q) echo "Goodbye!" ;;
*) echo "Huh?" ;;
esac
done

DISCUSSION

Please ping me on the Discord #programming channel if you have questions or comments about this.

RTS

Return to Nostromo