ZXTape! 0Created with Ramsoft MakeTZXTWO m b236099\,0:23658j\,0::2:7:0:0:0:0 :3,0;" EDUCATIONAL COMPENDIUM SIDE 2: "''" TORTOISE GRAPHICS "''"  The Hicks Consortium 1983 "''" Produced by Orwin Software " d1;14,1;" VOLUME SETTING OK ";16,1;" LEAVE THE TAPE RUNNING......" ( "tortoise" '"TWO"1 tortoise  T ."tortoise" - menu for tortoise graphics tape C P Hicks; 24/5/83 )mem=23732\+256*23733\ mem-168 ()mem=23732\+256*23733\ 2b$(32 ) d&0:7:0:4: nV1;1;" EDUCATIONAL COMPENDIUM SIDE 2: SPECTRUM TORTOISE GRAPHICS " x%"  The Hicks Consortium 1983 "; z!" Produced by Orwin Software" +5,9 ;1;"STOP THE TAPE" = 5;8,1;"No. Program Size Filename" 6 410 ,1;"1 - Graphics 48k tort48 " 412 ,1;"2 - Graphics 16k tort16 " 414,1;"3 - Maze 16k tortmaze" 416,1;"4 - Trail 16k tortrail" 7 }mem<6500010 ,29;8;1;"";19,0;"";0;"48k version needs 48k Spectrum" 621,0;" Press 0 to escape " ,^4,36$:248,0:0,80P:-248,0:0,-80P  k=1 ^0.2~L,0:#0;6;1;1,3;"Which program do you want?"; 502:k$=:k$=""k=k+2-8*(k>8):8;1;0;16,1;" ";5+k,1;" ";''1;7+k,1;" ";  k$="1"n$="tort48":500  k$="2"n$="tort16":500 "k$="3"n$="tortmaze":500 "k$="4"n$="tortrail":500  k$="0"  410 ꏏ n$="tort48"mem<65000;:#0;1,2;7;0;1;"tort48 needs a 48k Spectrum":1,1:100d:;:400 y:3,0;"Ready to load ";n$;12 ,0;1;"START THE TAPE AND PRESS ANY KEY":0.1}L,0 I0:12 ,0;b$;6,0;"Searching tape for ";n$ &: 0n$ : ':"tortoise"10 : stort48 \i\i^i ꏏtort48 C P HICKS, 28/5/83 k$="s":1800 -21004:set up m/c for screen transfers k$="s" # 1800 ((maxmac="2000":m$(maxmac):1900l 2Bl$(k$ )=(k$+32 *(k$"A"k$"Z")):make k$ lower case <2l(k$)=(k$"a"k$"z"):check if lower case FAbeep0="0.02":beep=beep0:note="34":236099\,beep*"2500" P 100d Zc0:k$=l$():beep,note: dmain -e$=c18+c1+"L"+c18+c0:flashing l cursor v(c9) 1880X 1600@ 1500 500 35#  main loop "800 :1887_:510 %auto=c0i=mc1:restore old screen auto=c1518 imm (auto=0) 1850::#c0;c1;"F";c0;"orward,";c1;"B";c0;"ackward,";c1;"R";c0;"ight,";c1;"L";c0;"eft,";c1;"W";c0;"ipe";c1;"Q";c0;"uit,";c1;"I";c0;"nk(";ink;" ";border;"),";c1;"P";c0;"aper(";paper;" ";border;"),";c1;"U";c0;"p,";c1;"D";c0;"own? "; 1#c0;c1;c8;c2,c21+c3*pen;"_";c2,30;e$; -90Z:(k$"?"k$<"a")k$>"z"515 1850::a$=""  530 auto a$DZz$a$=z$(̱a$)a$=""  a$""524   1880X:headings=c1  510  23560\c01850::#c0;c2,c4;"interrupted from keyboard";:502*beep,c2:502:1850::23560\,c13:a$="":522   1865I auto=c1len=a$*(a$63?)+63?*(a$>63?):#c0;c0,c0;c1;"size=";size;c0;" ";c1,c0;k$;a$(len);z$(63?-len);c1,c0;c1;c1;" "; k$=" "510 rauto=c1a$c1l(a$(c1))a$=k$+a$:k$="m":a$c3a$(c2)="v"a$(c3)"0"a$(c3)"9"k$=a$(c1):a$=a$(c2) auto=c0k$"c"1887_ k$="f"k$="b"600X k$="l"k$="r"700 k$="i"k$="p"575? k$="u"pen=c0:574> ,k$="d"pen=c1:paper;ink;x,y:574> k$="c"1885]:510  ?k$="g"1200:turtle=(turtle=c0):1200:574> !k$="w"1350F:510 "autoc0556, #k$="o"1030:508 $k$="s"2900T :508 &hk$="q"#c0;"Do you really want to quit? ";e$;:c0:w$=l$():beep,note:1850::k$="q":w$="y" 'k$="q"508 (k$="t"2200:508 )k$="?"1650r:508 +k$="n"1290 :508 .k$="m"1400x:508 0k$="x"k$="y"584H 2Jk$="h"1200:x=128:y=92\:a=c0:1250:500 4/auto=c0k$="a"a$="":1300:508 7k$="v"850R:508 8/auto=c0k$="e"2000:a$="":508 9#auto=c1k$="["k$="{"510 :Hauto=c1k$="]"num=r$:num>c0size=size/num:r$=r$(c2):510 ;(auto=c1k$="("2800 :510 <(auto=c1k$=")"2850" :510 =R#c0;c0,c4;"Command '";k$;"' not recognised";:2405e :1880X:508 >1260:510 ?ink & paper @o$="ink":k$="p"o$="paper" A0auto=c0#c0;"Colour code for ";o$;" (0-7)? "; B1100L:err=c1508 C&numc72428| :508 Dk$="p"paper=num Ek$="i"ink=num F 1270 G 510 Hx & y Lauto=c0#c0;k$;" value? "; N1100L:errc0508 Ox0=c0:y0=c0 Pk$="x"x0=num+xmin-x Qk$="y"y0=num+ymin-y R1000:err=c1508 S 1270 T11200:x=x+x0:y=y+y0:c1;c1;c8;c8;x,y Upen=c1paper;ink;x,y V1200:510 Xb & f ]%o$="backward":k$="f"o$="forward" b)auto=c0#c0;c2,c0;"How far ";o$;"? "; g1100L:err=c1508 lk$="b"num=-num qr=num*size:r=c0508 v 900 l & r o$="right":k$="l"o$="left" ,auto=c0#c0;c2,c0;o$;" by what angle? "; "1100L:err=c1num=90Z err=c2num=c0 num=c0508 k$="r"num=-num  a=a+num ?a=a+360h*((a/360h)*((axmaxx+x0ymaxy+y0c32)+len*(lenc32) I+1895g:c21,(c32-len)/c2;a$(len);: Lget number M%err=c0:var=c0:auto=c01110V N=i=c0:a$(c1)=" "Ʊa$>c1a$=a$(c2):1870N:1102N Oautoc1a$(c1)="v"err=c2:num=c0:var=c1:a$>c1a$=a$(c2):a$(c1)"1"a$(c1)"9":i=c1:num=v(a$(c1)):err=c0::1108T Pvar=c1a$="":2450 : R5i=i+c1:a$(i)"0"a$(i)"9"1870N:1106R S8num=c1:err=c1:i=i-c1:i>c0iia$=a$(i+c1): U a$="": V&23560\,c0:n$="":al=c0:al1=c0 `4#c0;c1;"N";c8;:c0:ak=(l$()):23560\,c0 afal=c0ak="?"#0;"?";:2465 :beep*c10,note:502:2465 :#0;c8+" "+c8; bAvar=c0al=c0ak="v"var=c1:#c0;"v";:beep,note:1120` cak=c01120` o,ak=c13#c0;" ";:c2*beep,note:1190 tPak=c12al>c0#c0;" "+c8+c8+95_+c8;:al=al-c1:al1=al1-c1:1180 ak<"0"ak>"9"1120` Tbeep,note:#c0;ak;95_;c8;:al=al+c1:n$=n$+" ":n$(al)=ak:akc32al1=al alc0alc91850::2450 :err=c2:num=c0:1198  num=v(num) 1850:: draw/erase tortoise  turtle=c0 x>xmaxxymaxy255numc0 auto=c01895g size=size*num:r$=num+r$ a$="[ "+b$+" ] "+a$ auto=c11850: %1265:auto=c1:23560\,c0  clear Dc0:c0:c0:c0:paper:ink:border::pap0=c7:ink0=c0:pap0:ink0 z$(64@):l$(c32) >pen=c1:turtle=c1:s$="":x$="":step=c0:err=c0:1880X (x=128:y=92\:a=c0:size=c1 3xmin=c8:xmax=247:ymin=c16:ymax=167 1850::p0=c5:1595; ,*c1;paper;ink;x,y:c1;paper;ink;x,y 6 ;c1:ink:xmin-c1,ymin-c1:p0;xmax-xmin+c2,c0:p0;c0,ymax-ymin+c2:p0;xmin-xmax-2,c0:p0;c0,ymin-ymax-c2:xmin-c1,ymin-c1:ink0:c0: @ headings J$headings=c1:23560\,c0:kk=c0 O&kk=kk+c1:1700:i=c1kk:b$:i Pb$="end "1610J Tpaper=c0:border=c4:ink=c7 U 1500 Vpaper:ink:border ^1830&:1850: `paper c 2497 db$(c5)="town " fkk=c2size=c5:2492 g4100d:1850::23560\c01650r hPa$=b$:auto=c1:500:1200:1880X:23560\c01650r i61850::2497 :500:kkc21648p j61643k:mc0=23296[:i=c0c18:n:mc0+i,n:i k33!,0,64@,14,32 ,175,126~,31,119w,35#,13 ,32 ,249,62>,80P,188,32 ,241,201 l'1850::p0=c0:c1:1595;:c0 mc0:c7;c10,c16;" ";:c1:1830&:c0:2495 :c7;c8,c0;"";:c2,c10:i=c10c1-c1:#c0;c0,c15;i;" ";:502:i:#c0;c1;c0,c15;"Go":i=c1180:j=mc0:c7;c8,c0;"";:i p 1615O r<beep,note:paper=c6:border=c6:ink=c0:pap0:ink0:border s headings=c0 t7:1850::c1;" SPECTRUM TORTOISE GRAPHICS 48k"; v ::"The tortoise draws lines with a ";"pen it is carrying on its tail. ";"You move it around the screen ";"using the following words:" xTc19,c0;c1;" You only use the first ";" letter of each word "; zkk=c0:2500 |.c6,c0;:i=c1c12:31;" ";:i:c6,c0 }a$,b$:kk=kk+c1 ~"a$="end"2405e :1672 'kkc122405e :kk=c0:1660| 0c1;a$(c1);c0;a$(c2);c8;"- ";b$:1661} a$=""   demo pics "i0 g u i7 g x0 y50 d triangle 10 f15 i6 square 20 f30 i5 pentagon 30 f58 i4 hexagon 37 f60 i3 heptagon 43 g v1=0 v2=7 i7 p0 (6 pv1 iv2 w b v1=v1+1 v2=v2-1)" D"i0 g u i7 g x91 y64 d tortoise u l90 f1 r90 f14 p3 l30 f2 r30 g " U"v1=9 (3 v1=v1-2 i v1 l f59 l f50 l120 f100 l120 f100 l120 f50 l f85 l180 f21 r ) " "town i0 w i p7 w p ","end " initial headings  c0="0":c1="1":c2="2":c3="3":c4="4":c5="5":c6="6":c7="7":c8="8":c9="9":c10="10":c11="11":c12="12":c13="13":c14="14":c15="15":c16="16":c17="17":c18="18":c19="19":c20="20":c21="21":c22="22":c32="32"  c0:c0:c0 c0:c1:c7: Fc9,c3;"Please wait, the program is";c11,c6;"being set up for you"; !$k$="s"c5,c9;c1;"STOP THE TAPE" &0c15,c5;c6;c0;"TORTOISE";c15,c19;"GRAPHICS" + 2495 0&c2,c12;c6;"SPECTRUM":c1,c1:c10: 9ꏏ ::border:;:pap0:c21,c0;border;31;" ";c0,c0;: D!ꏏtake blanks from front of a$ F7a$""a$(c1)=" "a$=a$(c2):1870N:1862F G Hꏏlet k$=a$(c1) I-k$=l$(a$(c1)):len=a$-c1:len=c0a$="": Ja$=a$(c2): Nauto=c1#c0;c1;c1;" ";: S Wꏏreset values X-auto=c0:r$=c0:t$="end":a$="":size=c1: \restore previous values ]i=mc1:x$=y$:step=stepkept:x=xkept:y=ykept:x8=x8kept:y8=y8kept:ink=inkkept:paper=paperkept:a=akept:pen=penkept:turtle=turtlekept:1880X: ^store current values _i=mc2:y$=x$:stepkept=step:xkept=x:ykept=y:x8kept=x8:y8kept=y8:inkkept=ink:paperkept=paper:akept=a:penkept=pen:turtlekept=turtle: frestore old screen g i=mc1: linitialise macros qm$="end":1900l:i=c0 v1a$,b$:len1=a$:len2=b$:a$="end"1918~ x*hash=c0:a$(c1)="#"hash=c1:a$=a$(c2) {di=i+c1:p=a$+b$+c2:m$(p+c1)=m$(c1):m$(c1p)=((a$+100d*hash))+a$+(±b$)+b$:1910v ~auto=c1:a$="###":2700  "#forward","f","#backward","b","#left","l","#right","r","#up","u","#down","d","#repeat","(","#next",")","#ink","i","#paper","p","#wipe","w","#macro","m","#home","h","#value","v","#graphic","g","#auto"," ","#imm"," "  "square","f1 l f1 l f1 l f1 l" #"rectangle","f1 l f2 l f1 l f2 l" &"triangle","f1 l120 f1 l120 f1 l120" "pentagon","(5 f1 l72)" "hexagon","(6 f1 l60)" "heptagon","(7 f1 l52) r4 " "circle","(20 f1 l18)" !"pattern","(8 f2 (4 f1 l) l45)" '"spiral","v1=1 (40 v1=v1+1 f v1 l45)" "house","m square10 l f10 r m triangle10 u r f4 l f2 d m square2 u f4 d m square2 u r f2 d m square2 u r f2 d m square2 u f2 l f4 r f2 l180 d" *"street","house f20 house f20 house b40" ?"town","g h x15 y10 street4 x10 y95 street2 f120 street2 h g" "tortoise","(2 f11 r30 tort l90 f3 l30 f6 r60 tort l90 f3 l60 ) l120 f3 r30 f2 l60 f2 r120 f2 r120 f2 l90 u f14 d f1 tort u l90 f3 l90 d f1 " 8"tort","f2 l30 f1 l60 f2 l60 f1 l30 f2 l90 u f3 l90 d"  "end","h" edit macros 5c5::pap0:c1;"CHANGE, DEFINE, and ERASE MACROS"; 3000 :c11,c0; c$="":o$="":2093- څ#c0;c1;"C";c0;"hange, ";c1;"D";c0;"efine, or ";c1;"E";c0;"rase macro? ";e$;:90Z:1850::w$=k$:w$=c132090* !w$="c"o$="change":2016  w$="e"o$="erase":2016 !w$="d"o$="define":2020  2006 nummacc22020 (nummac=c0w$="e"w$="c"2444 : nummac=c1w$="e"w$="c"a$=m$(c2̯m$(c1)+c1):2091+:c16,c0;"The only macro defined is ";"'";a$;"'.";:#c0;"Is that the one to ";o$;"? ";e$;:c0:b$=l$():beep,note:1850::b$="y"2026  2006 identify macro 2091+:c12,c0;"Input the name of the macro you ";"want to ";o$;".";'':w$="e""Be careful you don't erase a ";"macro which is needed by ";"another macro.";  3050 ?a$="?"c19,c0;"Reply with the name of a macro";:2023 a$c12090* c$="'"+a$+"'":2091+ C2700 :w$="c"w$="e"err=c1hash=c12445 :2090* o$=o$(̱o$-c1)+"ing" w$="d"2040 w$="c"2060  erase  2091+ .nummac=nummac-c1:sparem=sparem+len1+len2+c2 m$(p)=m$(p+len1+len2+c2)  2080   define 'a$=c$:err=c02430~ :2006 2091+:sparem<256c12,c0;"You are running out of space, ";"and may have to delete an old ";"macro to make room for the new ";"macro ";c$;:2405e :2091+ %nummacc0s$=""x$=""2056 Dc12,c0;"You can define the new macro ";c$;" starting from:";'' Anummacc1" - an existing macro";'" >(type in its name)" Os$""x$""" - existing command sequence";'" >(type 'auto' or 'imm')" (" - scratch";'" >(press ENTER)"; <#c0;"Which do you want? ";:3065 :a$="?"2051 a$=""2060  2091+:a$c1 a$="auto"a$=s$:2064 a$"imm"2059  a$=x$:20971:2064  ,2700 :err=c12445 :2040  change/define macro a$=b$ len=c$:2091+ T2600( :a$=""#c0;"No commands entered, so ignored ";:2405e :2090* +a$(c1)="?"2420t :a$="":2065 Eb$=(c$-c2)+c$(c2(c$-c1))+(a$)+a$:len=b$:w$="c"2075  define len+c9>sparem20960: Um$(len+c1)=m$(c1):m$(c1len)=b$:nummac=nummac+c1:sparem=sparem-len:2080   change 'len-len1-len2+c9>sparem20960: 3m$(p+len)=m$(p+len1+len2+c2):m$(pp+len-c1)=b$  sparem=sparem+len1+len2+c2-len  !o$=o$(̱o$-c3)+"ed":2091+ "c5;c1,c0;z$;z$;z$;z$;z$; ' 2435 :k$="e"2000 * +clear lines -#c1;c11,c0;l$;c11,c0;o$;" ";c$; .'c12,c0;z$;z$;z$;z$;l$;:1850:: 0s$=a$:2091+:c12,c0;o$;" ";c$;c16,c0;"No room for definition - it has ";"been put into 'auto' so you can ";"erase something else and then ";"come back to this definition":2405e : 1redo imm in a$ 26j=c0:i=c1̱a$:a$(i)=c13a$(i)=a$(i+c2):j=j+c2 3i:a$=a$(̱a$-j): 4copy screen mc H/58599:mc1=58600:mc2=58612 R/2140\:i=023:n:mc1+i,n:i \m1,0,27,33!,0,229,17,0,64@,237,176,201 fm1,0,27,17,0,229,33!,0,64@,237,176,201  32 tape handling  1895g V#c0;c0;"Tape: ";c1;"L";c0;"oad or ";c1;"S";c0;"ave? ";e$;:90Z:1850: k$="l"2300  k$"s" 1c1;c21,c0;" Save on tape "; save on tape o$="save":2298 k$="m"2260  k$"p" save screen 8c$="pic":1200:2295:k$="a"1200:  1093E +2296:c$:1200:2490 : save macros 3:c1;c14,c0;" Save macros on tape ";  c$="mac":2295:k$="a" !2296:c$m$():2490 *:c1;c2,c0;" Verifying macros on tape ";:c4,c0;"Macros saved as Character Array ";c1;c$;c0;c17,c0;"If verify fails then restart ";"by typing ";c1;"GOTO 2200";c14,c0;c0;"Position by rewinding tape back ";"to before ";c$;31;" ";:2396\ : 2485 :c8,c2;:k$="a" Uc$m$():c14,c0;z$;c17,c0;z$;c9;c1;c14,c4;"Macros on tape are ok";:2490  hc$=c$+(480+*c9)+(480+*c9):#c0;"Name on tape will be ";c1;c$;:2405e :2480 : Bc0,c0;#0;c0,c0;c1;"Press RECORD & PLAY on recorder ";: X#c0;c0;o$;": ";c1;"P";c0;"icture or ";c1;"M";c0;"acros?";:90Z:1850:: load from tape 3:c1;c14,c0;" Load from tape "; o$="load":2298 k$="m"23608 $ k$"p" &1c1;c14,c0;" Load picture from tape "; )2395[ :k$="a" .*c$:turtle=c0:2490 :1886^: 8load macros =1c1;c14,c0;" Load macros from tape "; B2395[ :k$="a" G c$m$() I&c18,c0;"Macros loaded";:2490 La$="###":2700 Q$c5::pap0:3000 :2405e V [c18,c0;" (Press ENTER if name unknown) ":border:"What name was used when it was saved on tape? ";c$:pap0:c18,c0;l$:2396\ :2485 : \?c0,c0;#c0;c0,c0;c1;"Only press PLAY on the recorder ";'': ` messages e)#c0;c2,c4;"Press any key to continue"; j%c10*beep,c1:90Z:1850:: o01000:k$=l$():beep,note:1850:: t4#c0;c0,c4;"Input series of commands";:2405e w9#c0;c0,c2;"Error in use of repeat (i...)";:2405e y<#c0;c0,c1;"Name must be 2-9 letters (a-z)";:2405e : |;#c0;c0,c0;"Error in size of number entered";:2405e ~>hash=c0c16,c0;"Macro ";c$;" already exists"'':2405e hash=c1c14,c0;c$;" already exists as a";'"command. You are not allowed to";"define a macro of the same name.":2405e ]c16,c4;"Macro ";c$;" ";o$;c18,c2;"Press ";c1;"E";c0;" to edit more macros";:2405e 6#c0;c0,c3;"There are no macros defined":2405e 3#c0;c0,c0;"Macro '";v$;"' not found":2405e 4#c0;c0,c4;"Error in using a variable":2405e K#c0;c0,c0;"Sound: beep length = ";beep;c0,28;"secs";:2405e X#c0;" Get the printer ready and then ";" press any key (A to abandon) ";:2410j -c8;c8;c8;c1;c19,c9;"Input a number";: c#c0;c0,c0;c1;" Recent immediate commands ";" are listed above ";:2405e @#c0;c0,c0;c1;"No immediate commands are stored";:2405e N#c0;"Position tape,then press any key";" (A to abandon)";:2410j X#c0;" Position and start the tape ";"then press any key(A to abandon)";:2410j ;#c0;c1;"Stop the tape,then press any key";:2410j : *c7,c12;"tortoise";c9,c12;"graphics";: *c18,c2;" The Hicks Consortium 1983": 2#c0;c2,c0;"Demo: Press any key to interrupt";: command list "Forward","moves forward" "Backward","moves backward" "Left","turns left" "Right","turns right" "Wipe","wipes screen" "Up","takes pen off paper" "Down","puts pen to paper" "Paper","change paper colour" "Ink","change ink colour" "Quit","quit program" #"Cancel","take last command back" "?","list commands" "Note","list recent commands" #"Graphic","tortoise shape on/off" ""Output","pic/macros to printer" !"Tape","save or load from tape" "Macro","use existing macro" "Auto","accept command string" "Home","centre of screen" A"X or "+19+c1+"Y"+19+c0,"input x or y position" "Edit","define & edit macros"  "Value","set variable's value" @"(i..."+19+c1+")"+19+c0,"repeat (...) i times" $ "end"," " (editing string input ->#c0;c2,c0;"Commands? ";:imax=250:low=c1:26102 2zi=c1:im=imax+e$:b$=e$+a$:xpos=33!-(23690\):ypos=24-(23691\):xpos=c32xpos=c0:ypos=ypos-c1 7 imax>256imax=256 <#c0;ypos,xpos;b$;" "; F<c0:k$=:beep,note:low=c1k$=(k$+c32*(k$"A"k$"Z")) KDk$" "k$"z"b$c1i=i-c1:b$(ii+c5)=e$+b$(i):2620< Z8k$=c12i>c1b$=b$(i-c2)+b$(i):i=i-c1:2620< db$imk$" "2695 ik$=c72605- sk$c132620< x;a$=b$(c6):i>c1a$=b$(i-c1):ia$2730 i>c122730 l(a$(i))2715 .lena=i-c1:v$=a$(lena):lena>c92790 p=c1:j=c0 [j=j+c1:m$(pp+c2)="end"numkey=numk:nummac=j-c1-numkey:sparem=maxmac-p+c2:2790 len1=m$(p) Vhash=c0:len1>100dlen1=len1-100d:numk=numk+c1:hash=c1:handle keywords ,len2=m$(p+len1+c1):lenalen12770 'a$(len1)=m$(p+c1p+len1)2780 p=p+len1+len2+c2:2750 :a$=a$(len1+c1):b$=m$(p+len1+c2p+len1+len2+c1):err=c0 auto=c01850:  storage of (i...) 1100L:err=c2 i=c0:n=c1 'i=i+c1:i>a$2423w :t$="end": Da$(i)="("a$(i)=")"n=n+(a$(i)="(")-(a$(i)=")"):nc02830 za$-i+c1c7a$(ii+c5)="repeat"l(a$(i+c6))=c0(i=c0Ũl(a$(i-c1))=c0)a$(i)="("+a$(i+c6):n=n+1:2818 ya$-i+c1c5a$(ii+c3)="next"l(a$(i+c4))=c0(i=c0Ũl(a$(i-c1))=c0)a$(i)=")"+a$(i+c4):n=n-c1:nc02830 2818 errc1numc02840  a$i -err=c1a$(i )=a$(i+c1)::no num after ( num=c0a$=a$(i+c1): Gt$=((num/256))+(num-256*(num/256))+i+a$(i)+t$  "get back (i...) ' t$="end" ,&num=256*(t$(c1))+(t$(c2))-c1 1*numc0t$=t$((t$(c3))+c4):2880@ 6=t$(c1)=((num/256)):t$(c2)=(num-256*t$(c1)) ;"a$="{ "+t$(c4((t$(c3))+c3))+a$ @ T set sound ^t#c0;c0,c0;c1;"SET SOUND";c0;" (Reply must be 0-10)";c2,c0;"Beep length (0.01 secs) ? ";:1100L:err=c1 hnum>c102910^ rbeep=num*0.01z# = -j=beep*2500 :j>255j=255 beep0=beep:236099\,j #beep,note:1850::2455  current macro display kk=c1:3022 kk=c2 nummac>c03025 ;kk=c1c5,c2;c1;c8;c8;"There are no macros defined": kk=c22444 : ѻc1;c9;c8;c8;c2,c1;"Current macros are:"::p0=c1:yp=c4:xp=c1:j=c1nummac:len3=m$(p0):len4=m$(p0+len3+c1):len3>100dlen3=len3-100d:p0=p0+len3+len4+c2:3040 3yp,xp;c1;c8;c8;c8;c8;"";m$(p0+c1p0+len3); p0=p0+len3+len4+c2 )xp=xp+c10:xp>25xp=c1:yp=yp+c1 ypc14nummac=j3040 Lc1;c8;c8;c8;c8;c16,25;"(more)";:2405e :kk=c21895g kk=c1c5::pap0 8c1;c8;c8;c8;c2,c1;"Current macros (cont):":yp=c4 j   get lc macro name #c0;"Name of macro? "; $low=c1:a$="":imax=c9:26102 a$="?"a$="" 'a$>c9űa$)+62>*(a$>62>):#c0;c0,c0;c1;"size=";size;c0;" ";c1,c0;k$;a$(len);31; k$=" "508 &a$c1l(a$(c1))a$=k$+a$:k$="m" 9k$="f"q$="How far":1100L:r=size*num:900 k$="l"k$="r"700 k$="i"k$="p"575? k$="u"pen=c0:574> ,k$="d"pen=c1:paper;ink;x,y:574>  ?k$="g"1200:turtle=(turtle=c0):1200:574> !k$="w"160 $k$="m"1400x:508 &autoc05600 +k$="n"1290  ,k$="e"2000 . 508 04k$="]"num=r$:num>c0size=size/num:r$=r$(c2) = 508 >1260:508 ?i&p A$q$="Colour code (0-7)":1100L C&numc72428| :508 Dk$="p"paper=num Ek$="i"ink=num I1270:508 l&r $q$=k$+" by what angle":1100L a=a+num*((k$="l")-(k$="r")) ?a=a+360h*((a/360h)*((axmaxx+x0ymaxy+y0c1 x$=x$+b$+c13+" " step=step+c1:step18 step=18 %x$(c1)c13x$=x$(c2):1284 x$=x$(4):  x$=""  &1295:2470 :1295: c1;c8;c8;c1,c2;x$: x macros auto=c11475 3050 :a$="" :2700 :errc01850::2445 :1880X: q$="size":1100L !auto*err=c1num=c1:1485 auto+num=c0 num2552428| : size=size*num:r$=num+r$ /a$="[ "+m$(p+len1+c2p+len1+len2+c1)+" ] "+a$ %1265:auto=c1:23560\,c0  w paper:ink::pap0:ink0 /pen=c1:turtle=c1:x$="":step=c0:1880X x="128":y="92":a=c0 -xmin=c8:xmax="247":ymin=c16:ymax="167" 1850::800  p0=5:c1:ink:xmin-c1,ymin-c1:p0;xmax-xmin+c2,c0:p0;c0,ymax-ymin+c2:p0;xmin-xmax-c2,c0:p0;c0,ymin-ymax-c2:xmin-c1,ymin-c1:ink0:c0 6 @start Tc0:c0:c0:c0 r7ink0=c0:paper=c6:pap0=paper:ink=c0:pap0:ink0:c3 t+:c1;" SPECTRUM TORTOISE GRAPHICS 16k"; v '''''''"The tortoise draws lines with a ";"pen it is carrying on its tail. ";''"You move it around the screen ";"using the commands:"'''" ";c1;"F";c0;"orward, ";c1;"L";c0;"eft & ";c1;"R";c0;"ight" xY20,c0;c1;" You only use the first ";" letter of each command "; zc16:2495 |2405e :pap0: :7;:21,c0;31;" ";c0,c0;#c0;c0,c0;:: X+auto=c0:r$=c0:a$="":size=c1::reset ed  3000 <#c0;"Define or Erase macro? ";:90Z:w$=k$:w$=c13 -nummac=c0w$="e"1850::2444 : w$"e"w$"d"2010 3050 :a$="" *2700 :w$="e"err=c12445 : w$="d"2040 .nummac=nummac-c1:sparem=sparem+len1+len2+c2 m$(p)=m$(p+len1+len2+c2):  err=c02430~ :2006 ov$=a$:sparem<256#c0;"You are short of macro space"'"- about ";sparem-c16;" letters free":2405e x$=""2060  B#c0;"Use immediate string (y/n)?";:90Z:k$"y"2060  /a$=x$:i=c1̱a$:a$(i)=c13a$(i)=a$(i+c2)  i:2066  /c0,c0;"(Maximum 100 letters) Commands? ";a$ -1850::1560:2796 :a$="" 4len=a$:len>100dlen=100d:a$=a$(len) len=len+v$+c2 Alen+c9>sparem#c0;"No room - definition ignored":2405e : dm$(len+c1)=m$(c1):m$(c1len)=±v$+v$+±a$+a$:a$="":v$="":nummac=nummac+c1:sparem=sparem-len * ` ꏏmess e&#c0;" Press any key to continue"; jc10*beep,c1:90Z: y>#c0;"Name must be 2-9 letters (a-z)":1560:2405e |,#c0;"Wrong number":1880X:2405e ~(#c0;"Macro already exists":2405e %#c0;"No macros defined":2405e ##c0;"Macro not found":2405e *#c0;c1;"immediate commands":2405e 1c3,c2;c3;c7;" The Hicks Consortium 1983": ?macro err=c1 Tauto=c01850::#c0;" Checking macro list";'" - please be patient"; 2796 :i=c0 i=i+c1:i>a$2730 l(a$(i))2715 .lena=i-c1:v$=a$(lena):lena>c92790 p=c1:j=c0 Gj=j+c1:m$(pp+c2)="end"nummac=j-c1:sparem=maxmac-p+c2:2790 len1=m$(p) ,len2=m$(p+len1+c1):lenalen12770 v$=m$(p+c1p+len1)2780 p=p+len1+len2+c2:2750 a$=a$(len1+c1):err=c0 auto=c01850:  ,a$>c0a$(c1)=" "a$=a$(c2):2796  dis %1850::nummacc02444 : p=c1:j=c1nummac:i=p+m$(p) W#c0;"Macros are:";20;m$(p+c1i);31'':p=i+m$(i+c1)+c2:2405e :j: m name c0,c0;"Name of macro? ";a$ !1560:2796 :a$="" 'a$>c9űa$