HP Papertape Basic Games - April 2024
=====================================

Most of these were extracted from the "absfiles.zip" collection, only the
programs that run on the stock HPBASIC are included here (no overlay stuff).
BEASTIPT, OTHELL8K, PATTERN and WUMPUSPT were copied from the "hpbapps.zip"
collection.

These programs are not period-authentic. Most of them were converted to
papertape basic from other programs, often with extensive modifications
to fix the formatting, remove string usage etc as there were very few
published games that would run unmodified on plain HP papertape basic.
MANDPL1, OTHELL8K, OTHPT2 and PATTERN are new programs that I wrote.
Details are in the initial REM statements.

Some of the programs have been renamed from their absfiles.zip counterparts
to match the files included with the HP2100 SimH_cpanel distribution from:
https://github.com/rsanchovilla/SimH_cpanel/blob/master/test_run/HP2100/HP2100.zip
(47 megabyte download) Be sure to check out the other simulators from:
https://github.com/rsanchovilla/SimH_cpanel
(2.2 gigabyte zip to download all)

These simulators (as far as I can tell) are Windows-only but they are
pre-compiled and work fine in Linux using wine, for my Ubuntu 20.04 system
I made a "run_wineconsole" script containing...

#!/bin/bash
[ -f "$1" ] && cd $(dirname "$1")
wineconsole "$1"

...then associated .bat files to it so I can just double-click the batch
files to run them.

To use these with SimH_cpanel HP2100, copy these files to the
HP2100/sw/Basic/ptbasic/games directory (overwrite or skip existing)
then add the following files... (cut between the dashed lines)

------ file "HP2100/PaperTape Basic Games2.bat" ---------------------
@echo off
title %~n0
cd sw
:: uncomment just one line to select CPU...
::hp2100 HP_cpanel.ini  2116B   Basic/ptbasic   run_games2.ini
hp2100 HP_cpanel.ini  2116C   Basic/ptbasic   run_games2.ini
::hp2100 HP_cpanel.ini  2100A   Basic/ptbasic   run_games2.ini
::hp2100 HP_cpanel.ini  2100S   Basic/ptbasic   run_games2.ini
::hp2100 HP_cpanel.ini  21MXM   Basic/ptbasic   run_games2.ini
::hp2100 HP_cpanel.ini  21MXE   Basic/ptbasic   run_games2.ini
::hp2100 HP_cpanel.ini  1000M   Basic/ptbasic   run_games2.ini
::hp2100 HP_cpanel.ini  1000E   Basic/ptbasic   run_games2.ini
::hp2100 HP_cpanel.ini  1000F   Basic/ptbasic   run_games2.ini
---------------------------------------------------------------------

(the 21MXM is the fastest but the 2116C has better blinkenlights)

------ file "HP2100/sw/Basic/ptbasic/run_games2.ini" ----------------
set clk sc=10
set tty sc=11
set ptr sc=12
set ptp sc=13

; set tty autolf

att ptr -q basic.abs
boot ptr

reset
go 100 until "READY"

att ptr -q games/1_MENU.txt

send "PTAPE\r"

go until "READY" 

expect "LOAD: LUNAR LANDER\r"     att ptr -q games/LANDERPT.txt
expect "LOAD: STAR TREK\r"        att ptr -q games/TREKPT.txt
expect "LOAD: WUMPUS ADVENTURE\r" att ptr -q games/WUMPUSPT.txt
expect "LOAD: HAMURABI\r"         att ptr -q games/HAMRBIPT.txt
expect "LOAD: BEASTI\r"           att ptr -q games/BEASTIPT.txt
expect "LOAD: GOLF\r"             att ptr -q games/GOLFPT.txt
expect "LOAD: GOMOKU\r"           att ptr -q games/GOMOKUPT.txt
expect "LOAD: MANDPL1\r"          att ptr -q games/MANDPL1.txt
expect "LOAD: OREGON TRAIL\r"     att ptr -q games/OREGON.txt
expect "LOAD: OTHELL\r"           att ptr -q games/OTHELL8K.txt
expect "LOAD: OTHPT2\r"           att ptr -q games/OTHPT2.txt
expect "LOAD: PATTERN\r"          att ptr -q games/PATTERN.txt
expect "LOAD: PTSTRK\r"           att ptr -q games/PTSTRK.txt
expect "LOAD: SEA BATTLE\r"       att ptr -q games/SEABATPT.txt
expect "LOAD: STAR\r"             att ptr -q games/STAR.txt
expect "LOAD: TREK\r"             att ptr -q games/TREK.txt
expect "LOAD: TREK3\r"            att ptr -q games/TREK3.txt
expect "LOAD: TREK8\r"            att ptr -q games/TREK8.txt
expect "LOAD: TREKD1\r"           att ptr -q games/TREKD1.txt
expect "LOAD: TTY TREK\r"         att ptr -q games/TTYTRKPT.txt

send "RUN\r"
go

go until "READY" 
send "SCRATCH\r"
go until "READY" 
send "PTAPE\r"
go until "READY" 
send "RUN\r"
go

:end
---------------------------------------------------------------------

------ file "HP2100/sw/Basic/ptbasic/games/1_MENU.txt" --------------
10  PRINT "SELECT"
20  PRINT "   1) LUNAR LANDER      2) STAR TREK"
30  PRINT "   3) WUMPUS ADVENTURE  4) HAMURABI"
31  PRINT "   5) BEASTI            6) GOLF"
32  PRINT "   7) GOMOKU            8) MANDPL1"
33  PRINT "   9) OREGON TRAIL     10) OTHELL"
34  PRINT "   11) OTHPT2          12) PATTERN"
35  PRINT "   13) PTSTRK          14) SEA BATTLE"
36  PRINT "   15) STAR            16) TREK"
37  PRINT "   17) TREK3           18) TREK8"
38  PRINT "   19) TREKD1          20) TTY TREK"
40  PRINT "   0) RETURN TO BASIC"
60  INPUT A9
100  IF A9=1 THEN 210
110  IF A9=2 THEN 220
120  IF A9=3 THEN 230
130  IF A9=4 THEN 240
131  IF A9=5 THEN 250
132  IF A9=6 THEN 260
133  IF A9=7 THEN 270
134  IF A9=8 THEN 280
135  IF A9=9 THEN 290
136  IF A9=10 THEN 300
137  IF A9=11 THEN 310
138  IF A9=12 THEN 320
139  IF A9=13 THEN 330
140  IF A9=14 THEN 340
141  IF A9=15 THEN 350
142  IF A9=16 THEN 360
143  IF A9=17 THEN 370
144  IF A9=18 THEN 380
145  IF A9=19 THEN 390
146  IF A9=20 THEN 400
150  GOTO 890
210  PRINT "LOAD: LUNAR LANDER"
211  GOTO 900
220  PRINT "LOAD: STAR TREK"
221  GOTO 900
230  PRINT "LOAD: WUMPUS ADVENTURE"
231  GOTO 900
240  PRINT "LOAD: HAMURABI"
241  GOTO 900
250  PRINT "LOAD: BEASTI"
251  GOTO 900
260  PRINT "LOAD: GOLF"
261  GOTO 900
270  PRINT "LOAD: GOMOKU"
271  GOTO 900
280  PRINT "LOAD: MANDPL1"
281  GOTO 900
290  PRINT "LOAD: OREGON TRAIL"
291  GOTO 900
300  PRINT "LOAD: OTHELL"
301  GOTO 900
310  PRINT "LOAD: OTHPT2"
311  GOTO 900
320  PRINT "LOAD: PATTERN"
321  GOTO 900
330  PRINT "LOAD: PTSTRK"
331  GOTO 900
340  PRINT "LOAD: SEA BATTLE"
341  GOTO 900
350  PRINT "LOAD: STAR"
351  GOTO 900
360  PRINT "LOAD: TREK"
361  GOTO 900
370  PRINT "LOAD: TREK3"
371  GOTO 900
380  PRINT "LOAD: TREK8"
381  GOTO 900
390  PRINT "LOAD: TREKD1"
391  GOTO 900
400  PRINT "LOAD: TTY TREK"
410  GOTO 900
890  PRINT
900  END
---------------------------------------------------------------------

Note - if doing this under Linux make sure to convert the files to
CRLF line ends using flip -m or similar, especially "1_MENU.txt" as
papertape BASIC doesn't take kindly to LF-only line ends.

-------------------------------------
4/7/2024 - Initial collection

Terry Newton (wtn90125@yahoo.com)

