home *** CD-ROM | disk | FTP | other *** search
/ Club Amiga de Montreal - CAM / CAM_CD_1.iso / files / 058.lha / CrissCross (.txt) < prev    next >
Encoding:
AmigaBASIC Source Code  |  1986-11-20  |  2.0 KB  |  62 lines

  1. ' *******************************
  2. ' *         CRISSCROSS          *
  3. ' *                             *
  4. ' *   Ted L. Lashley - APL706   *
  5. ' *     6401 Main Street #4     *
  6. ' *     Zachary, LA   70791     *
  7. ' *******************************
  8. SCREEN 2,640,200,3,2
  9. WINDOW 2,,(0,0)-(631,186),2,2
  10. GOSUB getpalettes
  11. RANDOMIZE TIMER
  12. GOSUB intro
  13. start:  
  14.  x=(RND*240)
  15.  c=0
  16.  FOR a=1 TO ((308-x)*x) STEP x
  17.   b=INT(93*(COS(a)))+93
  18.    d=INT(93*(COS(a+1)))+93
  19.     c=c+1
  20.     kolor=(INT(2*(c+x)) MOD 7)+1
  21.    LINE (2*c,b)-(2*(c+x),d),kolor
  22.   q$=INKEY$:IF q$=CHR$(27) THEN CLS:SYSTEM:END::ELSE IF q$<>"" THEN CLS: GOTO start
  23.  NEXT a
  24. FOR q=1 TO 3000: NEXT
  25. a$=INKEY$:IF a$<>"" THEN loop :ELSE CLS: GOTO start
  26. loop: 
  27.  a$=INKEY$:IF a$="" THEN loop :ELSE CLS: GOTO start
  28. intro:
  29.  LOCATE 2,29:COLOR 2,0:PRINT "C R I S S C R O S S"
  30.  LOCATE 3,29:COLOR 3,0:PRINT "==================="
  31.  LOCATE 7,1:COLOR 1,0
  32.  PRINT "         This colorful graphics program is self-running.  After each"
  33.  PRINT "         screen is completed, the program will pause for a few seconds,"
  34.  PRINT "         the screen will clear, and the next screen will be drawn."
  35.  PRINT:PRINT
  36.  COLOR 4,0
  37.  PRINT "         During the pause between screens, hitting any key will stop"
  38.  PRINT "         the program; hitting any key will then let the program resume."
  39.  PRINT:PRINT
  40.  COLOR 7,0
  41.  PRINT "         You may clear the screen while the graphics are being drawn"
  42.  PRINT "         by hitting any key.  Press <ESC> to end the program."
  43.  PRINT:PRINT
  44.  COLOR 6,0
  45.  PRINT "         Watch it awhile - some of the designs are surprising!"
  46.  PRINT
  47.  COLOR 5,0
  48.  PRINT "         Press <RETURN> to begin."
  49. loop2:
  50.  w$=INKEY$:IF w$="" THEN loop2 :ELSE CLS:RETURN
  51. getpalettes:
  52.  PALETTE 0,0,0,0         ' black
  53.  PALETTE 1,0.9,0.9,0.9      ' white
  54.  PALETTE 2,0.94,0.03,0.6    ' pink
  55.  PALETTE 3,0.91,0.3,0.15    ' orange
  56.  PALETTE 4,0.8,0.8,0       ' yellow
  57.  PALETTE 5,0.09,0.6,0.06    ' green
  58.  PALETTE 6,0.1,0.2,0.8      ' blue
  59.  PALETTE 7,0.74,0.29,0.89   ' violet
  60. RETURN
  61.  
  62.