Dragmaster

Products: Dragmaster
Date: 1983
Type: Program
Platform(s): TS 2068
Tags: Game

DRAGMASTER 2000 is a drag racing simulation that challenges the player to launch from a standing start, shift through four gears, and complete a quarter-mile run as quickly as possible. The program loads an external machine code file (“dragmc”) at address 50000 and calls several USR routines at addresses such as 50008, 51060, 51075, 51150, 51230, and 51250 for engine sound, tachometer animation, and display updates. Joystick input is handled via the STICK command, with keys 1–4 for gear selection and “g” for throttle. Six user-defined graphics (UDGs “a” through “f”) are defined at startup to render car silhouettes and track scenery on the title and race screens. A timer built from system variables at addresses 23672–23674 measures elapsed time to hundredths of a second, and a best-time leaderboard with player initials is maintained across runs.


Program Analysis

Program Structure

The program is organized into well-separated functional blocks. Execution begins at line 5, which immediately jumps to line 25 (skipping the CLEAR and LOAD setup on lines 10–20 during a warm restart). The main game loop runs from line 220, with a subroutine dispatcher at line 228. Key subsystems are:

  • Initialization (lines 10–178): memory clear, machine code load, UDG setup, variable initialization
  • Main game loop (lines 220–270): input polling, physics update, display refresh
  • Input handler (lines 600–699, 1800–1899): joystick via STICK and keyboard via INKEY$
  • Engine/physics (lines 1000–1599): tachometer, speed variable x, engine stress variable j
  • Instrument drawing (lines 2000–3999): PLOT/DRAW needle animation for two gauges
  • Gear/resistance logic (lines 4000–4099): gear-dependent resistance multiplier r
  • Race start sequence (lines 5500–5599): countdown lights, foul detection
  • Results/leaderboard (lines 5200–5399): elapsed time calculation, best time comparison, initials INPUT
  • Title/rules screens (lines 7000–8099, 9620–9699)
  • UDG definition (lines 9100–9199)
  • Machine code data/save (lines 9600–9610, 9800–9970)
  • SOUND mute utility (lines 9980–9992)
  • Error recovery (lines 9994–9997)

Machine Code Usage

The program relies heavily on external machine code loaded from the file “dragmc” at address 50000 (14950 bytes). Several USR entry points are called throughout:

AddressPurpose
50008Engine sound / acceleration effect
51060General display or engine state update (called from redline loop)
51075Gas-on display routine
51150Deceleration/coast display routine
51230Small block copy routine (POKEd inline at lines 9810–9840)
51250Delay/timing loop (POKEd inline at lines 9910–9960)

Additionally, lines 40–90 POKE a short Z80 routine at address 51060 from DATA at line 100. The bytes 237,75,80,195 etc. correspond to Z80 instructions including LD BC,(nn) and LDIR, suggesting a block memory copy bootstrap. A second inline machine code stub is built at address 50000–50005 (lines 150–160), which appears to be a short jump/call launcher: POKE 50000,0 (NOP), followed by bytes forming a CALL instruction to address 16384 (64*256+0).

Physics Model

Two floating-point variables simulate the drivetrain: x represents engine/wheel speed (capped at 0.080) and j represents engine stress or RPM. The gas subroutine (line 1700) increments x by pp (0.0070) per cycle and j by ll (0.0015). The coast subroutine (line 1600) decrements x by pp. Gear selection (lines 4005–4016) sets resistance multiplier r as a fraction of j, with gear 1 giving the highest resistance (0.65) and gear 4 the lowest (0.025), modeling transmission ratio effects. Line 243 subtracts 1.5*r from j each cycle, providing back-pressure. Redline is triggered at j>.070 (line 1442) unless in 4th gear.

Instrument Display

Two analog needle gauges are drawn using PLOT/DRAW with OVER 1 (XOR mode) to erase the previous needle before drawing the new one. The tachometer (lines 3000–3999) is centered at pixel (85,50) and the speedometer (lines 2000–2999) at (174,50). Needle angle is computed via COS and SIN applied to (35.3 - x*180/PI) and (35.2 - j*180/PI) respectively, scaling by 15 pixels. The previous values oc,os,ow,oe are stored and only redrawn when changed, saving processing time.

Timer Implementation

Line 172 defines FN t() using a DEF FN to read the system frame counter from three consecutive memory locations at 23672–23674, computing (65536*PEEK 23674 + 256*PEEK 23673 + PEEK 23672)/60 to yield elapsed seconds. The race start time t1 is captured at line 5560 and the finish time t2 at line 5215. Elapsed time t3 = t2 - t1 - 4 (line 5218) subtracts a 4-second offset, presumably to account for the countdown sequence. Speed in MPH is then computed as 1320/t3 (line 5222), treating the track as a quarter-mile (1320 feet).

Input Handling

Input is dual-mode. Keyboard input via INKEY$ is read in subroutine 1800, accepting keys “1”–”4″ for gears and “g” for gas. Joystick input is handled in subroutine 600 using STICK(1,1) for directional movement (gear up) and STICK(2,1) for the fire button (gas). A shift-counter variable sh increments on each joystick movement, capping at 4, and is converted to a string for the gear variable k$. Lines 615–617 distinguish between a stick movement while already in gear (increments) versus from neutral (sets to “1”). An older alternative using OUT 245,14 / IN (246+1*256) is preserved in commented-out REM lines at 605–614 and 800–899.

SOUND Usage

Line 510 uses SOUND with multiple channel parameters (6,0;7,7;8,16;9,16;10,16;12,5;13,0) to generate engine idle noise during the attract loop. Line 1150 uses SOUND with randomized parameters (1,RND*13;0,RND*377) to create engine running noise. The subroutine at line 9980 silences all channels by iterating SOUND n,0 for n=0 to 13.

Error Handling

Lines 9994–9997 implement a three-stage ON ERR chain. Line 9994 calls ON ERR RESET to clear error state, followed by a PAUSE, then ON ERR GO TO 9994 to redirect any subsequent error back to the reset handler, and finally ON ERR CONTINUE to allow resumption. This pattern guards against runtime errors in the main loop (line 220 sets ON ERR GO TO 9994) without crashing the program.

Title Screen and UDGs

Six UDGs are defined at lines 9100–9198 using BIN literals POKEd into USR "a" through USR "f". UDGs \a and \d form left and right tire/wheel shapes, \b and \c form car body halves, \e is a circular “smoke puff” or crowd figure used extensively in the staging area scenery (lines 9700–9748), and \f is a checkered flag tile used in the start-line crowd decoration. The title screen (lines 9620–9699) draws a track silhouette using PLOT/DRAW and block graphics, displaying colored rectangles for timing lights and staging beams.

Notable Techniques and Anomalies

  • Line 5 jumps to 25, bypassing the LOAD at line 20 on warm restarts, allowing re-entry without reloading machine code.
  • INT (RND*1) at lines 245, 4010–4016 always evaluates to 0, making those terms effectively zero — this appears to be a vestigial expression intended to add randomness but is nonfunctional.
  • Line 239 filters unrecognized key presses back to the last valid gear f$, preventing invalid states.
  • The d1 damage accumulator (lines 1228–1247) increases during hard acceleration and triggers engine shutdown at d1>15 (line 1247), but gearing down (lines 4020–4024) subtracts from it, rewarding smooth shifting.
  • Lines 9600–9610 contain the SAVE statements to write the BASIC program and machine code back to tape, tucked safely after the main game logic.
  • The b$="999" sentinel (line 165, checked at line 5400) prevents display of an uninitialized best time on the first run.

Content

Appears On

Related Products

Speed your Dragmaster over the 1/4 mile drag strip in a race against the clock. Super graphics and intriguing automotive...

Related Articles

Related Content

Image Gallery

Source Code

    5 GO TO 25
   10 CLEAR 49999
   15 CLS : PRINT AT 10,5;"Leave everything alone";AT 11,5;"more to come"
   20 LOAD "dragmc"CODE 50000,14950
   25 GO SUB 9100: GO SUB 9620
   26 BORDER 1
   27 REM GO SUB 9300
   28 LET sh=0: LET s$="N": LET g$="x": LET k$="N": RANDOMIZE 0
   30 RESTORE 100
   35 GO TO 150
   40 LET a=51060
   50 READ r: IF r=999 THEN GO TO 150
   60 POKE a,r
   70 REM PRINT a;r
   80 LET a=a+1
   90 GO TO 50
  100 DATA 237,75,80,195,42,82,195,237,91,84,195,237,176,201,999
  150 POKE 50000,0
  152 POKE 50001,27
  154 POKE 50002,220
  156 POKE 50003,205
  158 POKE 50004,0
  160 POKE 50005,64
  165 LET b$="999"
  170 LET c1=USR 51060
  172 DEF FN t()=((65536*PEEK 23674+256*PEEK 23673+PEEK 23672)/60)
  173 LET gear=0: LET h=0
  174 LET d1=0
  175 LET s$="N": LET f$="N"
  176 LET ex=0: LET sh=0: LET st=1
  177 LET r=1
  178 LET ss=0
  179 REM GO SUB 5500
  211 LET c=1: LET s=1: LET w=1: LET e=1
  212 LET oc=0: LET os=0: LET ow=0: LET oe=0
  214 GO SUB 5400
  216 LET x=0: LET t1=9999999
  217 LET j=0
  218 LET pp=.0070
  219 LET ll=.0015
  220 ON ERR GO TO 9994: LET gas=0: GO SUB 1800
  221 IF k$="g" OR g$="g" THEN LET gas=1
  222 IF gas=1 THEN GO SUB 1000: GO TO 220
  225 GO SUB 228
  227 GO TO 220
  228 LET s$=k$
  230 IF s$="n" THEN LET s$="N"
  239 IF s$<>"N" AND s$<>"" AND s$<>"1" AND s$<>"2" AND s$<>"3" AND s$<>"4" THEN LET s$=f$
  240 IF CODE s$=0 AND gear=0 THEN LET s$=f$
  241 PRINT ; INK 0; PAPER 7;AT 11,16;s$
  242 IF x>.080 THEN LET x=.080
  243 LET j=j-1.5*r 
  244 POKE 51058,INT (255-254): IF x>0 THEN LET c1=USR 50008
  245 LET x=x-(INT (RND*1)*pp)
  247 IF x<.0001 THEN LET x=.0000
  248 IF j<.0001 THEN LET j=.0000
  250 GO SUB 1000
  260 GO SUB 2000
  262 GO SUB 3000
  263 GO SUB 2000
  264 GO SUB 3000
  270 RETURN 
  500 REM 
  501 FOR n=-10 TO 0
  503 IF INKEY$<>"" THEN RETURN 
  505 BEEP .01,n
  510 SOUND 6,0;7,7;8,16;9,16;10,16;12,5;13,0
  525 NEXT n
  530 FOR n=0 TO -10 STEP -1
  535 BEEP .01,n
  538 IF INKEY$<>"" THEN RETURN 
  540 NEXT n
  599 RETURN 
  600 REM 
  601 LET g$="x"
  603 LET k$=s$
  605 REM OUT 245,14
  610 REM LET a=IN (246+1*256)
  611 LET a= STICK (1,1)
  612 REM LET a=255-a
  613 REM IF a=0 THEN RETURN 
  615 IF a<>0 AND k$<>"N" THEN LET sh=sh+1: LET k$=STR$ sh: IF sh>4 THEN LET sh=4
  617 IF a<>0 AND k$="N" THEN LET k$="1"
  618 LET a= STICK (2,1)
  622 IF a=1 THEN LET g$="g": RETURN 
  623 IF k$>"4" AND k$<>"N" THEN LET k$="4"
  625 LET f$=k$: LET s$=k$
  630 PRINT ; INK 0; PAPER 7;AT 11,16;s$
  635 LET a=0
  699 RETURN 
  800 REM 
  805 OUT 245,14: LET a=IN (246+1*256): LET a=255-a: IF a=0 THEN RETURN 
  810 IF a>127 THEN LET ex=1
  899 RETURN 
  999 GO TO 220
 1000 REM 
 1002 IF x>.080 THEN LET x=.080
 1003 POKE 51058,20
 1110 REM PRINT ; INK 0; PAPER 7;AT 11,16;s$
 1150 SOUND 3,15;7,60;8,15;9,15;1,RND*13;0,RND*377
 1200 REM 
 1201 LET c1=USR 51250
 1220 IF gas=0 THEN GO SUB 1600
 1222 IF gas=1 THEN GO SUB 1700
 1223 REM GO SUB 1800
 1225 IF s$ ="N" AND gas=0 THEN GO TO 1400
 1226 IF s$="N" THEN GO TO 1400
 1227 LET fg=(RND*VAL s$)
 1228 LET d1=d1+x*(INT (RND*20)+30)+fg*.5
 1230 LET c1=USR 51250
 1232 IF d1<9 THEN GO TO 1250
 1234 IF d1>9 THEN PRINT INK 7; PAPER 0;AT 6,15;"\.'\.'\.'"
 1235 LET c1=USR 51250
 1236 IF d1>13 THEN PRINT INK 7; PAPER 0;AT 6,14;"\.'\.'\.'\.'\.'"
 1238 REM IF d1>14 THEN PRINT INK 7; PAPER 0;AT 6,13;"\.'\.'\.'\.'\.'\.'\.'\.'\.'"
 1240 IF d1>15 THEN PRINT INK 7; PAPER 0;AT 6,11;"\.'\.'\.'\.'\.'\.'\.'\.'\.'\.'\.'"
 1247 IF d1>15 THEN GO TO 5200
 1250 LET c1=USR 51250
 1254 IF x<.0001 THEN LET x=.0000
 1300 IF x>.080 THEN LET x=.080
 1350 LET c1=USR 51250
 1400 LET c=COS (35.3-x*180/PI)*15
 1401 LET t9=FN t()
 1402 LET s=SIN (35.3-x*180/PI)*15
 1403 IF t9-30>t1 THEN GO TO 170
 1404 LET c1=USR 51250
 1410 GO SUB 3000
 1421 IF s$="N" AND gas=0 THEN GO TO 1435
 1427 GO SUB 4000
 1430 IF gas=0 THEN GO TO 1433
 1431 LET j=j+r: IF s$="N" THEN GO TO 1433
 1432 LET x=1.8*r+x
 1433 IF j>.080 THEN LET j=.080
 1434 IF j<.0001 THEN LET j=.0000
 1435 LET w=COS (35.2-j*180/PI)*15
 1437 LET e=SIN (35.2-j*180/PI)*15
 1440 GO SUB 2000
 1441 IF st=1 THEN GO SUB 5500
 1442 IF j>.070 AND s$<>"4" THEN GO TO 5000
 1443 REM IF j>.070 THEN LET d1=d1-1
 1445 IF j>.080 THEN LET j=.080
 1446 IF j<.0001 THEN LET j=.015
 1500 GO SUB 3000
 1555 GO SUB 2000
 1599 RETURN 
 1600 REM 
 1610 LET c1=USR 51150
 1612 LET x=x-pp
 1650 IF x<.0001 THEN LET x=.0000
 1699 RETURN 
 1700 REM 
 1710 LET c1=USR 51075
 1712 IF s$="1" OR s$="2" OR s$="3" OR s$="4" THEN LET c1=USR 50008
 1714 LET x=x+pp
 1716 IF s$="N" THEN LET x=x-pp
 1718 LET j=j+ll
 1799 RETURN 
 1800 REM 
 1805 GO SUB 600
 1807 LET k$=s$
 1810 REM LET k$=CHR$ (PEEK 23560)
 1811 LET k$=INKEY$
 1813 IF k$=" " THEN RETURN 
 1815 IF k$="" THEN RETURN 
 1816 IF k$<>"1" AND k$<>"2" AND k$<>"3" AND k$<>"4" AND k$<>"g" THEN RETURN 
 1817 IF CODE k$=0 THEN RETURN 
 1820 IF k$="g" THEN RETURN 
 1825 LET s$=k$
 1826 LET f$=s$
 1830 PRINT ; INK 0; PAPER 7;AT 11,16;s$
 1899 RETURN 
 2000 IF st=1 THEN GO TO 2045
 2001 IF w=ow AND e=oe THEN GO TO 2999
 2002 LET c1=USR 51250
 2030 GO SUB 1800
 2045 PLOT 174,50
 2050 DRAW OVER  1; INK 0; PAPER 2; INVERSE 0;ow+ow,oe+oe
 2060 LET ow=w: LET oe=e
 2065 PLOT 174,50
 2070 DRAW OVER  1; INK 0; PAPER 2; INVERSE 0;w+w,e+e
 2999 RETURN 
 3000 IF st=1 THEN GO TO 3045
 3001 IF c=oc AND s=os THEN GO TO 3999
 3005 LET c1=USR 51250
 3030 GO SUB 1800
 3045 PLOT 85,50
 3050 DRAW OVER 1; INK 0; PAPER 7; INVERSE 0;oc+oc,os+os
 3060 LET oc=c: LET os=s
 3065 PLOT 85,50
 3070 DRAW OVER 1; INK 0; PAPER 7; INVERSE 0;c+c,s+s
 3999 RETURN 
 4000 REM 
 4001 LET f$=s$
 4002 GO SUB 1800
 4005 IF s$="N" THEN LET r=j*.8
 4010 IF s$="1" THEN LET r=j*.65*(INT (RND*1)+.5)
 4012 IF s$="2" THEN LET r=j*.50*(INT (RND*1)+.5)
 4014 IF s$="3" THEN LET r=j*.35*(INT (RND*1)+.5)
 4016 IF s$="4" THEN LET r=j*.025*(INT (RND*1)+.5)
 4020 IF s$="2" AND h<1 THEN LET d1=d1-10
 4022 IF s$="3" AND h<2 THEN LET d1=d1-10
 4024 IF s$="4" AND h<3 THEN LET d1=d1-10
 4025 IF CODE s$=0 THEN LET s$="N": GO TO 4027
 4026 LET h=VAL s$
 4030 LET c1=USR 51250
 4035 REM GO SUB 1800
 4036 REM 
 4099 RETURN 
 5000 REM redline
 5003 FOR n=1 TO 10
 5005 LET c1=USR 51230
 5006 BEEP .1,20
 5007 LET c1=USR 51060
 5008 NEXT n
 5010 PRINT ; PAPER 0; INK 7;AT 3,10;"blown engine"
 5020 BEEP .2,2
 5030 FOR n=1 TO 50
 5032 NEXT n
 5040 GO TO 170
 5200 REM 
 5210 PRINT ; PAPER 0; INK 7;AT 3,10;"shutdown"
 5215 LET t2=FN t()
 5217 REM IF t2<t1 THEN GO TO 5215
 5218 LET t3=(t2-t1)-4: LET t$=STR$ t3: LET x$=t$(1 TO LEN t$): IF LEN x$>6 THEN LET x$=x$(1 TO 6)
 5219 PRINT ; PAPER 0; INK 7;AT 0,6;x$
 5220 REM BEEP 2,4
 5222 LET mph=1320/ VAL x$
 5223 LET m$=STR$ mph: LET p$=m$(1 TO LEN m$): IF LEN p$>7 THEN LET p$=p$(1 TO 7)
 5225 PRINT ; PAPER 0; INK 7;AT 1,6;p$
 5227 REM BEEP .1,2: BEEP .1,6: BEEP .2,8: BEEP .1,4: BEEP .5,20
 5228 GO SUB 9980
 5230 IF VAL x$<VAL b$ THEN GO SUB 5300
 5231 IF ss=1 THEN GO TO 5250
 5232 GO SUB 9980 : PRINT INK 7; PAPER 0;AT 0,25;b$
 5233 FOR n=1 TO 80: NEXT n
 5235 REM PRINT INK 2;AT 6,10;"Press the x key       "
 5236 REM IF INKEY$<>"x" THEN GO TO 5236
 5240 REM 
 5250 LET ss=0
 5252 GO TO 170
 5300 PRINT INK 2;AT 6,7;"Enter your initials"
 5305 LET ss=1
 5310 INPUT i$
 5330 LET b$=x$
 5332 LET u$=p$
 5340 REM PRINT INK 7; PAPER 0;AT 0,25;b$
 5342 REM PRINT INK 7; PAPER 0;AT 1,25;u$
 5399 RETURN 
 5400 IF b$="999" THEN RETURN 
 5420 PRINT INK 7; PAPER 0;AT 2,28;i$(1 TO 3)
 5440 PRINT INK 7; PAPER 0;AT 0,25;b$
 5441 PRINT INK 7; PAPER 0;AT 1,25;u$
 5499 RETURN 
 5500 GO SUB 9980 : LET st=2
 5501 PRINT INK 2;AT 5,1;"Press the R key for rules"
 5502 PRINT INK 2;AT 6,1;"Press any other key when ready": GO SUB 800: IF ex=1 THEN GO TO 5504
 5503 IF INKEY$="" THEN GO TO 5502
 5504 PRINT INK 5;AT 6,1;"\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::"
 5505 PRINT INK 5;AT 5,1;"\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::"
 5506 IF INKEY$="r" THEN GO TO 7000
 5507 GO SUB 9700
 5509 FOR n=9 TO 19 STEP 2
 5510 PRINT INK 2; PAPER 0;AT 3,n;"\::"
 5515 NEXT n
 5517 PAUSE 100
 5520 FOR n=9 TO 19 STEP 2
 5522 IF INKEY$="g" OR g$="g" AND s$<>"N" THEN GO SUB 5600
 5523 BEEP .01,5
 5525 PRINT INK 4; PAPER 0;AT 3,n;"\::"
 5530 PAUSE 20
 5535 REM LET s$="N"
 5540 GO SUB 1800
 5541 REM IF INKEY$="1" OR s$="1" THEN LET s$="1"
 5542 REM IF INKEY$="2" THEN LET s$="2"
 5543 REM IF INKEY$="3" THEN LET s$="3"
 5544 REM IF INKEY$="4" THEN LET s$="4"
 5545 PRINT ; INK 0; PAPER 7;AT 11,16;s$
 5550 NEXT n
 5560 LET t1=FN t()
 5570 PRINT INK 0; PAPER 0;AT 3,9;"             "
 5599 RETURN 
 5600 REM foul
 5605 BORDER 2: PAPER 2: CLS 
 5610 PRINT INK 0; PAPER 0;AT 3,9;"             "
 5612 PRINT INK 7; PAPER 0;AT 3,9;" red light"
 5614 BEEP .1,2: BEEP .2,2: BEEP .1,2
 5620 PAUSE 100
 5625 PAPER 7
 5696 GO TO 170
 5699 RETURN 
 7000 REM 
 7005 PAPER 7
 7010 CLS 
 7020 PRINT INK 2;AT 3,3;"Welcome to DRAGMASTER 2000"
 7021 PRINT INK 1;AT 4,3;"**************************"
 7022 PRINT INK 1;AT 5,3;"the rules are......"
 7024 PRINT INK 1;AT 7,2;"1. Keys 1,2,3,4 are the gears"
 7026 PRINT INK 1;AT 8,2;"2. The G key is the gas"
 7028 PRINT INK 1;AT 9,2;"3. You cannot leave until all      the status lites are green"
 7030 PRINT INK 1;AT 11,2;"4. You must keep the G key         down unless you want to         change gears"
 7032 PRINT INK 1;AT 14,2;"5. You may redline tach----        sometimes"
 7034 PRINT INK 2; FLASH 1;AT 18,4;"WATCH THOSE INSTRUMENTS"
 7088 PAUSE 100
 7095 PRINT INK 1; FLASH 1;AT 20,2;"Press any key"
 7096 IF INKEY$="" THEN GO TO 7096
 7098 GO SUB 8000
 7099 GO TO 170
 8000 REM 
 8020 CLS 
 8040 PRINT INK 2;AT 3,0;"JOYSTICK USAGE (optional)"
 8042 PRINT INK 2;AT 6,0;"The joystick is inserted into   player one(1) slot"
 8044 PRINT INK 0;AT 10,0;"The fire button replaces the G  key"
 8046 PRINT INK 0;AT 13,0;"To shift up 1 gear simply move  the stick in any direction--    Insure a complete shift is made"
 8050 PRINT INK 1; FLASH 1;AT 20,2;"Press any key"
 8053 IF INKEY$="" THEN GO TO 8053
 8099 GO TO 170
 9000 REM 
 9005 FOR n=12 TO 20 STEP 2
 9010 PRINT INK 7;AT n,4;"\::"
 9011 PRINT INK 7;AT n,27;"\::"
 9020 NEXT n
 9025 FOR n=220 TO 225
 9030 REM PLOT INK 0; PAPER 7; OVER 0;n,8: DRAW INK 0; PAPER 7; OVER 0; INVERSE 0;0,70
 9035 NEXT n
 9040 FOR n=38 TO 40
 9042 REM PLOT INK 0; PAPER 7; OVER 0;n,8: DRAW INK 0; PAPER 7; OVER 0; INVERSE 0;0,70
 9044 NEXT n
 9052 PRINT INK 4;AT 7,0;"\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::"
 9053 PRINT INK 4;AT 8,0;"\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::"
 9054 PLOT INK 4; PAPER 2; INVERSE 1;132,110
 9055 FOR n=106 TO 152
 9060 PLOT INK 4; OVER 0; PAPER 2; INVERSE 1;n,100
 9070 DRAW INK 4; PAPER 2; OVER 0; INVERSE 1;132-n,110-100
 9072 NEXT n
 9073 FOR n=0 TO 3
 9074 PRINT INK 0;AT n,0;"\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::\::"
 9080 NEXT n
 9082 PRINT INK 0; PAPER 2;AT 9,13;"\: "
 9084 PRINT INK 0; PAPER 4;AT 8,13;"\: "
 9086 PRINT INK 0; PAPER 2; INVERSE 1;AT 9,19;"\: "
 9088 PRINT INK 0; PAPER 4; INVERSE 1;AT 8,19;"\: "
 9090 PRINT INK 7; PAPER 0;AT 0,0;"TIME = ";AT 0,14;"BEST TIME = "
 9092 PRINT INK 7; PAPER 0;AT 1,0;"MPH  = ";AT 1,14;"BEST MPH  = "
 9094 PRINT INK 7; PAPER 0;AT 3,0;"STATUS  = ";AT 2,14;"BEST DRIVER  = "
 9096 RETURN 
 9100 REM 
 9105 RESTORE 9120
 9107 FOR n=0 TO 7
 9109 READ r: POKE USR "a"+n,r
 9111 NEXT n
 9120 DATA BIN 00000000,BIN 00000001,BIN 00000011,BIN 01111111,BIN 00111111,BIN 00001111,BIN 00000011,BIN 00000000
 9125 RESTORE 9140
 9128 FOR n=0 TO 7
 9130 READ r: POKE USR "b"+n,r
 9135 NEXT n
 9140 DATA BIN 00000000,BIN 11010100,BIN 11111111,BIN 11111111,BIN 11111111,BIN 11111111,BIN 11010100,BIN 00000000
 9142 RESTORE 9150
 9144 FOR n=0 TO 7
 9146 READ r: POKE USR "c"+n,r
 9148 NEXT n
 9150 DATA BIN 00000000,BIN 00101011,BIN 11111111,BIN 11111111,BIN 11111111,BIN 11111111,BIN 00101011,BIN 00000000
 9152 RESTORE 9160
 9154 FOR n=0 TO 7
 9156 READ r: POKE USR "d"+n,r
 9158 NEXT n
 9160 DATA BIN 00000000,BIN 10000000,BIN 11000000,BIN 11111110,BIN 11111100,BIN 11110000,BIN 11000000,BIN 00000000
 9162 RESTORE 9170
 9164 FOR n=0 TO 7
 9166 READ r: POKE USR "e"+n,r
 9168 NEXT n
 9170 DATA BIN 00000000,BIN 01111110,BIN 01111110,BIN 01111110,BIN 01111110,BIN 01111110,BIN 01111110,BIN 00000000
 9172 RESTORE 9180
 9174 FOR n=0 TO 7
 9176 READ r: POKE USR "f"+n,r
 9178 NEXT n
 9180 DATA BIN 00000000,BIN 00111100,BIN 01111110,BIN 01011010,BIN 01111110,BIN 00100100,BIN 00011000,BIN 00111100
 9197 REM GO SUB 9200
 9198 REM GO SUB 9800
 9199 RETURN 
 9600 SAVE "dragp" LINE 10
 9608 SAVE "dragmc"CODE 50000,14950
 9610 STOP 
 9620 REM 
 9624 BORDER 0
 9626 PAPER 0
 9628 CLS 
 9630 PLOT INK 7;40,88
 9632 DRAW INK 7;175,0
 9634 PLOT INK 7;128,88
 9636 DRAW INK 7;0,86
 9638 PRINT INK 2;AT 11,5;"\::\::\::\::\::"
 9640 PRINT INK 2;AT 12,5;"\::\::\::\::\::"
 9642 PRINT INK 2;AT 13,5;"\::\::\::\::\::"
 9644 PRINT INK 2;AT 14,5;"\::\::\::\::\::"
 9646 PRINT INK 7;AT 11,22;"\.'\.'\.'\.'\.'"
 9648 PRINT INK 7;AT 12,22;"\.'\.'\.'\.'\.'"
 9650 PRINT INK 7;AT 13,22;"\.'\.'\.'\.'\.'"
 9652 PRINT INK 7;AT 14,22;"\.'\.'\.'\.'\.'"
 9654 PRINT INK 4;AT 0,16;"\::\::\::\::\::"
 9656 PRINT INK 4;AT 1,16;"\::\::\::\::\::"
 9658 PRINT INK 4;AT 2,16;"\::\::\::\::\::"
 9660 PRINT INK 4;AT 3,16;"\::\::\::\::\::"
 9662 PRINT INK 6;AT 15,12;"\a\b"
 9664 PRINT INK 6;AT 15,18;"\c\d"
 9682 PRINT INK 7;AT 14,11;"DRAGMASTER"
 9684 PRINT INK 7;AT 15,14;"2000"
 9685 PRINT INK 2;AT 19,7;"Copyright TIMEX 1982"
 9686 PRINT INK 6;AT 21,10;"PRESS ANY KEY"
 9690 IF INKEY$="" THEN GO SUB 500
 9691 IF INKEY$="" THEN GO TO 9690
 9692 PAPER 7
 9699 RETURN 
 9700 REM 
 9706 REM 
 9708 PAPER 0
 9710 PRINT INK 3;AT 7,6;"\e"
 9712 PRINT INK 3;AT 6,6;"\e"
 9713 PRINT INK 3;AT 6,7;"\e\e\e"
 9715 PRINT INK 7; PAPER 1;AT 5,0;"\f\f\f\f\f\f\f\f\f"
 9717 PRINT INK 7; PAPER 1;AT 4,0;"\f\f\f\f\f\f\f\f"
 9719 PRINT INK 3;AT 6,0;"\e\e\e\e\e\e\e"
 9720 PRINT INK 3;AT 7,0;"\e\e\e\e\e\e\e"
 9722 PRINT INK 3;AT 8,0;"\e\e\e\e\e"
 9724 PRINT INK 3;AT 9,0;"\e\e\e"
 9726 PRINT INK 3;AT 10,0;"\e\e\e"
 9728 PRINT INK 3;AT 11,0;"\e\e"
 9730 PRINT INK 3;AT 7,26;"\e"
 9734 PRINT INK 3;AT 6,23;"\e\e\e"
 9735 PRINT INK 7; PAPER 1;AT 5,24;"\f\f\f\f\f\f\f\f"
 9737 PRINT INK 7; PAPER 1;AT 4,25;"\f\f\f\f\f\f\f"
 9739 PRINT INK 3;AT 6,26;"\e\e\e\e\e\e"
 9740 PRINT INK 3;AT 7,26;"\e\e\e\e\e\e"
 9742 PRINT INK 3;AT 8,28;"\e\e\e\e"
 9744 PRINT INK 3;AT 9,30;"\e\e"
 9746 PRINT INK 3;AT 10,30;"\e\e"
 9748 PRINT INK 3;AT 11,31;"\e"
 9796 PAPER 7
 9799 RETURN 
 9800 REM 
 9810 LET a=51230
 9820 RESTORE 9860
 9825 READ r: IF r=999 THEN GO TO 9870
 9827 REM PRINT a,r
 9830 POKE a,r: LET a=a+1
 9840 GO TO 9825
 9860 DATA 1,0,24,33,0,64,17,0,91,126,18,35,27,11,120,177,32,247,201,999
 9870 RETURN 
 9900 REM 
 9910 LET a=51250
 9920 RESTORE 9960
 9925 READ r: IF r=999 THEN GO TO 9970
 9930 POKE a,r: LET a=a+1
 9940 GO TO 9925
 9960 DATA 62,5,17,1,0,33,200,26,245,0,0,0,241,61,32,248,201,999
 9970 STOP 
 9980 REM 
 9990 FOR n=0 TO 13: SOUND n,0: NEXT n
 9992 RETURN 
 9994 ON ERR RESET 
 9995 PAUSE 100
 9996 ON ERR GO TO 9994
 9997 ON ERR CONTINUE 

Note: Type-in program listings on this website use ZMAKEBAS notation for graphics characters.

People

No people associated with this content.

Scroll to Top