Home » Recent acquisitions » Acorn ADFS disks » adfs_AcornUser_199611.adf » Regulars » StarInfo/Lindop/!Bio/Library/IconSprite/IconSprite

StarInfo/Lindop/!Bio/Library/IconSprite/IconSprite

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 » Recent acquisitions » Acorn ADFS disks » adfs_AcornUser_199611.adf » Regulars
Filename: StarInfo/Lindop/!Bio/Library/IconSprite/IconSprite
Read OK:
File size: 0D41 bytes
Load address: 0000
Exec address: 0000
File contents
   10REM >iconsprite
   20REM A J Lindop, 28/12/93
   30REM Change IBM icon to sprite
   40REM
   50END
   60:
   70DEF FNiconsprite_name="IBM icons to Sprites"
   80DEF FNiconsprite_args="-in * -out Sprite -send"
   90:
  100DEF FNiconsprite_init
  110REM PROCwrite_in_icon(wind_hand%,3,STR$mode%)
  120=0
  130:
  140DEF FNiconsprite_key(wh%,ic%,cx%,cy%,ch%,ci%,key%)
  150=0
  160:
  170DEF FNiconsprite_mouse(mx%,my%,mb%,mh%,mi%)
  180=0
  190:
  200DEF FNiconsprite(in$,out$)
  210LOCAL in%,out%,len%,i%,l%,j%,mode%,h%,v%,load%,exec%,length%,attrib%,type%,i$,a%,b%,lb%,hm%,op%,hpi%
  220LOCAL I%,J%,K%,L%,A%,B%,C%,D%
  230DIM screen% &280
  240FOR i%=0 TO &280
  250  screen%?i%=0
  260NEXT
  270SYS "OS_File",5,in$ TO type%,, load%, exec%, length%, attrib%
  280IF type% =0 THEN PROCwarn(" Could not find the specified object")
  290IF type% =2 THEN PROCwarn(" Object is a Directory")
  300IF type% =1 THEN
  310  mode%=27
  320  D%=&7E
  330  length%=16*32
  340  REM ip%=input pixel/byte, op%=output pixel/byte
  350  h%=16:    REM input bytes/input line
  360  ip%=2:op%=2
  370  hpi%=ip%*h%            : REM input horiz. pixels = output horiz. pixels
  380  lb%=h%*8               : REM input bytes to be decoded
  390  v%=length%DIVh%        : REM input vertical lines
  400  h%=h%-1                : REM input horizontal bytes - 1
  410  len%=length%*ip%DIVop% : REM output file length
  420  ho%=hpi%-1             : REM output horizontal pixels - 1
  430  p%=4*op%               : REM output (pixel/byte) * 4
  440  in%=OPENIN(in$)
  450  out%=OPENOUT(out$)
  460  PTR#in%=0
  470  PTR#out%=0
  480
  490  REM write output file header block
  500  PROCwput(out%,1)
  510  PROCwput(out%,16)
  520  PROCwput(out%,len%+60)
  530
  540  REM write sprite header block
  550  PROCwput(out%,len%+60-16)
  560  l%=LEN(in$)
  570  FOR i%=1 TO l%
  580    i$=MID$(in$,i%,1)
  590    IF i$="." THEN a%=i%
  600  NEXT
  610  a%=a%+1
  620  b%=0
  630  FOR i%=a% TO l%
  640    j%=ASC(MID$(in$,i%,1)) OR &20
  650    b%=b%+1
  660    BPUT#out%,j%
  670  NEXT
  680  FOR i%=b%+1 TO 12
  690    BPUT#out%,0
  700  NEXT
  710  PTR#out%=28
  720  i%=ho% DIV p%
  730  j%=(32*((ho% MOD p%) +1) DIV p%) -1
  740  PROCwput(out%,i%)
  750  PROCwput(out%,v%-1)
  760  PROCwput(out%,0)
  770  PROCwput(out%,j%)
  780  PROCwput(out%,&2C)
  790  PROCwput(out%,&2C)
  800  PROCwput(out%,mode%)
  810
  820  REM end of sprite header block - sprite data follows
  830  REM ignore header block of icon length=D%
  840
  850  FOR i%=1 TO D%
  860    l%=BGET#in%
  870  NEXT
  880  FOR l%=1 TO v%
  890    FOR i%=0 TO h%
  900      PROChourglass(PTR#in%,EXT#in%)
  910      L%=BGET#in%
  920      A%=L% AND &F0
  930      B%=L% AND &0F
  940      CASE B% OF
  950        WHEN 0: J%=7
  960        WHEN 1: J%=11
  970        WHEN 2: J%=10
  980        WHEN 3: J%=3
  990        WHEN 4: J%=5
 1000        WHEN 5: J%=4
 1010        WHEN 6: J%=3
 1020        WHEN 7: J%=3
 1030        WHEN 8: J%=2
 1040        WHEN 9: J%=11
 1050        WHEN 10: J%=10
 1060        WHEN 11: J%=9
 1070        WHEN 12: J%=8
 1080        WHEN 13: J%=11
 1090        WHEN 14: J%=15
 1100        WHEN 15: J%=0
 1110      ENDCASE
 1120      B%=J%
 1130      C%=A% DIV 16
 1140      CASE C% OF
 1150        WHEN 0: J%=7
 1160        WHEN 1: J%=11
 1170        WHEN 2: J%=10
 1180        WHEN 3: J%=3
 1190        WHEN 4: J%=5
 1200        WHEN 5: J%=4
 1210        WHEN 6: J%=3
 1220        WHEN 7: J%=3
 1230        WHEN 8: J%=2
 1240        WHEN 9: J%=11
 1250        WHEN 10: J%=10
 1260        WHEN 11: J%=9
 1270        WHEN 12: J%=8
 1280        WHEN 13: J%=11
 1290        WHEN 14: J%=15
 1300        WHEN 15: J%=0
 1310      ENDCASE
 1320      C%=J%
 1330      D%=B% * 16
 1340      L%=(D%+C%)
 1350      j%=i%+(l%-1)*(h%+1)
 1360      screen%?j%=L%
 1370    NEXT
 1380  NEXT
 1390  FOR l%=1 TO v%
 1400    FOR i%=0 TO h%
 1410      j%=i%+(v%-l%)*(h%+1)
 1420      L%=screen%?j%
 1430      BPUT#out%,L%
 1440    NEXT
 1450  NEXT
 1460  CLOSE#in%
 1470  CLOSE#out%
 1480ENDIF
 1490=0
 1500
 1510
 1520

� >iconsprite
� A J Lindop, 28/12/93
� Change IBM icon to sprite
(�
2�
<:
F-� �iconsprite_name="IBM icons to Sprites"
P0� �iconsprite_args="-in * -out Sprite -send"
Z:
d� �iconsprite_init
n/� PROCwrite_in_icon(wind_hand%,3,STR$mode%)
x=0
�:
�3� �iconsprite_key(wh%,ic%,cx%,cy%,ch%,ci%,key%)
�=0
�:
�,� �iconsprite_mouse(mx%,my%,mb%,mh%,mi%)
�=0
�:
�� �iconsprite(in$,out$)
�d� in%,out%,len%,i%,l%,j%,mode%,h%,v%,load%,exec%,length%,attrib%,type%,i$,a%,b%,lb%,hm%,op%,hpi%
�� I%,J%,K%,L%,A%,B%,C%,D%
�� screen% &280
�� i%=0 � &280
�  screen%?i%=0
�
?ș "OS_File",5,in$ � type%,, load%, exec%, length%, attrib%
>� type% =0 � �warn(" Could not find the specified object")
"0� type% =2 � �warn(" Object is a Directory")
,� type% =1 �
6  mode%=27
@  D%=&7E
J  length%=16*32
T3  � ip%=input pixel/byte, op%=output pixel/byte
^(  h%=16:    � input bytes/input line
h  ip%=2:op%=2
rK  hpi%=ip%*h%            : � input horiz. pixels = output horiz. pixels
|:  lb%=h%*8               : � input bytes to be decoded
�3  v%=length%�h%        : � input vertical lines
�;  h%=h%-1                : � input horizontal bytes - 1
�1  len%=length%*ip%�op% : � output file length
�=  ho%=hpi%-1             : � output horizontal pixels - 1
�8  p%=4*op%               : � output (pixel/byte) * 4
�  in%=�(in$)
�  out%=�(out$)
�
  �#in%=0
�  �#out%=0
�
�&  � write output file header block
�  �wput(out%,1)
�  �wput(out%,16)
  �wput(out%,len%+60)

!  � write sprite header block
&  �wput(out%,len%+60-16)
0  l%=�(in$)
:  � i%=1 � l%
D    i$=�in$,i%,1)
N    � i$="." � a%=i%
X  �
b
  a%=a%+1
l
  b%=0
v  � i%=a% � l%
�    j%=�(�in$,i%,1)) � &20
�    b%=b%+1
�    �#out%,j%
�  �
�  � i%=b%+1 � 12
�    �#out%,0
�  �
�  �#out%=28
�  i%=ho% � p%
�%  j%=(32*((ho% � p%) +1) � p%) -1
�  �wput(out%,i%)
�  �wput(out%,v%-1)
�  �wput(out%,0)
  �wput(out%,j%)
  �wput(out%,&2C)
  �wput(out%,&2C)
   �wput(out%,mode%)
*
48  � end of sprite header block - sprite data follows
>-  � ignore header block of icon length=D%
H
R  � i%=1 � D%
\    l%=�#in%
f  �
p  � l%=1 � v%
z    � i%=0 � h%
�!      �hourglass(�#in%,�#in%)
�      L%=�#in%
�      A%=L% � &F0
�      B%=L% � &0F
�      Ȏ B% �
�        � 0: J%=7
�        � 1: J%=11
�        � 2: J%=10
�        � 3: J%=3
�        � 4: J%=5
�        � 5: J%=4
�        � 6: J%=3
�        � 7: J%=3
        � 8: J%=2
        � 9: J%=11
        � 10: J%=10
$        � 11: J%=9
.        � 12: J%=8
8        � 13: J%=11
B        � 14: J%=15
L        � 15: J%=0
V      �
`      B%=J%
j      C%=A% � 16
t      Ȏ C% �
~        � 0: J%=7
�        � 1: J%=11
�        � 2: J%=10
�        � 3: J%=3
�        � 4: J%=5
�        � 5: J%=4
�        � 6: J%=3
�        � 7: J%=3
�        � 8: J%=2
�        � 9: J%=11
�        � 10: J%=10
�        � 11: J%=9
�        � 12: J%=8
        � 13: J%=11

        � 14: J%=15
        � 15: J%=0
      �
(      C%=J%
2      D%=B% * 16
<      L%=(D%+C%)
F      j%=i%+(l%-1)*(h%+1)
P      screen%?j%=L%
Z	    �
d  �
n  � l%=1 � v%
x    � i%=0 � h%
�      j%=i%+(v%-l%)*(h%+1)
�      L%=screen%?j%
�      �#out%,L%
�	    �
�  �
�  �#in%
�  �#out%
��
�=0
�
�
�
�
00000000  0d 00 0a 11 f4 20 3e 69  63 6f 6e 73 70 72 69 74  |..... >iconsprit|
00000010  65 0d 00 14 1a f4 20 41  20 4a 20 4c 69 6e 64 6f  |e..... A J Lindo|
00000020  70 2c 20 32 38 2f 31 32  2f 39 33 0d 00 1e 1f f4  |p, 28/12/93.....|
00000030  20 43 68 61 6e 67 65 20  49 42 4d 20 69 63 6f 6e  | Change IBM icon|
00000040  20 74 6f 20 73 70 72 69  74 65 0d 00 28 05 f4 0d  | to sprite..(...|
00000050  00 32 05 e0 0d 00 3c 05  3a 0d 00 46 2d dd 20 a4  |.2....<.:..F-. .|
00000060  69 63 6f 6e 73 70 72 69  74 65 5f 6e 61 6d 65 3d  |iconsprite_name=|
00000070  22 49 42 4d 20 69 63 6f  6e 73 20 74 6f 20 53 70  |"IBM icons to Sp|
00000080  72 69 74 65 73 22 0d 00  50 30 dd 20 a4 69 63 6f  |rites"..P0. .ico|
00000090  6e 73 70 72 69 74 65 5f  61 72 67 73 3d 22 2d 69  |nsprite_args="-i|
000000a0  6e 20 2a 20 2d 6f 75 74  20 53 70 72 69 74 65 20  |n * -out Sprite |
000000b0  2d 73 65 6e 64 22 0d 00  5a 05 3a 0d 00 64 16 dd  |-send"..Z.:..d..|
000000c0  20 a4 69 63 6f 6e 73 70  72 69 74 65 5f 69 6e 69  | .iconsprite_ini|
000000d0  74 0d 00 6e 2f f4 20 50  52 4f 43 77 72 69 74 65  |t..n/. PROCwrite|
000000e0  5f 69 6e 5f 69 63 6f 6e  28 77 69 6e 64 5f 68 61  |_in_icon(wind_ha|
000000f0  6e 64 25 2c 33 2c 53 54  52 24 6d 6f 64 65 25 29  |nd%,3,STR$mode%)|
00000100  0d 00 78 06 3d 30 0d 00  82 05 3a 0d 00 8c 33 dd  |..x.=0....:...3.|
00000110  20 a4 69 63 6f 6e 73 70  72 69 74 65 5f 6b 65 79  | .iconsprite_key|
00000120  28 77 68 25 2c 69 63 25  2c 63 78 25 2c 63 79 25  |(wh%,ic%,cx%,cy%|
00000130  2c 63 68 25 2c 63 69 25  2c 6b 65 79 25 29 0d 00  |,ch%,ci%,key%)..|
00000140  96 06 3d 30 0d 00 a0 05  3a 0d 00 aa 2c dd 20 a4  |..=0....:...,. .|
00000150  69 63 6f 6e 73 70 72 69  74 65 5f 6d 6f 75 73 65  |iconsprite_mouse|
00000160  28 6d 78 25 2c 6d 79 25  2c 6d 62 25 2c 6d 68 25  |(mx%,my%,mb%,mh%|
00000170  2c 6d 69 25 29 0d 00 b4  06 3d 30 0d 00 be 05 3a  |,mi%)....=0....:|
00000180  0d 00 c8 1b dd 20 a4 69  63 6f 6e 73 70 72 69 74  |..... .iconsprit|
00000190  65 28 69 6e 24 2c 6f 75  74 24 29 0d 00 d2 64 ea  |e(in$,out$)...d.|
000001a0  20 69 6e 25 2c 6f 75 74  25 2c 6c 65 6e 25 2c 69  | in%,out%,len%,i|
000001b0  25 2c 6c 25 2c 6a 25 2c  6d 6f 64 65 25 2c 68 25  |%,l%,j%,mode%,h%|
000001c0  2c 76 25 2c 6c 6f 61 64  25 2c 65 78 65 63 25 2c  |,v%,load%,exec%,|
000001d0  6c 65 6e 67 74 68 25 2c  61 74 74 72 69 62 25 2c  |length%,attrib%,|
000001e0  74 79 70 65 25 2c 69 24  2c 61 25 2c 62 25 2c 6c  |type%,i$,a%,b%,l|
000001f0  62 25 2c 68 6d 25 2c 6f  70 25 2c 68 70 69 25 0d  |b%,hm%,op%,hpi%.|
00000200  00 dc 1d ea 20 49 25 2c  4a 25 2c 4b 25 2c 4c 25  |.... I%,J%,K%,L%|
00000210  2c 41 25 2c 42 25 2c 43  25 2c 44 25 0d 00 e6 12  |,A%,B%,C%,D%....|
00000220  de 20 73 63 72 65 65 6e  25 20 26 32 38 30 0d 00  |. screen% &280..|
00000230  f0 11 e3 20 69 25 3d 30  20 b8 20 26 32 38 30 0d  |... i%=0 . &280.|
00000240  00 fa 12 20 20 73 63 72  65 65 6e 25 3f 69 25 3d  |...  screen%?i%=|
00000250  30 0d 01 04 05 ed 0d 01  0e 3f c8 99 20 22 4f 53  |0........?.. "OS|
00000260  5f 46 69 6c 65 22 2c 35  2c 69 6e 24 20 b8 20 74  |_File",5,in$ . t|
00000270  79 70 65 25 2c 2c 20 6c  6f 61 64 25 2c 20 65 78  |ype%,, load%, ex|
00000280  65 63 25 2c 20 6c 65 6e  67 74 68 25 2c 20 61 74  |ec%, length%, at|
00000290  74 72 69 62 25 0d 01 18  3e e7 20 74 79 70 65 25  |trib%...>. type%|
000002a0  20 3d 30 20 8c 20 f2 77  61 72 6e 28 22 20 43 6f  | =0 . .warn(" Co|
000002b0  75 6c 64 20 6e 6f 74 20  66 69 6e 64 20 74 68 65  |uld not find the|
000002c0  20 73 70 65 63 69 66 69  65 64 20 6f 62 6a 65 63  | specified objec|
000002d0  74 22 29 0d 01 22 30 e7  20 74 79 70 65 25 20 3d  |t").."0. type% =|
000002e0  32 20 8c 20 f2 77 61 72  6e 28 22 20 4f 62 6a 65  |2 . .warn(" Obje|
000002f0  63 74 20 69 73 20 61 20  44 69 72 65 63 74 6f 72  |ct is a Director|
00000300  79 22 29 0d 01 2c 10 e7  20 74 79 70 65 25 20 3d  |y")..,.. type% =|
00000310  31 20 8c 0d 01 36 0e 20  20 6d 6f 64 65 25 3d 32  |1 ...6.  mode%=2|
00000320  37 0d 01 40 0c 20 20 44  25 3d 26 37 45 0d 01 4a  |7..@.  D%=&7E..J|
00000330  13 20 20 6c 65 6e 67 74  68 25 3d 31 36 2a 33 32  |.  length%=16*32|
00000340  0d 01 54 33 20 20 f4 20  69 70 25 3d 69 6e 70 75  |..T3  . ip%=inpu|
00000350  74 20 70 69 78 65 6c 2f  62 79 74 65 2c 20 6f 70  |t pixel/byte, op|
00000360  25 3d 6f 75 74 70 75 74  20 70 69 78 65 6c 2f 62  |%=output pixel/b|
00000370  79 74 65 0d 01 5e 28 20  20 68 25 3d 31 36 3a 20  |yte..^(  h%=16: |
00000380  20 20 20 f4 20 69 6e 70  75 74 20 62 79 74 65 73  |   . input bytes|
00000390  2f 69 6e 70 75 74 20 6c  69 6e 65 0d 01 68 11 20  |/input line..h. |
000003a0  20 69 70 25 3d 32 3a 6f  70 25 3d 32 0d 01 72 4b  | ip%=2:op%=2..rK|
000003b0  20 20 68 70 69 25 3d 69  70 25 2a 68 25 20 20 20  |  hpi%=ip%*h%   |
000003c0  20 20 20 20 20 20 20 20  20 3a 20 f4 20 69 6e 70  |         : . inp|
000003d0  75 74 20 68 6f 72 69 7a  2e 20 70 69 78 65 6c 73  |ut horiz. pixels|
000003e0  20 3d 20 6f 75 74 70 75  74 20 68 6f 72 69 7a 2e  | = output horiz.|
000003f0  20 70 69 78 65 6c 73 0d  01 7c 3a 20 20 6c 62 25  | pixels..|:  lb%|
00000400  3d 68 25 2a 38 20 20 20  20 20 20 20 20 20 20 20  |=h%*8           |
00000410  20 20 20 20 3a 20 f4 20  69 6e 70 75 74 20 62 79  |    : . input by|
00000420  74 65 73 20 74 6f 20 62  65 20 64 65 63 6f 64 65  |tes to be decode|
00000430  64 0d 01 86 33 20 20 76  25 3d 6c 65 6e 67 74 68  |d...3  v%=length|
00000440  25 81 68 25 20 20 20 20  20 20 20 20 3a 20 f4 20  |%.h%        : . |
00000450  69 6e 70 75 74 20 76 65  72 74 69 63 61 6c 20 6c  |input vertical l|
00000460  69 6e 65 73 0d 01 90 3b  20 20 68 25 3d 68 25 2d  |ines...;  h%=h%-|
00000470  31 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |1               |
00000480  20 3a 20 f4 20 69 6e 70  75 74 20 68 6f 72 69 7a  | : . input horiz|
00000490  6f 6e 74 61 6c 20 62 79  74 65 73 20 2d 20 31 0d  |ontal bytes - 1.|
000004a0  01 9a 31 20 20 6c 65 6e  25 3d 6c 65 6e 67 74 68  |..1  len%=length|
000004b0  25 2a 69 70 25 81 6f 70  25 20 3a 20 f4 20 6f 75  |%*ip%.op% : . ou|
000004c0  74 70 75 74 20 66 69 6c  65 20 6c 65 6e 67 74 68  |tput file length|
000004d0  0d 01 a4 3d 20 20 68 6f  25 3d 68 70 69 25 2d 31  |...=  ho%=hpi%-1|
000004e0  20 20 20 20 20 20 20 20  20 20 20 20 20 3a 20 f4  |             : .|
000004f0  20 6f 75 74 70 75 74 20  68 6f 72 69 7a 6f 6e 74  | output horizont|
00000500  61 6c 20 70 69 78 65 6c  73 20 2d 20 31 0d 01 ae  |al pixels - 1...|
00000510  38 20 20 70 25 3d 34 2a  6f 70 25 20 20 20 20 20  |8  p%=4*op%     |
00000520  20 20 20 20 20 20 20 20  20 20 3a 20 f4 20 6f 75  |          : . ou|
00000530  74 70 75 74 20 28 70 69  78 65 6c 2f 62 79 74 65  |tput (pixel/byte|
00000540  29 20 2a 20 34 0d 01 b8  10 20 20 69 6e 25 3d 8e  |) * 4....  in%=.|
00000550  28 69 6e 24 29 0d 01 c2  12 20 20 6f 75 74 25 3d  |(in$)....  out%=|
00000560  ae 28 6f 75 74 24 29 0d  01 cc 0d 20 20 cf 23 69  |.(out$)....  .#i|
00000570  6e 25 3d 30 0d 01 d6 0e  20 20 cf 23 6f 75 74 25  |n%=0....  .#out%|
00000580  3d 30 0d 01 e0 04 0d 01  ea 26 20 20 f4 20 77 72  |=0.......&  . wr|
00000590  69 74 65 20 6f 75 74 70  75 74 20 66 69 6c 65 20  |ite output file |
000005a0  68 65 61 64 65 72 20 62  6c 6f 63 6b 0d 01 f4 13  |header block....|
000005b0  20 20 f2 77 70 75 74 28  6f 75 74 25 2c 31 29 0d  |  .wput(out%,1).|
000005c0  01 fe 14 20 20 f2 77 70  75 74 28 6f 75 74 25 2c  |...  .wput(out%,|
000005d0  31 36 29 0d 02 08 19 20  20 f2 77 70 75 74 28 6f  |16)....  .wput(o|
000005e0  75 74 25 2c 6c 65 6e 25  2b 36 30 29 0d 02 12 04  |ut%,len%+60)....|
000005f0  0d 02 1c 21 20 20 f4 20  77 72 69 74 65 20 73 70  |...!  . write sp|
00000600  72 69 74 65 20 68 65 61  64 65 72 20 62 6c 6f 63  |rite header bloc|
00000610  6b 0d 02 26 1c 20 20 f2  77 70 75 74 28 6f 75 74  |k..&.  .wput(out|
00000620  25 2c 6c 65 6e 25 2b 36  30 2d 31 36 29 0d 02 30  |%,len%+60-16)..0|
00000630  0f 20 20 6c 25 3d a9 28  69 6e 24 29 0d 02 3a 11  |.  l%=.(in$)..:.|
00000640  20 20 e3 20 69 25 3d 31  20 b8 20 6c 25 0d 02 44  |  . i%=1 . l%..D|
00000650  15 20 20 20 20 69 24 3d  c1 69 6e 24 2c 69 25 2c  |.    i$=.in$,i%,|
00000660  31 29 0d 02 4e 18 20 20  20 20 e7 20 69 24 3d 22  |1)..N.    . i$="|
00000670  2e 22 20 8c 20 61 25 3d  69 25 0d 02 58 07 20 20  |." . a%=i%..X.  |
00000680  ed 0d 02 62 0d 20 20 61  25 3d 61 25 2b 31 0d 02  |...b.  a%=a%+1..|
00000690  6c 0a 20 20 62 25 3d 30  0d 02 76 12 20 20 e3 20  |l.  b%=0..v.  . |
000006a0  69 25 3d 61 25 20 b8 20  6c 25 0d 02 80 1e 20 20  |i%=a% . l%....  |
000006b0  20 20 6a 25 3d 97 28 c1  69 6e 24 2c 69 25 2c 31  |  j%=.(.in$,i%,1|
000006c0  29 29 20 84 20 26 32 30  0d 02 8a 0f 20 20 20 20  |)) . &20....    |
000006d0  62 25 3d 62 25 2b 31 0d  02 94 11 20 20 20 20 d5  |b%=b%+1....    .|
000006e0  23 6f 75 74 25 2c 6a 25  0d 02 9e 07 20 20 ed 0d  |#out%,j%....  ..|
000006f0  02 a8 14 20 20 e3 20 69  25 3d 62 25 2b 31 20 b8  |...  . i%=b%+1 .|
00000700  20 31 32 0d 02 b2 10 20  20 20 20 d5 23 6f 75 74  | 12....    .#out|
00000710  25 2c 30 0d 02 bc 07 20  20 ed 0d 02 c6 0f 20 20  |%,0....  .....  |
00000720  cf 23 6f 75 74 25 3d 32  38 0d 02 d0 11 20 20 69  |.#out%=28....  i|
00000730  25 3d 68 6f 25 20 81 20  70 25 0d 02 da 25 20 20  |%=ho% . p%...%  |
00000740  6a 25 3d 28 33 32 2a 28  28 68 6f 25 20 83 20 70  |j%=(32*((ho% . p|
00000750  25 29 20 2b 31 29 20 81  20 70 25 29 20 2d 31 0d  |%) +1) . p%) -1.|
00000760  02 e4 14 20 20 f2 77 70  75 74 28 6f 75 74 25 2c  |...  .wput(out%,|
00000770  69 25 29 0d 02 ee 16 20  20 f2 77 70 75 74 28 6f  |i%)....  .wput(o|
00000780  75 74 25 2c 76 25 2d 31  29 0d 02 f8 13 20 20 f2  |ut%,v%-1)....  .|
00000790  77 70 75 74 28 6f 75 74  25 2c 30 29 0d 03 02 14  |wput(out%,0)....|
000007a0  20 20 f2 77 70 75 74 28  6f 75 74 25 2c 6a 25 29  |  .wput(out%,j%)|
000007b0  0d 03 0c 15 20 20 f2 77  70 75 74 28 6f 75 74 25  |....  .wput(out%|
000007c0  2c 26 32 43 29 0d 03 16  15 20 20 f2 77 70 75 74  |,&2C)....  .wput|
000007d0  28 6f 75 74 25 2c 26 32  43 29 0d 03 20 17 20 20  |(out%,&2C).. .  |
000007e0  f2 77 70 75 74 28 6f 75  74 25 2c 6d 6f 64 65 25  |.wput(out%,mode%|
000007f0  29 0d 03 2a 04 0d 03 34  38 20 20 f4 20 65 6e 64  |)..*...48  . end|
00000800  20 6f 66 20 73 70 72 69  74 65 20 68 65 61 64 65  | of sprite heade|
00000810  72 20 62 6c 6f 63 6b 20  2d 20 73 70 72 69 74 65  |r block - sprite|
00000820  20 64 61 74 61 20 66 6f  6c 6c 6f 77 73 0d 03 3e  | data follows..>|
00000830  2d 20 20 f4 20 69 67 6e  6f 72 65 20 68 65 61 64  |-  . ignore head|
00000840  65 72 20 62 6c 6f 63 6b  20 6f 66 20 69 63 6f 6e  |er block of icon|
00000850  20 6c 65 6e 67 74 68 3d  44 25 0d 03 48 04 0d 03  | length=D%..H...|
00000860  52 11 20 20 e3 20 69 25  3d 31 20 b8 20 44 25 0d  |R.  . i%=1 . D%.|
00000870  03 5c 10 20 20 20 20 6c  25 3d 9a 23 69 6e 25 0d  |.\.    l%=.#in%.|
00000880  03 66 07 20 20 ed 0d 03  70 11 20 20 e3 20 6c 25  |.f.  ...p.  . l%|
00000890  3d 31 20 b8 20 76 25 0d  03 7a 13 20 20 20 20 e3  |=1 . v%..z.    .|
000008a0  20 69 25 3d 30 20 b8 20  68 25 0d 03 84 21 20 20  | i%=0 . h%...!  |
000008b0  20 20 20 20 f2 68 6f 75  72 67 6c 61 73 73 28 8f  |    .hourglass(.|
000008c0  23 69 6e 25 2c a2 23 69  6e 25 29 0d 03 8e 12 20  |#in%,.#in%).... |
000008d0  20 20 20 20 20 4c 25 3d  9a 23 69 6e 25 0d 03 98  |     L%=.#in%...|
000008e0  15 20 20 20 20 20 20 41  25 3d 4c 25 20 80 20 26  |.      A%=L% . &|
000008f0  46 30 0d 03 a2 15 20 20  20 20 20 20 42 25 3d 4c  |F0....      B%=L|
00000900  25 20 80 20 26 30 46 0d  03 ac 11 20 20 20 20 20  |% . &0F....     |
00000910  20 c8 8e 20 42 25 20 ca  0d 03 b6 15 20 20 20 20  | .. B% .....    |
00000920  20 20 20 20 c9 20 30 3a  20 4a 25 3d 37 0d 03 c0  |    . 0: J%=7...|
00000930  16 20 20 20 20 20 20 20  20 c9 20 31 3a 20 4a 25  |.        . 1: J%|
00000940  3d 31 31 0d 03 ca 16 20  20 20 20 20 20 20 20 c9  |=11....        .|
00000950  20 32 3a 20 4a 25 3d 31  30 0d 03 d4 15 20 20 20  | 2: J%=10....   |
00000960  20 20 20 20 20 c9 20 33  3a 20 4a 25 3d 33 0d 03  |     . 3: J%=3..|
00000970  de 15 20 20 20 20 20 20  20 20 c9 20 34 3a 20 4a  |..        . 4: J|
00000980  25 3d 35 0d 03 e8 15 20  20 20 20 20 20 20 20 c9  |%=5....        .|
00000990  20 35 3a 20 4a 25 3d 34  0d 03 f2 15 20 20 20 20  | 5: J%=4....    |
000009a0  20 20 20 20 c9 20 36 3a  20 4a 25 3d 33 0d 03 fc  |    . 6: J%=3...|
000009b0  15 20 20 20 20 20 20 20  20 c9 20 37 3a 20 4a 25  |.        . 7: J%|
000009c0  3d 33 0d 04 06 15 20 20  20 20 20 20 20 20 c9 20  |=3....        . |
000009d0  38 3a 20 4a 25 3d 32 0d  04 10 16 20 20 20 20 20  |8: J%=2....     |
000009e0  20 20 20 c9 20 39 3a 20  4a 25 3d 31 31 0d 04 1a  |   . 9: J%=11...|
000009f0  17 20 20 20 20 20 20 20  20 c9 20 31 30 3a 20 4a  |.        . 10: J|
00000a00  25 3d 31 30 0d 04 24 16  20 20 20 20 20 20 20 20  |%=10..$.        |
00000a10  c9 20 31 31 3a 20 4a 25  3d 39 0d 04 2e 16 20 20  |. 11: J%=9....  |
00000a20  20 20 20 20 20 20 c9 20  31 32 3a 20 4a 25 3d 38  |      . 12: J%=8|
00000a30  0d 04 38 17 20 20 20 20  20 20 20 20 c9 20 31 33  |..8.        . 13|
00000a40  3a 20 4a 25 3d 31 31 0d  04 42 17 20 20 20 20 20  |: J%=11..B.     |
00000a50  20 20 20 c9 20 31 34 3a  20 4a 25 3d 31 35 0d 04  |   . 14: J%=15..|
00000a60  4c 16 20 20 20 20 20 20  20 20 c9 20 31 35 3a 20  |L.        . 15: |
00000a70  4a 25 3d 30 0d 04 56 0b  20 20 20 20 20 20 cb 0d  |J%=0..V.      ..|
00000a80  04 60 0f 20 20 20 20 20  20 42 25 3d 4a 25 0d 04  |.`.      B%=J%..|
00000a90  6a 14 20 20 20 20 20 20  43 25 3d 41 25 20 81 20  |j.      C%=A% . |
00000aa0  31 36 0d 04 74 11 20 20  20 20 20 20 c8 8e 20 43  |16..t.      .. C|
00000ab0  25 20 ca 0d 04 7e 15 20  20 20 20 20 20 20 20 c9  |% ...~.        .|
00000ac0  20 30 3a 20 4a 25 3d 37  0d 04 88 16 20 20 20 20  | 0: J%=7....    |
00000ad0  20 20 20 20 c9 20 31 3a  20 4a 25 3d 31 31 0d 04  |    . 1: J%=11..|
00000ae0  92 16 20 20 20 20 20 20  20 20 c9 20 32 3a 20 4a  |..        . 2: J|
00000af0  25 3d 31 30 0d 04 9c 15  20 20 20 20 20 20 20 20  |%=10....        |
00000b00  c9 20 33 3a 20 4a 25 3d  33 0d 04 a6 15 20 20 20  |. 3: J%=3....   |
00000b10  20 20 20 20 20 c9 20 34  3a 20 4a 25 3d 35 0d 04  |     . 4: J%=5..|
00000b20  b0 15 20 20 20 20 20 20  20 20 c9 20 35 3a 20 4a  |..        . 5: J|
00000b30  25 3d 34 0d 04 ba 15 20  20 20 20 20 20 20 20 c9  |%=4....        .|
00000b40  20 36 3a 20 4a 25 3d 33  0d 04 c4 15 20 20 20 20  | 6: J%=3....    |
00000b50  20 20 20 20 c9 20 37 3a  20 4a 25 3d 33 0d 04 ce  |    . 7: J%=3...|
00000b60  15 20 20 20 20 20 20 20  20 c9 20 38 3a 20 4a 25  |.        . 8: J%|
00000b70  3d 32 0d 04 d8 16 20 20  20 20 20 20 20 20 c9 20  |=2....        . |
00000b80  39 3a 20 4a 25 3d 31 31  0d 04 e2 17 20 20 20 20  |9: J%=11....    |
00000b90  20 20 20 20 c9 20 31 30  3a 20 4a 25 3d 31 30 0d  |    . 10: J%=10.|
00000ba0  04 ec 16 20 20 20 20 20  20 20 20 c9 20 31 31 3a  |...        . 11:|
00000bb0  20 4a 25 3d 39 0d 04 f6  16 20 20 20 20 20 20 20  | J%=9....       |
00000bc0  20 c9 20 31 32 3a 20 4a  25 3d 38 0d 05 00 17 20  | . 12: J%=8.... |
00000bd0  20 20 20 20 20 20 20 c9  20 31 33 3a 20 4a 25 3d  |       . 13: J%=|
00000be0  31 31 0d 05 0a 17 20 20  20 20 20 20 20 20 c9 20  |11....        . |
00000bf0  31 34 3a 20 4a 25 3d 31  35 0d 05 14 16 20 20 20  |14: J%=15....   |
00000c00  20 20 20 20 20 c9 20 31  35 3a 20 4a 25 3d 30 0d  |     . 15: J%=0.|
00000c10  05 1e 0b 20 20 20 20 20  20 cb 0d 05 28 0f 20 20  |...      ...(.  |
00000c20  20 20 20 20 43 25 3d 4a  25 0d 05 32 14 20 20 20  |    C%=J%..2.   |
00000c30  20 20 20 44 25 3d 42 25  20 2a 20 31 36 0d 05 3c  |   D%=B% * 16..<|
00000c40  14 20 20 20 20 20 20 4c  25 3d 28 44 25 2b 43 25  |.      L%=(D%+C%|
00000c50  29 0d 05 46 1d 20 20 20  20 20 20 6a 25 3d 69 25  |)..F.      j%=i%|
00000c60  2b 28 6c 25 2d 31 29 2a  28 68 25 2b 31 29 0d 05  |+(l%-1)*(h%+1)..|
00000c70  50 17 20 20 20 20 20 20  73 63 72 65 65 6e 25 3f  |P.      screen%?|
00000c80  6a 25 3d 4c 25 0d 05 5a  09 20 20 20 20 ed 0d 05  |j%=L%..Z.    ...|
00000c90  64 07 20 20 ed 0d 05 6e  11 20 20 e3 20 6c 25 3d  |d.  ...n.  . l%=|
00000ca0  31 20 b8 20 76 25 0d 05  78 13 20 20 20 20 e3 20  |1 . v%..x.    . |
00000cb0  69 25 3d 30 20 b8 20 68  25 0d 05 82 1e 20 20 20  |i%=0 . h%....   |
00000cc0  20 20 20 6a 25 3d 69 25  2b 28 76 25 2d 6c 25 29  |   j%=i%+(v%-l%)|
00000cd0  2a 28 68 25 2b 31 29 0d  05 8c 17 20 20 20 20 20  |*(h%+1)....     |
00000ce0  20 4c 25 3d 73 63 72 65  65 6e 25 3f 6a 25 0d 05  | L%=screen%?j%..|
00000cf0  96 13 20 20 20 20 20 20  d5 23 6f 75 74 25 2c 4c  |..      .#out%,L|
00000d00  25 0d 05 a0 09 20 20 20  20 ed 0d 05 aa 07 20 20  |%....    .....  |
00000d10  ed 0d 05 b4 0b 20 20 d9  23 69 6e 25 0d 05 be 0c  |.....  .#in%....|
00000d20  20 20 d9 23 6f 75 74 25  0d 05 c8 05 cd 0d 05 d2  |  .#out%........|
00000d30  06 3d 30 0d 05 dc 04 0d  05 e6 04 0d 05 f0 04 0d  |.=0.............|
00000d40  ff                                                |.|
00000d41