8-Bit Software Online Conversion
Rune Converter - Listing
10*TV255
20MODE2
30VDU23,1,0;0;0;0;
40PROCSI
50DIM C(8,8),B(8),V(8),R(8,8)
60COLOUR3:PROCROMREAD(224):PROCGRID
70PROCCALCULATE(224)
80x=32:y=32:GCOL3,5
90X=1:Y=1
100REPEAT:PROCCURSOR:PROCCURSOR
110IF INKEY-86 PROCCHANGE
120IF INKEY-74 PROCCALCULATE(0)
130IF INKEY-38 PROCINVERT
140IF INKEY-83 PROCERASE
150IF INKEY-54 PROCMIRROR
160IF INKEY-102 PROCMIRROR2
170IF INKEY-52 PROCROTATE
180IF INKEY-17 CALL !-4
190IF INKEY-82 THEN GOTO 1790
200IF INKEY-72 THEN GOTO 1630
210UNTIL TRUE=FALSE
220DEFPROCROMREAD(NUM):LOCAL x,y,i,d
230IFNUM<>0THEN c1=NUM:GOTO320
240VDU23,1,1;0;0;0;:*FX21,0
250VDU31,0,11:PRINTSPC(20);
260IFNUM<>0THEN c1=NUM:GOTO320
270SOUND1,-8,200,1
280VDU31,0,11:PRINT"Read chr$ no. "
290VDU31,13,11:INPUT c1
300IF c1<32 OR c1>255 GOTO 250
310VDU23,1,0;0;0;0;
320?&0B00=c1:A%=10:X%=0:Y%=11
330CALL &FFF1:FOR i=1 TO 8
340V(i)=?(&0B00+i):NEXT
350FOR i=1 TO 8:B(i)=2^(i-1):NEXT
360FOR x=1 TO 8:d=V(x):FOR y=1 TO 8
370IF d>=B(9-y) C(y,x)=-1:d=d-B(9-y)
ELSE C(y,x)=0
380NEXT:NEXT:ENDPROC
390DEFPROCGRID:LOCAL x,y,i
400FOR i=0 TO 10:VDU31,0,i
410PRINT" ";:NEXT
420COLOUR6:PRINTTAB(10,0);"Definer"
430COLOUR3
440GCOL0,7:FOR i=1 TO 9
450MOVE32*i,1024-32
460DRAW32*i,1024-(32*9):NEXT i
470FOR i=1 TO 9:MOVE32,1024-(32*i)
480DRAW32*9,1024-(32*i):NEXT:GCOL3,1
490FOR x=1 TO 8:FOR y=1 TO 8
500IF C(x,y) PROCB(0,x*32,y*32)
510NEXT:NEXT
520GCOL0,5:MOVE700,900:DRAW900,900
530DRAW900,800:DRAW700,800
540DRAW700,900:MOVE100,400
550DRAW550,400:DRAW550,160
560DRAW100,160:DRAW100,400:ENDPROC
570DEFPROCB(c,x,y) :IF c=0 GOTO 590
580C(X,Y)= NOT C(X,Y)
590FOR i=1 TO 32 STEP 4
600MOVEx+4,1024-(y-i)-32
610DRAWx+28,1024-(y-i)-32:NEXT
620ENDPROC
630DEFPROCCALCULATE(N):LOCAL i,x,y
640FORi=1 TO 8:B(i)=2^(i-1):NEXT i
650FOR x=1TO8:V(x)=0:FOR y=1TO8
660IF C(y,x)=-1 V(x)=V(x)+B(9-y)
670NEXT:NEXT:FOR i=1 TO 8
680VDU31,5,i:PRINT;÷V(i):NEXT i
690VDU23,1,1;0;0;0;:*FX21,0
700VDU31,12,13:PRINTSPC(6);
710IF N<>0 c2=N:GOTO 740 ELSE SOUND1,-
8,170,1
720VDU31,0,13:PRINT"Redefine no.";
730INPUTc2:IFc2<224 OR c2>255THEN700
740VDU23,1,0;0;0;0;
750VDU23,c2:FOR i=1 TO 8:VDUV(i)
760z=2:x=20
770NEXT:VDU31,12,5,c2
780VDU31,z,x,224,225,226,227,228,229
790VDU31,z,x+1,230,231,232,233,234,235
800VDU31,z,x+2,236,237,238,239,240,241
810VDU31,z,x+3,242,243,244,245,246,247
820VDU31,z,x+4,248,249,250,251,252,253
830VDU31,z,x+5,254,255
840REPEAT UNTIL NOT INKEY-74:ENDPROC
850DEFPROCCURSOR:*FX4,1
860GCOL3,2:PROCBLOCK(x,y)
870IF INKEY-58 PROCUP
880IF INKEY-42 PROCDOWN
890IF INKEY-26 PROCLEFT
900IF INKEY-122 PROCRIGHT
910IF INKEY-1 GCOL3,1:PROCB(1,x,y)
920GCOL3,2:PROCBLOCK(x,y):*FX4
930ENDPROC
940DEFPROCBLOCK(x,y)
950FORi=1 TO 16 STEP 4
960MOVEx+16,1024-y-8-i
970DRAWx+20,1024-y-8-i:NEXT i:ENDPROC
980DEFPROCUP :IF Y=1 THEN ENDPROC
990Y=Y-1:y=y-32:GCOL3,2
1000PROCBLOCK(x,y+32):PROCBLOCK(x,y)
1010ENDPROC
1020DEFPROCDOWN
1030IF Y=8 THEN ENDPROC
1040Y=Y+1:y=y+32:GCOL3,2
1050PROCBLOCK(x,y-32):PROCBLOCK(x,y)
1060ENDPROC
1070DEFPROCLEFT :IF X=1 THEN ENDPROC
1080X=X-1:x=x-32:GCOL3,2
1090PROCBLOCK(x+32,y):PROCBLOCK(x,y)
1100ENDPROC
1110DEFPROCRIGHT
1120IF X=8 THEN ENDPROC
1130X=X+1:x=x+32:GCOL3,2
1140PROCBLOCK(x-32,y):PROCBLOCK(x,y)
1150ENDPROC
1160DEFPROCCHANGE
1170PROCROMREAD(0):PROCGRID
1180PROCCALCULATE(0)
1190X=1:Y=1:x=32:y=32:ENDPROC
1200DEFPROCINVERT
1210FORi=1TO8:FORj=1TO8
1220C(i,j)=NOT(C(i,j)):NEXT,
1230PROCGRID:PROCCALCULATE(0)
1240ENDPROC
1250DEFPROCERASE
1260FORi=1TO8:FORj=1TO8:C(i,j)=0
1270NEXT,:PROCGRID:PROCCALCULATE(0)
1280ENDPROC
1290DEFPROCMIRROR
1300FORi=1TO8:FORj=1TO8
1310R(i,j)=C(i,9-j) :NEXT,
1320FORi=1TO8:FORj=1TO8
1330C(i,j)=R(i,j):NEXT,:PROCGRID
1340PROCCALCULATE(0):ENDPROC
1350DEFPROCMIRROR2
1360FORi=1TO8:FORj=1TO8
1370R(j,i)=C(9-j,i) :NEXT,
1380FORi=1TO8:FORj=1TO8
1390C(i,j)=R(i,j):NEXT,:PROCGRID
1400PROCCALCULATE(0):ENDPROC
1410DEFPROCROTATE
1420FORi=1TO8:FORj=1TO8
1430R(i,j)=C(j,9-i):NEXT,
1440FORi=1TO8:FORj=1TO8
1450C(i,j)=R(i,j):NEXT,:PROCGRID
1460PROCCALCULATE(0):ENDPROC
1470DEFPROCSI
1480VDU28,10,30,19,15
1490F=3:S=2
1500COLOURF:PRINT"R";:COLOURS:PRINT"ota
te"
1510COLOURF:PRINT"M";:COLOURS:PRINT"irr
or"
1520COLOURF:PRINT"U";:COLOURS:PRINT"psi
de dwn";
1530COLOURF:PRINT"I";:COLOURS:PRINT"nve
rt"
1540COLOURF:PRINT"C";:COLOURS:PRINT"lea
r all"
1550COLOURF:PRINT"N";:COLOURS:PRINT"ew
char"
1560COLOURF:PRINT"R";:COLOURS:PRINT"et
calc"
1570COLOURF:PRINT"Q";:COLOURS:PRINT"uit
"
1580COLOURF:PRINT"S";:COLOURS:PRINT"poo
l"
1590COLOURF:PRINT"@";:COLOURS:PRINT"Sav
e"
1600COLOUR6:PRINT'"Author: "
1610PRINT"J.Henson."
1620COLOUR1:VDU26:ENDPROC
1630REMsave
1640*FX21,0
1650VDU28,0,31,17,30,12
1660CLS:INPUT NAME$
1670IF LEN(NAME$)>10 OR LEN(NAME$)<1 TH
EN CLS:GOTO 1660
1680*OPT1,0
1690ON ERROR PROCerror
1700CLS:PRINT"Saving"
1710OSCLI("SAVE"+CHR$34+NAME$+CHR$34+"
0C00 0D00")
1720ON ERROR OFF
1730*OPT1,1
1740PRINTCHR$12;"Saved data."
1750I=INKEY(400)
1760CLS
1770VDU26
1780GOTO100
1790REMspool
1800Z=c1
1810*FX21,0
1820VDU28,0,31,17,30,12
1830REPEAT
1840CLS:INPUT"Name:"N$
1850INPUT"Start:"line
1860INPUT"Inc. :"nc
1870UNTIL LEN(N$)<11 AND LEN(N$)>=1
1880ON ERROR PROCerror
1890CLS:OSCLI("SPOOL "+N$)
1900ON ERROR OFF
1910FOR I%=224 TO 255:m=&C00:FORI=224 T
O 255
1920PRINTSTR$(line);"VDU23,";STR$(I);
1930FOR J=m TO m+7:PRINT",";STR$(?J);:N
EXT
1940PRINT:line=line+nc:m=m+8:NEXT:*SPOO
L
1950VDU12,26:PROCROMREAD(Z):PROCGRID:VD
U31,12,5,c2:GOTO100
1960DEFPROCerror
1970IF ERR<>201 GOTO 2010
1980PRINT"Disk read only.":I=INKEY(900)
1990PRINT"Make disk R/W.":I=INKEY(900)
2000PRINT"Space when done.":REPEAT:UNTI
L INKEY$(0)=" ":ENDPROC
2010CLS:REPORT:PRINT;" at line ";ERL:EN
D