Home » Recent acquisitions » Acorn ADFS disks » adfs_AcornUser_199611.adf » Regulars » StarInfo/Challenge/Shells

StarInfo/Challenge/Shells

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/Challenge/Shells
Read OK:
File size: 04BB bytes
Load address: 0000
Exec address: 0000
File contents
   10REM >Shells
   11REM by dL
   12REM (c) Acorn User November 1996
   13:
   20ON ERROR IF INKEY-2 END ELSE RUN
   30
   70cols=16 : REM 16, 256 or 32768
   80type=1  : REM 1 or -1
   90
  100CASE cols OF
  110 WHEN 16:
  120  MODE 27
  130  FOR c=0 TO 15
  140   COLOUR c,c*15,c*15,c*17
  150  NEXT
  160 WHEN 256:
  170  MODE 28
  180  SYS "OS_SWINumberFromString",,"ColourTrans_SetGCOL" TO gcol
  190 WHEN 32768:
  200  DIM mode 64
  210  !mode=1
  220  mode!4=640
  230  mode!8=480
  240  mode!12=4
  250  mode!16=-1
  260  mode!20=-1
  270  MODE mode
  280ENDCASE
  290OFF
  300
  310REPEAT
  320 IF INKEY$0 = " " type=-type
  330 REPEAT
  340  x=RND(1280)
  350  y=RND(960)
  360  n=RND(15)+5
  370  r=RND(80)+48
  380  n=7+RND(13)
  390
  400  m=r*SINRAD(180/n)
  410  o=RND(1)*360
  420  p=4*(0.5-RND(1))
  430
  440 UNTIL FNsize(r)
  450
  460 IF cols>16 THEN
  470  R=255-RND(128)
  480  G=255-RND(128)
  490  B=255-RND(128)
  500 ENDIF
  510
  520 IF type>0 FOR j=0 TO r-1 ELSE FOR j=r-1 TO 0 STEP -1
  530  d=m*j/r
  540  c=(r-1-j)/r
  550  CASE cols OF
  560   WHEN 16:
  570    GCOL 0,15*c
  580   WHEN 256:
  590    SYS gcol,((R*c)<<8) OR ((G*c)<<16) OR ((B*c)<<24),,,&100
  600   WHEN 32768:
  610    GCOL R*c,G*c,B*c
  620  ENDCASE
  630  FOR i=0 TO n-1
  640   a=o+j*p+360*i/n
  650   CIRCLE FILL x+SINRAD(a)*j,y+COSRAD(a)*j,d
  660  NEXT
  670 NEXT
  680
  690UNTIL 0
  700
  710DEF FNsize(s)
  720FOR j=0 TO s-1
  730 d=m*j/s
  740 FOR i=0 TO n-1
  750  a=o+j*p+360*i/n
  760  IF POINT(x+SINRAD(a)*(j+d+4),y+COSRAD(a)*(j+d+4)) >0 THEN =FALSE
  770 NEXT
  780NEXT
  790=TRUE


� >Shells
� by dL
"� (c) Acorn User November 1996

:
� � � �-2 � � �

F cols=16 : � 16, 256 or 32768
Ptype=1  : � 1 or -1
Z
d
Ȏ cols �
n
 � 16:
x
  � 27
�  � c=0 � 15
�   � c,c*15,c*15,c*17
�  �
� � 256:
�
  � 28
�?  ș "OS_SWINumberFromString",,"ColourTrans_SetGCOL" � gcol
�
 � 32768:
�  � mode 64
�
  !mode=1
�  mode!4=640
�  mode!8=480
�  mode!12=4
�  mode!16=-1
  mode!20=-1
  � mode
�
"�
,
6�
@ � �0 = " " type=-type
J �
T  x=�(1280)
^  y=�(960)
h  n=�(15)+5
r  r=�(80)+48
|  n=7+�(13)
�
�  m=r*��(180/n)
�  o=�(1)*360
�  p=4*(0.5-�(1))
�
� � �size(r)
�
� � cols>16 �
�  R=255-�(128)
�  G=255-�(128)
�  B=255-�(128)
� �
�
, � type>0 � j=0 � r-1 � � j=r-1 � 0 � -1

  d=m*j/r
  c=(r-1-j)/r
&  Ȏ cols �
0   � 16:
:    � 0,15*c
D
   � 256:
N=    ș gcol,((R*c)<<8) � ((G*c)<<16) � ((B*c)<<24),,,&100
X   � 32768:
b    � R*c,G*c,B*c
l  �
v  � i=0 � n-1
�   a=o+j*p+360*i/n
�"   ȏ Ȑ x+��(a)*j,y+��(a)*j,d
�  �
� �
�
�� 0
�
�� �size(s)
�� j=0 � s-1
� d=m*j/s
� � i=0 � n-1
�  a=o+j*p+360*i/n
�1  � �x+��(a)*(j+d+4),y+��(a)*(j+d+4)) >0 � =�
 �
�
=�
�
00000000  0d 00 0a 0d f4 20 3e 53  68 65 6c 6c 73 0d 00 0b  |..... >Shells...|
00000010  0b f4 20 62 79 20 64 4c  0d 00 0c 22 f4 20 28 63  |.. by dL...". (c|
00000020  29 20 41 63 6f 72 6e 20  55 73 65 72 20 4e 6f 76  |) Acorn User Nov|
00000030  65 6d 62 65 72 20 31 39  39 36 0d 00 0d 05 3a 0d  |ember 1996....:.|
00000040  00 14 13 ee 20 85 20 e7  20 a6 2d 32 20 e0 20 8b  |.... . . .-2 . .|
00000050  20 f9 0d 00 1e 04 0d 00  46 20 63 6f 6c 73 3d 31  | .......F cols=1|
00000060  36 20 3a 20 f4 20 31 36  2c 20 32 35 36 20 6f 72  |6 : . 16, 256 or|
00000070  20 33 32 37 36 38 0d 00  50 17 74 79 70 65 3d 31  | 32768..P.type=1|
00000080  20 20 3a 20 f4 20 31 20  6f 72 20 2d 31 0d 00 5a  |  : . 1 or -1..Z|
00000090  04 0d 00 64 0d c8 8e 20  63 6f 6c 73 20 ca 0d 00  |...d... cols ...|
000000a0  6e 0a 20 c9 20 31 36 3a  0d 00 78 0a 20 20 eb 20  |n. . 16:..x.  . |
000000b0  32 37 0d 00 82 10 20 20  e3 20 63 3d 30 20 b8 20  |27....  . c=0 . |
000000c0  31 35 0d 00 8c 19 20 20  20 fb 20 63 2c 63 2a 31  |15....   . c,c*1|
000000d0  35 2c 63 2a 31 35 2c 63  2a 31 37 0d 00 96 07 20  |5,c*15,c*17.... |
000000e0  20 ed 0d 00 a0 0b 20 c9  20 32 35 36 3a 0d 00 aa  | ..... . 256:...|
000000f0  0a 20 20 eb 20 32 38 0d  00 b4 3f 20 20 c8 99 20  |.  . 28...?  .. |
00000100  22 4f 53 5f 53 57 49 4e  75 6d 62 65 72 46 72 6f  |"OS_SWINumberFro|
00000110  6d 53 74 72 69 6e 67 22  2c 2c 22 43 6f 6c 6f 75  |mString",,"Colou|
00000120  72 54 72 61 6e 73 5f 53  65 74 47 43 4f 4c 22 20  |rTrans_SetGCOL" |
00000130  b8 20 67 63 6f 6c 0d 00  be 0d 20 c9 20 33 32 37  |. gcol.... . 327|
00000140  36 38 3a 0d 00 c8 0f 20  20 de 20 6d 6f 64 65 20  |68:....  . mode |
00000150  36 34 0d 00 d2 0d 20 20  21 6d 6f 64 65 3d 31 0d  |64....  !mode=1.|
00000160  00 dc 10 20 20 6d 6f 64  65 21 34 3d 36 34 30 0d  |...  mode!4=640.|
00000170  00 e6 10 20 20 6d 6f 64  65 21 38 3d 34 38 30 0d  |...  mode!8=480.|
00000180  00 f0 0f 20 20 6d 6f 64  65 21 31 32 3d 34 0d 00  |...  mode!12=4..|
00000190  fa 10 20 20 6d 6f 64 65  21 31 36 3d 2d 31 0d 01  |..  mode!16=-1..|
000001a0  04 10 20 20 6d 6f 64 65  21 32 30 3d 2d 31 0d 01  |..  mode!20=-1..|
000001b0  0e 0c 20 20 eb 20 6d 6f  64 65 0d 01 18 05 cb 0d  |..  . mode......|
000001c0  01 22 05 87 0d 01 2c 04  0d 01 36 05 f5 0d 01 40  |."....,...6....@|
000001d0  1a 20 e7 20 bf 30 20 3d  20 22 20 22 20 74 79 70  |. . .0 = " " typ|
000001e0  65 3d 2d 74 79 70 65 0d  01 4a 06 20 f5 0d 01 54  |e=-type..J. ...T|
000001f0  0f 20 20 78 3d b3 28 31  32 38 30 29 0d 01 5e 0e  |.  x=.(1280)..^.|
00000200  20 20 79 3d b3 28 39 36  30 29 0d 01 68 0f 20 20  |  y=.(960)..h.  |
00000210  6e 3d b3 28 31 35 29 2b  35 0d 01 72 10 20 20 72  |n=.(15)+5..r.  r|
00000220  3d b3 28 38 30 29 2b 34  38 0d 01 7c 0f 20 20 6e  |=.(80)+48..|.  n|
00000230  3d 37 2b b3 28 31 33 29  0d 01 86 04 0d 01 90 13  |=7+.(13)........|
00000240  20 20 6d 3d 72 2a b5 b2  28 31 38 30 2f 6e 29 0d  |  m=r*..(180/n).|
00000250  01 9a 10 20 20 6f 3d b3  28 31 29 2a 33 36 30 0d  |...  o=.(1)*360.|
00000260  01 a4 14 20 20 70 3d 34  2a 28 30 2e 35 2d b3 28  |...  p=4*(0.5-.(|
00000270  31 29 29 0d 01 ae 04 0d  01 b8 0f 20 fd 20 a4 73  |1))........ . .s|
00000280  69 7a 65 28 72 29 0d 01  c2 04 0d 01 cc 10 20 e7  |ize(r)........ .|
00000290  20 63 6f 6c 73 3e 31 36  20 8c 0d 01 d6 12 20 20  | cols>16 .....  |
000002a0  52 3d 32 35 35 2d b3 28  31 32 38 29 0d 01 e0 12  |R=255-.(128)....|
000002b0  20 20 47 3d 32 35 35 2d  b3 28 31 32 38 29 0d 01  |  G=255-.(128)..|
000002c0  ea 12 20 20 42 3d 32 35  35 2d b3 28 31 32 38 29  |..  B=255-.(128)|
000002d0  0d 01 f4 06 20 cd 0d 01  fe 04 0d 02 08 2c 20 e7  |.... ........, .|
000002e0  20 74 79 70 65 3e 30 20  e3 20 6a 3d 30 20 b8 20  | type>0 . j=0 . |
000002f0  72 2d 31 20 8b 20 e3 20  6a 3d 72 2d 31 20 b8 20  |r-1 . . j=r-1 . |
00000300  30 20 88 20 2d 31 0d 02  12 0d 20 20 64 3d 6d 2a  |0 . -1....  d=m*|
00000310  6a 2f 72 0d 02 1c 11 20  20 63 3d 28 72 2d 31 2d  |j/r....  c=(r-1-|
00000320  6a 29 2f 72 0d 02 26 0f  20 20 c8 8e 20 63 6f 6c  |j)/r..&.  .. col|
00000330  73 20 ca 0d 02 30 0c 20  20 20 c9 20 31 36 3a 0d  |s ...0.   . 16:.|
00000340  02 3a 10 20 20 20 20 e6  20 30 2c 31 35 2a 63 0d  |.:.    . 0,15*c.|
00000350  02 44 0d 20 20 20 c9 20  32 35 36 3a 0d 02 4e 3d  |.D.   . 256:..N=|
00000360  20 20 20 20 c8 99 20 67  63 6f 6c 2c 28 28 52 2a  |    .. gcol,((R*|
00000370  63 29 3c 3c 38 29 20 84  20 28 28 47 2a 63 29 3c  |c)<<8) . ((G*c)<|
00000380  3c 31 36 29 20 84 20 28  28 42 2a 63 29 3c 3c 32  |<16) . ((B*c)<<2|
00000390  34 29 2c 2c 2c 26 31 30  30 0d 02 58 0f 20 20 20  |4),,,&100..X.   |
000003a0  c9 20 33 32 37 36 38 3a  0d 02 62 15 20 20 20 20  |. 32768:..b.    |
000003b0  e6 20 52 2a 63 2c 47 2a  63 2c 42 2a 63 0d 02 6c  |. R*c,G*c,B*c..l|
000003c0  07 20 20 cb 0d 02 76 11  20 20 e3 20 69 3d 30 20  |.  ...v.  . i=0 |
000003d0  b8 20 6e 2d 31 0d 02 80  16 20 20 20 61 3d 6f 2b  |. n-1....   a=o+|
000003e0  6a 2a 70 2b 33 36 30 2a  69 2f 6e 0d 02 8a 22 20  |j*p+360*i/n..." |
000003f0  20 20 c8 8f 20 c8 90 20  78 2b b5 b2 28 61 29 2a  |  .. .. x+..(a)*|
00000400  6a 2c 79 2b 9b b2 28 61  29 2a 6a 2c 64 0d 02 94  |j,y+..(a)*j,d...|
00000410  07 20 20 ed 0d 02 9e 06  20 ed 0d 02 a8 04 0d 02  |.  ..... .......|
00000420  b2 07 fd 20 30 0d 02 bc  04 0d 02 c6 0e dd 20 a4  |... 0......... .|
00000430  73 69 7a 65 28 73 29 0d  02 d0 0f e3 20 6a 3d 30  |size(s)..... j=0|
00000440  20 b8 20 73 2d 31 0d 02  da 0c 20 64 3d 6d 2a 6a  | . s-1.... d=m*j|
00000450  2f 73 0d 02 e4 10 20 e3  20 69 3d 30 20 b8 20 6e  |/s.... . i=0 . n|
00000460  2d 31 0d 02 ee 15 20 20  61 3d 6f 2b 6a 2a 70 2b  |-1....  a=o+j*p+|
00000470  33 36 30 2a 69 2f 6e 0d  02 f8 31 20 20 e7 20 b0  |360*i/n...1  . .|
00000480  78 2b b5 b2 28 61 29 2a  28 6a 2b 64 2b 34 29 2c  |x+..(a)*(j+d+4),|
00000490  79 2b 9b b2 28 61 29 2a  28 6a 2b 64 2b 34 29 29  |y+..(a)*(j+d+4))|
000004a0  20 3e 30 20 8c 20 3d a3  0d 03 02 06 20 ed 0d 03  | >0 . =..... ...|
000004b0  0c 05 ed 0d 03 16 06 3d  b9 0d ff                 |.......=...|
000004bb