home *** CD-ROM | disk | FTP | other *** search
AMOS Source Code | 1996-08-13 | 724 b | 23 lines |
- 'This example shows how you can create patterns with stars. Experiment!
- '
- 'This starfield is drawn 50 times/second, even if using a MC68000!
- '
- Screen Open 0,320,200,2,Lowres : Curs Off : Palette 0,$FFF
- Double Buffer : Autoback 0 : Hide
- '
- Extension_17_001C 200,False : Rem Reserve 200 single coloured stars!
- '
- 'Scatter initial positions of each star around centre of the screen!
- '
- For I=1 To 200
- Repeat
- Extension_17_003C I,152+Rnd(10),92+Rnd(10),-3+Rnd(6),-3+Rnd(6)
- Until Extension_17_0174(I)<>0 and Extension_17_0188(I)<>0
- Next I
- '
- 'A simple loop to clear, draw and update the stars!
- '
- Repeat
- Extension_17_01D8 : Extension_17_01EA : Extension_17_0248
- Screen Swap : Wait Vbl
- Until Mouse Key