Home » Personal collection » Acorn tapes » Own_Work » drawer_tl_tape08b_c15_acorn_maze.wav » MAZE

MAZE

This website contains an archive of files for the Acorn Electron, BBC Micro, Acorn Archimedes, Commodore 16 and Commodore 64 computers, which Dominic Ford has rescued from his private collection of floppy disks and cassettes.

Some of these files were originally commercial releases in the 1980s and 1990s, but they are now widely available online. I assume that copyright over them is no longer being asserted. If you own the copyright and would like files to be removed, please contact me.

Tape/disk: Home » Personal collection » Acorn tapes » Own_Work » drawer_tl_tape08b_c15_acorn_maze.wav
Filename: MAZE
Read OK:
File size: 0504 bytes
Load address: FFFF0E00
Exec address: FFFF8023
File contents
   10 *OPT 1,2
   20 *OPT 3,1
   30 MODE 6
   40 DIM A(20,20)
   50 INPUT"DO YOU WANT D OR P";TY$
   60 IF TY$="D"THEN 90
   70 IF TY$="P"THEN 430
   80 GOTO 50
   90 YA=0:YD=0
  100 CLS
  110 A$=GET$
  120 IF A$="W" THEN A(YA,YD)=10
  130 IF A$="S" THEN A(YA,YD)=0
  140 IF A$="B"THEN A(YA,YD)=8
  150 IF A$="F"THEN A(YA,YD)=9
  160PRINTTAB(YA,YD);CHR$(A(YA,YD)+32);
  170 IF A$="Q"THEN END
  180 IF A$="T"THEN 280
  190 IF A$="L"THEN 340
  200 IF A$="Z"THEN YA=YA-1
  210 IF A$="X"THEN YA=YA+1
  220 IF A$="/"THEN YD=YD+1
  230 IF A$=":"THEN YD=YD-1
  240 VDU 23,1,0;0;0;0,11
  250 VDU 23,1,1;0;0;0,11
  260 PRINT TAB(YA,YD);
  270 GOTO 110
  280 CLS:PRINT
  290 F=OPENOUT"MAZE-DATA"
  300 FOR Z=0 TO 20:FOR X=0 TO 20
  310 PRINT#F,A(Z,X)
  320 NEXT X:NEXT Z
  330 CLOSE#F:GOTO 400
  340 CLS:PRINT
  350 F=OPENIN"MAZE-DATA"
  360 FOR Z=0 TO 20:FOR X=0 TO 20
  370 INPUT#F,A(Z,X)
  380 NEXT X:NEXT Z
  390 CLOSE#F
  400 FOR Z=0 TO 20:FOR X=0 TO 20
  410 PRINTTAB(Z,X);CHR$(A(Z,X)+32);
  420 NEXT:YA=0:YD=0:GOTO 100
  430 F=OPENIN"MAZE-DATA"
  440 FOR Z=0 TO 20:FOR X=0 TO 20
  450 INPUT#F,A(Z,X)
  460 NEXT X:NEXT Z
  470 CLOSE#F
  480 CLS:FOR Z=0 TO 20:FOR X=0 TO 20
  490 PRINTTAB(Z,X);CHR$(A(Z,X)+32);
  500 NEXT
  510 FOR Z=0 TO 20:FOR X=0 TO 20
  520 IF A(Z,X)=8 THEN Q=Z:W=X
  530 IF A(Z,X)=9 THEN E=Z:W=X
  540 NEXT X:NEXT Z
  550 YA=Q:YD=W:TE=TIME
  560 A$=GET$
  570 IF A$="Z"THEN IF A(YA-1,YD)=0 OR A(YA-1,YD)=9 THEN YA=YA-1
  580 IF A$="X"THEN IF A(YA+1,YD)=0OR A(YA+1,YD)=9 THEN YA=YA+1
  590 IF A$=":"THEN IF A(YA,YD-1)=0 OR A(YA,YD-1)=9 THEN YD=YD-1
  600 IF A$="/"THEN IF A(YA,YD+1)=0 OR A(YA,YD+1)=9 THEN YD=YD+1
  610 IF A(YA,YD)=9 THEN RUN
  620 IF TIME>TE+30 THEN 550
  630 GOTO 560


 *OPT 1,2

 *OPT 3,1
 � 6
( � A(20,20)
2 �"DO YOU WANT D OR P";TY$
< � TY$="D"� �DZ@
F � TY$="P"� �tnA
P � �Tr@
Z YA=0:YD=0
d �
n	 A$=�
x � A$="W" � A(YA,YD)=10
� � A$="S" � A(YA,YD)=0
� � A$="B"� A(YA,YD)=8
� � A$="F"� A(YA,YD)=9
��YA,YD);�(A(YA,YD)+32);
� � A$="Q"� �
� � A$="T"� �TXA
� � A$="L"� �DTA
� � A$="Z"� YA=YA-1
� � A$="X"� YA=YA+1
� � A$="/"� YD=YD+1
� � A$=":"� YD=YD-1
� � 23,1,0;0;0;0,11
� � 23,1,1;0;0;0,11
 � �YA,YD);
 � �Dn@
 �:�
" F=�"MAZE-DATA"
, � Z=0 � 20:� X=0 � 20
6 �#F,A(Z,X)
@ � X:� Z
J �#F:� �tPA
T �:�
^ F=�"MAZE-DATA"
h � Z=0 � 20:� X=0 � 20
r �#F,A(Z,X)
| � X:� Z
� �#F
� � Z=0 � 20:� X=0 � 20
� �Z,X);�(A(Z,X)+32);
� �:YA=0:YD=0:� �Dd@
� F=�"MAZE-DATA"
� � Z=0 � 20:� X=0 � 20
� �#F,A(Z,X)
� � X:� Z
� �#F
� �:� Z=0 � 20:� X=0 � 20
� �Z,X);�(A(Z,X)+32);
� �
� � Z=0 � 20:� X=0 � 20
 � A(Z,X)=8 � Q=Z:W=X
 � A(Z,X)=9 � E=Z:W=X
 � X:� Z
& YA=Q:YD=W:TE=�
0	 A$=�
:6 � A$="Z"� � A(YA-1,YD)=0 � A(YA-1,YD)=9 � YA=YA-1
D5 � A$="X"� � A(YA+1,YD)=0� A(YA+1,YD)=9 � YA=YA+1
N6 � A$=":"� � A(YA,YD-1)=0 � A(YA,YD-1)=9 � YD=YD-1
X6 � A$="/"� � A(YA,YD+1)=0 � A(YA,YD+1)=9 � YD=YD+1
b � A(YA,YD)=9 � �
l � �>TE+30 � �TfB
v � �TpB
�
00000000  0d 00 0a 0d 20 2a 4f 50  54 20 31 2c 32 0d 00 14  |.... *OPT 1,2...|
00000010  0d 20 2a 4f 50 54 20 33  2c 31 0d 00 1e 08 20 eb  |. *OPT 3,1.... .|
00000020  20 36 0d 00 28 0f 20 de  20 41 28 32 30 2c 32 30  | 6..(. . A(20,20|
00000030  29 0d 00 32 1e 20 e8 22  44 4f 20 59 4f 55 20 57  |)..2. ."DO YOU W|
00000040  41 4e 54 20 44 20 4f 52  20 50 22 3b 54 59 24 0d  |ANT D OR P";TY$.|
00000050  00 3c 14 20 e7 20 54 59  24 3d 22 44 22 8c 20 8d  |.<. . TY$="D". .|
00000060  44 5a 40 0d 00 46 14 20  e7 20 54 59 24 3d 22 50  |DZ@..F. . TY$="P|
00000070  22 8c 20 8d 74 6e 41 0d  00 50 0b 20 e5 20 8d 54  |". .tnA..P. . .T|
00000080  72 40 0d 00 5a 0e 20 59  41 3d 30 3a 59 44 3d 30  |r@..Z. YA=0:YD=0|
00000090  0d 00 64 06 20 db 0d 00  6e 09 20 41 24 3d be 0d  |..d. ...n. A$=..|
000000a0  00 78 1b 20 e7 20 41 24  3d 22 57 22 20 8c 20 41  |.x. . A$="W" . A|
000000b0  28 59 41 2c 59 44 29 3d  31 30 0d 00 82 1a 20 e7  |(YA,YD)=10.... .|
000000c0  20 41 24 3d 22 53 22 20  8c 20 41 28 59 41 2c 59  | A$="S" . A(YA,Y|
000000d0  44 29 3d 30 0d 00 8c 19  20 e7 20 41 24 3d 22 42  |D)=0.... . A$="B|
000000e0  22 8c 20 41 28 59 41 2c  59 44 29 3d 38 0d 00 96  |". A(YA,YD)=8...|
000000f0  19 20 e7 20 41 24 3d 22  46 22 8c 20 41 28 59 41  |. . A$="F". A(YA|
00000100  2c 59 44 29 3d 39 0d 00  a0 1c f1 8a 59 41 2c 59  |,YD)=9......YA,Y|
00000110  44 29 3b bd 28 41 28 59  41 2c 59 44 29 2b 33 32  |D);.(A(YA,YD)+32|
00000120  29 3b 0d 00 aa 10 20 e7  20 41 24 3d 22 51 22 8c  |);.... . A$="Q".|
00000130  20 e0 0d 00 b4 13 20 e7  20 41 24 3d 22 54 22 8c  | ..... . A$="T".|
00000140  20 8d 54 58 41 0d 00 be  13 20 e7 20 41 24 3d 22  | .TXA.... . A$="|
00000150  4c 22 8c 20 8d 44 54 41  0d 00 c8 16 20 e7 20 41  |L". .DTA.... . A|
00000160  24 3d 22 5a 22 8c 20 59  41 3d 59 41 2d 31 0d 00  |$="Z". YA=YA-1..|
00000170  d2 16 20 e7 20 41 24 3d  22 58 22 8c 20 59 41 3d  |.. . A$="X". YA=|
00000180  59 41 2b 31 0d 00 dc 16  20 e7 20 41 24 3d 22 2f  |YA+1.... . A$="/|
00000190  22 8c 20 59 44 3d 59 44  2b 31 0d 00 e6 16 20 e7  |". YD=YD+1.... .|
000001a0  20 41 24 3d 22 3a 22 8c  20 59 44 3d 59 44 2d 31  | A$=":". YD=YD-1|
000001b0  0d 00 f0 16 20 ef 20 32  33 2c 31 2c 30 3b 30 3b  |.... . 23,1,0;0;|
000001c0  30 3b 30 2c 31 31 0d 00  fa 16 20 ef 20 32 33 2c  |0;0,11.... . 23,|
000001d0  31 2c 31 3b 30 3b 30 3b  30 2c 31 31 0d 01 04 0f  |1,1;0;0;0,11....|
000001e0  20 f1 20 8a 59 41 2c 59  44 29 3b 0d 01 0e 0b 20  | . .YA,YD);.... |
000001f0  e5 20 8d 44 6e 40 0d 01  18 08 20 db 3a f1 0d 01  |. .Dn@.... .:...|
00000200  22 13 20 46 3d ae 22 4d  41 5a 45 2d 44 41 54 41  |". F=."MAZE-DATA|
00000210  22 0d 01 2c 1a 20 e3 20  5a 3d 30 20 b8 20 32 30  |"..,. . Z=0 . 20|
00000220  3a e3 20 58 3d 30 20 b8  20 32 30 0d 01 36 0f 20  |:. X=0 . 20..6. |
00000230  f1 23 46 2c 41 28 5a 2c  58 29 0d 01 40 0c 20 ed  |.#F,A(Z,X)..@. .|
00000240  20 58 3a ed 20 5a 0d 01  4a 0f 20 d9 23 46 3a e5  | X:. Z..J. .#F:.|
00000250  20 8d 74 50 41 0d 01 54  08 20 db 3a f1 0d 01 5e  | .tPA..T. .:...^|
00000260  13 20 46 3d 8e 22 4d 41  5a 45 2d 44 41 54 41 22  |. F=."MAZE-DATA"|
00000270  0d 01 68 1a 20 e3 20 5a  3d 30 20 b8 20 32 30 3a  |..h. . Z=0 . 20:|
00000280  e3 20 58 3d 30 20 b8 20  32 30 0d 01 72 0f 20 e8  |. X=0 . 20..r. .|
00000290  23 46 2c 41 28 5a 2c 58  29 0d 01 7c 0c 20 ed 20  |#F,A(Z,X)..|. . |
000002a0  58 3a ed 20 5a 0d 01 86  08 20 d9 23 46 0d 01 90  |X:. Z.... .#F...|
000002b0  1a 20 e3 20 5a 3d 30 20  b8 20 32 30 3a e3 20 58  |. . Z=0 . 20:. X|
000002c0  3d 30 20 b8 20 32 30 0d  01 9a 19 20 f1 8a 5a 2c  |=0 . 20.... ..Z,|
000002d0  58 29 3b bd 28 41 28 5a  2c 58 29 2b 33 32 29 3b  |X);.(A(Z,X)+32);|
000002e0  0d 01 a4 17 20 ed 3a 59  41 3d 30 3a 59 44 3d 30  |.... .:YA=0:YD=0|
000002f0  3a e5 20 8d 44 64 40 0d  01 ae 13 20 46 3d 8e 22  |:. .Dd@.... F=."|
00000300  4d 41 5a 45 2d 44 41 54  41 22 0d 01 b8 1a 20 e3  |MAZE-DATA".... .|
00000310  20 5a 3d 30 20 b8 20 32  30 3a e3 20 58 3d 30 20  | Z=0 . 20:. X=0 |
00000320  b8 20 32 30 0d 01 c2 0f  20 e8 23 46 2c 41 28 5a  |. 20.... .#F,A(Z|
00000330  2c 58 29 0d 01 cc 0c 20  ed 20 58 3a ed 20 5a 0d  |,X).... . X:. Z.|
00000340  01 d6 08 20 d9 23 46 0d  01 e0 1c 20 db 3a e3 20  |... .#F.... .:. |
00000350  5a 3d 30 20 b8 20 32 30  3a e3 20 58 3d 30 20 b8  |Z=0 . 20:. X=0 .|
00000360  20 32 30 0d 01 ea 19 20  f1 8a 5a 2c 58 29 3b bd  | 20.... ..Z,X);.|
00000370  28 41 28 5a 2c 58 29 2b  33 32 29 3b 0d 01 f4 06  |(A(Z,X)+32);....|
00000380  20 ed 0d 01 fe 1a 20 e3  20 5a 3d 30 20 b8 20 32  | ..... . Z=0 . 2|
00000390  30 3a e3 20 58 3d 30 20  b8 20 32 30 0d 02 08 19  |0:. X=0 . 20....|
000003a0  20 e7 20 41 28 5a 2c 58  29 3d 38 20 8c 20 51 3d  | . A(Z,X)=8 . Q=|
000003b0  5a 3a 57 3d 58 0d 02 12  19 20 e7 20 41 28 5a 2c  |Z:W=X.... . A(Z,|
000003c0  58 29 3d 39 20 8c 20 45  3d 5a 3a 57 3d 58 0d 02  |X)=9 . E=Z:W=X..|
000003d0  1c 0c 20 ed 20 58 3a ed  20 5a 0d 02 26 13 20 59  |.. . X:. Z..&. Y|
000003e0  41 3d 51 3a 59 44 3d 57  3a 54 45 3d 91 0d 02 30  |A=Q:YD=W:TE=...0|
000003f0  09 20 41 24 3d be 0d 02  3a 36 20 e7 20 41 24 3d  |. A$=...:6 . A$=|
00000400  22 5a 22 8c 20 e7 20 41  28 59 41 2d 31 2c 59 44  |"Z". . A(YA-1,YD|
00000410  29 3d 30 20 84 20 41 28  59 41 2d 31 2c 59 44 29  |)=0 . A(YA-1,YD)|
00000420  3d 39 20 8c 20 59 41 3d  59 41 2d 31 0d 02 44 35  |=9 . YA=YA-1..D5|
00000430  20 e7 20 41 24 3d 22 58  22 8c 20 e7 20 41 28 59  | . A$="X". . A(Y|
00000440  41 2b 31 2c 59 44 29 3d  30 84 20 41 28 59 41 2b  |A+1,YD)=0. A(YA+|
00000450  31 2c 59 44 29 3d 39 20  8c 20 59 41 3d 59 41 2b  |1,YD)=9 . YA=YA+|
00000460  31 0d 02 4e 36 20 e7 20  41 24 3d 22 3a 22 8c 20  |1..N6 . A$=":". |
00000470  e7 20 41 28 59 41 2c 59  44 2d 31 29 3d 30 20 84  |. A(YA,YD-1)=0 .|
00000480  20 41 28 59 41 2c 59 44  2d 31 29 3d 39 20 8c 20  | A(YA,YD-1)=9 . |
00000490  59 44 3d 59 44 2d 31 0d  02 58 36 20 e7 20 41 24  |YD=YD-1..X6 . A$|
000004a0  3d 22 2f 22 8c 20 e7 20  41 28 59 41 2c 59 44 2b  |="/". . A(YA,YD+|
000004b0  31 29 3d 30 20 84 20 41  28 59 41 2c 59 44 2b 31  |1)=0 . A(YA,YD+1|
000004c0  29 3d 39 20 8c 20 59 44  3d 59 44 2b 31 0d 02 62  |)=9 . YD=YD+1..b|
000004d0  15 20 e7 20 41 28 59 41  2c 59 44 29 3d 39 20 8c  |. . A(YA,YD)=9 .|
000004e0  20 f9 0d 02 6c 15 20 e7  20 91 3e 54 45 2b 33 30  | ...l. . .>TE+30|
000004f0  20 8c 20 8d 54 66 42 0d  02 76 0b 20 e5 20 8d 54  | . .TfB..v. . .T|
00000500  70 42 0d ff                                       |pB..|
00000504
MAZE.m0
MAZE.m1
MAZE.m2
MAZE.m4
MAZE.m5