ZXTape! 0Created with Ramsoft MakeTZXKEYCODE 1 1p) 3 61:5:5:0:0:0 57087:23659k\,0:0,8;"";1,8;"";2,8;"" (L5,14;"";6,14;"";7,14;"" 2p10 ,8;"";11 ,8;"";12 ,8;"" <67:0:14,8;" David Wright" F;17,3;1;"MAIN PROGRAM NOW LOADING" P5:5 Z"" d"" Grapdisp O !Y6)#!H 7?~w#  :{wY#!@>@=G6#!@!X!W!Z 08<<80  << ??BBBBB< <0<< <0@ @! ?? !Ј 0 F`0bF 0 b0`BBBBB< 00?? 00&,80``d4 08,& 4d``8?8  8?8?@`BBBBB<!!!3>rKEYCODE k%kB$kDavid Wright Ȉr=(q=1)*p+(q1p=13 )*(12 +q)+(q=11 p13 )*(36$-p)+(q1q11 p=1)*(46.-q)  dq=1:p=1:pe=131:22528X,pe:22529X,pe:22560 X,pe:22561!X,pe 2,26;" Use ";3,26;"CURSOR";4,26;" KEYS ";5,26;" to ";6,26;" MOVE ";12 ,26;" PRESS";13 ,26;" 0 to ";14,26;(" TEST "flag1=0)+(" CHECK"flag1=1) =""520  i$=:i$="0"2000 &i$<535ůi$>568520 v=i$ ! q1=q:p1=p &Jq=1q=11 p1=p1+(v=8p<13 )-(v=5p>1) 05q=1(p=1p=13 )q1=q1+(v=6) :6q=11 (p=1p=13 )q1=q1-(v=7) D5q1q11 q1=q1+(v=6)-(v=7) Xgx=22462W+64@*q+2*p:pe=x-128:x,pe:x+1,pe:x+32 ,pe:x+33!,pe ]ix=22462W+64@*q1+2*p1:pe=x+128:x,pe:x+1,pe:x+32 ,pe:x+33!,pe bq=q1:p=p1:520 dq=1:p=1:pe=131:22528X,pe:22529X,pe:22560 X,pe:22561!X,pe "3,26;" Use ";4,26;" STICK";5,26;" to ";6,26;" MOVE ";12 ,26;" PRESS";13 ,26;" FIRE ";14,26;"BUTTON";15,26;" to ";16,26;(" TEST "flag1=0)+(" CHECK"flag1=1) 31=0720 %z=31:z162000  q1=q:p1=p y(q=1q=11 )p1=p1+(p<13 (z=1z=5z=9 ))-(p>1(z=2z=6z=10 )) Iq=1(p=1p=13 )q1=q1+(z=4z=5z=6) Kq=11 (p=1p=13 )q1=q1-(z=8z=9 z=10 )  ^q1q11 q1=q1+(z=4z=5z=6)-(z=8z=9 z=10 )  gx=22462W+64@*q+2*p:pe=x-128:x,pe:x+1,pe:x+32 ,pe:x+33!,pe %ix=22462W+64@*q1+2*p1:pe=x+128:x,pe:x+1,pe:x+32 ,pe:x+33!,pe *q=q1:p=p1:720 9000(#:9500% 64740 64805% 64782 64740:0,27;"TEST ";1,29;move;2,27;"max";max;4,27;"PRESS";5,27;"T to ";6,27;"TEST ";8,27;"PRESS";9 ,27;"S to ";10 ,27;"SET ";11 ,27;" ";12 ,27;"PRESS";13 ,27;"C to ";14,27;"CHECK";16,27;"PRESS";17,27;"K if ";18,27;"CODE ";19,27;"KNOWN" ""1020 =""1021 "i$=:64782:64740 (i$="T"i$="t")move=maxa$=" ":9 ,0;a$;10 ,0;"You have already had the ";11 ,0;"maximum number of TESTS. ";12 ,0;a$:9495%:990 6i$="T"i$="t"flag1=0:500+200*jy 6i$="C"i$="c"flag1=1:500+200*jy i$="K"i$="k"4000 (i$="S"i$="s"6000p+100d*jy $ 1000  .3,5:653324 3flag1=1k=111 :s$(k)=n$(k):k 3flag1=0k=111 :s$(k)=m$(k):k  ps=p:qs=q E(q=1q=11 )(p=1p=13 )64740:a$=" ":9 ,0;a$;10 ,0;"You cannot ";("TEST "flag1=0)+("CHECK"flag1=1);" from a ";11 ,0;"corner position. ";12 ,0;a$:9495%:990+8436 *(flag=5) 200:(flag1=0r$(1,r)="1")a$=" ":9 ,0;a$;10 ,0;"You have already done a ";11 ,0;"TEST from this position! ";12 ,0;a$:9495%:990 r$(1,r)="1" #t$(11 ,13 ):ab=0 !p=1d=2:p=2 #p=13 d=4:p=12 !q=1d=3:q=2 #q=11 d=1:q=10  2010+100d*d 4q=13000 >Ps$(q-1,p)="1"d=3:qn=q:pn=p:gr=6:ab=1:2500 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y,x;"";y+1,x;"":2650Z ()y,x;"";y+1,x;"":2650Z 2)y,x;"";y+1,x;"":2650Z <)y,x;"";y+1,x;"":2650Z F)y,x;"";y+1,x;"":2650Z P)y,x;"";y+1,x;"":2650Z ZN7:0:t$(q,p)=(gr+480):q=qn:p=pn:2000+100d*d flag1=03030 (flag09300T$+25*flag *.3,5:9495%:1000 Xy=2*q-2:x=2*p-2:ys=2*qs-2:xs=2*ps-2 a(qs=qps=pab=1)65344@:y,x;1;5;"";y+1,x;"":3200 (qs=qps=pab=0)65344@:y,x;6;0;"";y+1,x;"";1;y,x;"";y+1,x;"":3200 3070 +10 *move i65356L:5;1;ys,xs;"";ys+1,xs;"";y,x;"";y+1,x;"":3200 i65356L:6;1;ys,xs;"";ys+1,xs;"";y,x;"";y+1,x;"":3200 i65356L:6;2;ys,xs;"";ys+1,xs;"";y,x;"";y+1,x;"":3200 r65356L:1;0;3;ys,xs;"";ys+1,xs;"";y,x;"";y+1,x;"":3200 &i65356L:4;1;ys,xs;"";ys+1,xs;"";y,x;"";y+1,x;"":3200 0r65356L:1;7;3;ys,xs;"";ys+1,xs;"";y,x;"";y+1,x;"":3200 :i65356L:1;5;ys,xs;"";ys+1,xs;"";y,x;"";y+1,x;"":3200 Di65356L:7;3;ys,xs;"";ys+1,xs;"";y,x;"";y+1,x;"":3200 Ni65344@:7;4;ys,xs;"";ys+1,xs;"";y,x;"";y+1,x;"":3200 Xi65344@:0;3;ys,xs;"";ys+1,xs;"";y,x;"";y+1,x;"":3200 =.3,5:move=move+1:1,29;move 64805% a=qs:b=ps:3300 a=q:b=p:3300 V9 ,27;"PRESS";11 ,28;"ANY";13 ,28;"KEY":0 200:r$(1,r)="1" 1000 <a=a+(a=1)-(a=11 ):b=b+(b=1)-(b=13 ) tc=22462W+64@*a+2*b:c,160:c+1,160:c+32 ,160:c+33!,160: nk410 ,0;"There are only ";nk;" keys set.";12 ,0;"You must set 4 keys. ";:a$=" ":9 ,0;a$;11 ,0;a$;13 ,0;a$:9495%:990 "code=0:i=111 n$(i)m$(i)code=1 i code=04100 code=14300 (a$=" ":b$="":c$=" ":d$=" "  f5:1:5:23659k\,2::23659k\,0:10 ,0;a$'b$'c$'d$ 1a$="":b$="":c$="" Bd$="":e$="":f$="" "@3,11 ;a$;4,11 ;b$;5,11 ;c$ ,@18,8;d$;19,8;e$;20,8;f$ 664680 hLk=164@:n=-30-27:.03{u\,n:64691:n:k rj=1100d:j |011 ,3;"Press ENTER to play again." ""4230 i$=:i$=""4240 i$13 4230 7:7:0 823659k\,2::23659k\,0:9627% ̄64740:1;2,26;"THE ";3,26;"PANEL ";4,26;"WILL ";5,26;"SHUT. " +k=110 :.15~,20:k pe=160:9590v% E2:2:a=36$:b=140:c=136:d=104h i=17:.15~,20:a,b:c,0:0,-d:-c,0:0,d:a=a+8:b=b-8:c=c-16:d=d-16:i H65344@:0:7:i=111 :j=113 n$(i,j)="1"2*i-2,2*j-2;"";2*i-1,2*j-2;"";1;2*i-2,2*j-2;"";2*i-1,2*j-2;"" j:.15~,20:i C6:2:1:i=111 :j=113  bm$(i,j)="1"2*i-2,2*j-2;"";2*i-1,2*j-2;"" j:.15~,20:i 0:0:7 1;4,26;"IS NOW";6,26;"YOU ";7,26;"WILL ";8,26;"NEVER ";9 ,26;"RETURN";10 ,26;"HOME! " !15,26;"PRESS ";16,26;"ENTER";17,26;" TO ";18,26;"PLAY ";19,26;"AGAIN " &""4390& (i$=:i$=""4392( *i$13 4390& +823659k\,2::23659k\,0:9627% pqv=3:w=3:pe=128+22660X:22660X,pe:22661X,pe:22692X,pe:22693X,pe u=64740:0,26;" Use ";1,26;"CURSOR";2,26;" KEYS ";3,26;" to ";4,26;" MOVE ";9 ,26;" PRESS";10 ,26;" 0 to ";11 ,26;" SET ";16,26;" PRESS";17,26;" X to ";18,26;" EXIT " z=""6010z i$=:i$="0"62008 i$="X"i$="x"6250j 'i$<535ůi$>5686010z x=i$:v1=v:w1=w <v1=v+(x=6)-(x=7):w1=w+(x=8)-(x=5) <(v1<3v1>9 w1<3w1>11 )6010z zy=22462W+64@*v+2*w:pe=22+34"*(n$(v,w)="1"):y,pe:y+1,pe:y+32 ,pe:y+33!,pe iy=22462W+64@*v1+2*w1:pe=y+128:y,pe:y+1,pe:y+32 ,pe:y+33!,pe v=v1:w=w1:6010z qv=3:w=3:pe=128+22660X:22660X,pe:22661X,pe:22692X,pe:22693X,pe =64740:0,26;" Use ";1,26;" STICK";2,26;" to ";3,26;" MOVE ";8,26;"PRESS ";9 ,26;"FIRE ";10 ,26;"BUTTON";11 ,26;"to SET";16,26;" PRESS";17,26;" X to ";18,26;" EXIT " 3i$=:31=0i$"X"i$"x"6110 %z=31:z1662008 ="X"Ŧ="x"6250j  v1=v:w1=w Gw1=w+(z=1z=5z=9 )-(z=2z=6z=10 )  Gv1=v-(z=8z=9 z=10 )+(z=4z=5z=6) <(v1<3v1>9 w1<3w1>11 )6110 zy=22462W+64@*v+2*w:pe=22+34"*(n$(v,w)="1"):y,pe:y+1,pe:y+32 ,pe:y+33!,pe $iy=22462W+64@*v1+2*w1:pe=y+128:y,pe:y+1,pe:y+32 ,pe:y+33!,pe ./v=v1:w=w1:i=120:i:6110 8G.3,5:n$(v,w)="1"n$(v,w)=" ":nk=nk-1:6220L =nk=49 ,0;" ";10 ,0;"There are already 4 keys ";11 ,0;"set. ";12 ,0;" ":9495%:nk=5:6250j Bn$(v,w)="1":nk=nk+1 Lu65344@:1;1;2*v-2,2*w-2;"";2*v-1,2*w-2;"" Q64805% Rzy=57022+64@*v+2*w:pe=46.+10 *(n$(v,w)="1"):y,pe:y+1,pe:y+32 ,pe:y+33!,pe Ti=1502:i V6010z+100d*jy jy=22462W+64@*v+2*w:pe=22+34"*(n$(v,w)="1"):y,pe:y+1,pe:y+32 ,pe:y+33!,pe:nk564805% o%flag=6nk=5nk=4 tflag=69454$ y)i$="X"i$="x"64740:1000 ~#nk=5nk=4:990 #(65344@ #2n23659k\,2::23659k\,0:a$=" ":b$=" " #5359484 % %max=11 -i$:900 %-21,0;"Press ENTER to continue" %""9491% %=""9492% % %y64740:8,27;"PRESS";10 ,27;"ENTER";12 ,27;"WHEN";14,27;"READY" %""9496% %i$=:i$=""9497% %i$13 9496% % %Hm$(11 ,13 ):n=2:d(4):d(1)=(*63?) %!r$(1,44,) %&#flag2=0:d(n)=(*63?) %0/i=1n-1:d(n)=d(i)flag2=1 %4i %6flag2=19510&% %:$n=n+1:n49510&% %?%z=23672x\:i=1z:p=:i %Di=14 %N%x=(d(i)/9 ):y=d(i)-9 *x %Xm$(3+x,3+y)="1" %bi %q pe=32 %v_w=223:22592@X+w,pe:22624`X+w,pe:23104@Z+w,pe:23136`Z+w,pe:w %{kv=128544 32 :22530X+v,pe:22531X+v,pe:22550X+v,pe:22551X+v,pe:v % %M23659k\,2:" Press ENTER to continue";x$:23659k\,0 %x$09600% %,23659k\,2::23659k\,0 % %?7:0:7:0:0:0:0 %Y23659k\,2::23659k\,0:10 ,9 ;1;"STOP THE TAPE!" %*9600%:9900&:7:0 %9600%:7:9603%:5,11 ;2;1;"WARNING!";0;8,3;"Do not use the BREAK key";10 ,15;"or STOP key.";14,0;"These will cause the program to" %{i=110 :16,10 ;"C R A S H !";6,11 ;2;"--------":.15~,.15~:10 %g16,10 ;"C-R-A-S-H !";6,11 ;2;" ":.15~,.15~:10 %i %9600%:9800H& % 9600% %z8,0;"Would you like instructions?";12 ,5;"PRESS Y for YES.";15,5;"PRESS N for NO." %!i$=:i$="Y"i$="y"9632% %i$="N"i$="n"9475% % 9628% %0:7:0:23659k\,2::23659k\,0:5,0;"You are Captain Cady of the"''"starship Ajon."''"You have landed on an uncharted"''"planet and all of the crew have"''"died from a mysterious illness."''"You are immune to the infection." %9600%:5,0;"Your brilliant logical and"''"deductive mind is famous"''"throughout the galaxy. Equally"''"famous is your absent-mindedness"''"and therein lies your problem." %9600%:5,0;"To start the ship's engines you"''"must place 4 keys in the correct"''"positions in the key panel."''"You have forgotten the secret"''"coded positions for the 4 keys." %9600%:2,0;"There are 63 possible positions"''"in which you may place a key."''"An instant calculation tells you"''"that there are 595,665 ways"''"in which you may place the"''"4 keys in the panel." %d'"It is fortunate that the makers"''"of the keycode panel had heard"''"of your absent-mindedness." %9600%:5,0;"Surrounding the key panel is a"''"border from which you may fire"''"TEST lasers. The secret coded"''"positions of the 4 keys BEND or"''"RETURN the lasers according to"''"fixed rules." %9600%:1,0;"The in and out positions of a"''"TEST laser are indicated by a"''"pair of identical symbols. In"''"the case when the in and out"''"positions of the laser are the"''"same, a special symbol is"''"printed." %]'"You use the information gained"''"from the TEST lasers to deduce"''"the correct KEYCODE." %9600%:2,0;"To assist you in this task, you"''"may SET your 4 keys in the"''"positions at which you think a"''"key should be placed. You may" %'"then CHECK that symbols marking"''"in and out positions of the"''"laser agree with the key"''"positions that you have SET." %r9600%:2,0;"When the secret KEYCODE is"''"known, SET your 4 keys to the"''"KEYCODE positions." %x''"If you are RIGHT then the"''"engines will start."'''"If you are WRONG then the"''"KEYCODE panel will shut forever!" %9600%:7:0:7:23659k\,2::23659k\,0:7,0;"NEXT FOLLOWS AN EXPLANATION OF"''"THE RULES GOVERNING HOW A"''"KEY BENDS OR RETURNS A LASER." %@9600%:9000(#:9500%:64740:64805% %$i=1100d:i:9300T$ &H4,0;"The Kempston Competition-Pro"''"Joystick can be used."'''"Is there a joystick connected?";14,6;"PRESS Y for YES";16,6;"PRESS N for NO" &M""9805M& &R=""9810R& &W-i$=:i$="Y"i$="y"jy=1:9830f& &\'i$="N"i$="n"jy=0:9830f& &a 9805M& &f jt=1 &k4i=1502:31>30jt=0 &pi &u=(jt=1jy=1)(jt=0jy=0)9880& &zjy=1jt=023659k\,2::23659k\,0:9 ,0;"Is there really a joystick"''"connected?" &jy=0jt=123659k\,2::23659k\,0:9 ,0;"I think that a joystick is"''"connected!" &H14,6;"PRESS Y for YES";16,6;"PRESS N for NO" &""9862& &=""9864& &-i$=:i$="Y"i$="y"jy=1:9880& &'i$="N"i$="n"jy=0:9880& & 9862& & &V"T",31:"T"+1,63?:"T"+2,112p:"T"+3,224 &^"T"+4,224:"T"+5,112p:"T"+6,63?:"T"+7,31 &R"U",0:"U"+1,15:"U"+2,15:"U"+3,3 &\"U"+4,1:"U"+5,0:"U"+6,127:"U"+7,127 &V"S",0:"S"+1,254:"S"+2,254:"S"+3,128 &`"S"+4,192:"S"+5,224:"S"+6,240:"S"+7,240 &G0:0:7:23659k\,2::23659k\,0 &22,7;"PUBLISHED BY ";1;"" &!3,22;1;"" &25,7;1;" 1983 D.Wright. " &&9 ,7;"COPYRIGHT WARNING" &,,,,"CASES COMPUTER SIMULATIONS LTD ":"will rigorously protect the copy":"-right,of KEYCODE. Please note":"unauthorised copying, hiring,":"and lending of this software is":"strictly prohibited." & X %