'=========================================================================== ' Subject: NEW ANIMATED PLASMA EFFECT Date: 08-09-98 (03:32) ' Author: Daniel Davies Code: QB, QBasic, PDS ' Origin: ia53@rapid.co.uk Packet: GRAPHICS.ABC '=========================================================================== 'New Plasma Effect 'Daniel Davies 'E-Mail :- ia53@rapid.co.uk 'web :- www.users.rapid.net.uk/ia53/ DIM dist%(8900) DIM sintab1%(360) DIM sintab2%(360) q% = INT(RND * 25) + 1 s1a% = (RND * 20) + 55 s1b% = (RND * 10) + 20 s2a% = (RND * 20) + 55 s2b% = (RND * 8) + 11 FOR z% = 0 TO 360 x% = z% + q% sintab1%(z%) = 5 * (((35 * SIN(x% / s1a%)) + (15 * SIN(x% / s1b%)))) sintab2%(z%) = 10 * (((27 * SIN(x% / s2a%)) + (6 * SIN(x% / s2b%)))) NEXT z% FOR x% = 0 TO 8900 dist%(x%) = SQR(x%) * 2.5 NEXT x% SCREEN 13 FOR x% = 0 TO 255 READ r%, g%, b% OUT &H3C8, x% OUT &H3C9, g% OUT &H3C9, b% OUT &H3C9, r% NEXT x% DEF SEG = &HA000 DO ymod& = 0 WAIT &H3DA, 8 FOR y% = -50 TO 50 ym& = y% * y% FOR x% = -80 TO 79 xm& = x% * x% yd% = dist%(xm& + ym&) x2% = x% + m% x2% = x2% MOD 360 c% = ((sintab2%(yd%) + (((sintab1%(ABS(x2%)) + yd%) MOD 254) + 1)) MOD 254) + 1 add% = ((x% + 80) * 2) a& = ymod& + add% POKE a&, c% POKE a& + 1, c% POKE a& + 320, c% POKE a& + 321, c% NEXT x% ymod& = ymod& + 640 NEXT y% m% = m% + 1 LOOP WHILE INKEY$ = "" PALETTE SCREEN 0 WIDTH 80 PRINT "Plasma" PRINT "by Daniel Davies" PRINT "E-Mail :- ia53@rapid.co.uk" PRINT "web :- www.users.rapid.net.uk/ia53/" DATA 15,15,15,16,15,15,18,15,15,19,14,14,21,14,14,22,13,13,24,13,13,25,12,12,27,12,12 DATA 28,11,11,30,11,11,32,10,10,33,10,10,35,9,9,36,9,9,38,8,8,39,8,8,41,7,7,42,7,7 DATA 44,6,6,45,6,6,47,5,5,49,5,5,50,4,4,52,4,4,53,3,3,55,3,3,56,2,2,58,2,2,59,1,1,61,1,1 DATA 63,0,0,63,1,0,63,3,0,63,5,0,63,7,0,63,9,0,63,11,0,63,13,0,63,15,0,63,17,0,63,19,0 DATA 63,21,0,63,23,0,63,25,0,63,27,0,63,29,0,63,31,0,63,33,0,63,35,0,63,37,0,63,39,0 DATA 63,41,0,63,43,0,63,45,0,63,47,0,63,49,0,63,51,0,63,53,0,63,55,0,63,57,0,63,59,0 DATA 63,61,0,63,63,0,63,63,1,63,63,3,63,63,5,63,63,7,63,63,9,63,63,11,63,63,13,63,63,15 DATA 63,63,17,63,63,19,63,63,21,63,63,23,63,63,25,63,63,27,63,63,29,63,63,31,63,63,33 DATA 63,63,35,63,63,37,63,63,39,63,63,41,63,63,43,63,63,45,63,63,47,63,63,49,63,63,51 DATA 63,63,53,63,63,55,63,63,57,63,63,59,63,63,61,63,63,63,63,63,63,63,62,62,63,62,61 DATA 63,61,60,63,61,59,63,60,58,63,60,57,63,59,56,63,59,55,63,58,54,63,58,53,63,57,52 DATA 63,57,51,63,56,50,63,56,49,63,55,48,63,55,47,63,54,46,63,54,45,63,53,44,63,53,43 DATA 63,52,42,63,52,41,63,51,40,63,51,39,63,50,38,63,50,37,63,49,36,63,49,35,63,48,34 DATA 63,48,33,63,47,32,63,46,31,63,46,30,63,45,29,63,45,28,63,44,27,63,44,26,63,43,25 DATA 63,43,24,63,42,23,63,42,22,63,41,21,63,41,20,63,40,19,63,40,18,63,39,17,63,39,16 DATA 63,38,15,63,38,14,63,37,13,63,37,12,63,36,11,63,36,10,63,35,9,63,35,8,63,34,7 DATA 63,34,6,63,33,5,63,33,4,63,32,3,63,32,2,63,31,1,63,30,0,63,30,0,63,29,0,63,28,0 DATA 63,27,0,63,26,0,63,25,0,63,24,0,63,23,0,63,22,0,63,21,0,63,20,0,63,19,0,63,18,0 DATA 63,17,0,63,16,0,63,15,0,63,15,0,63,14,0,63,13,0,63,12,0,63,11,0,63,10,0,63,9,0 DATA 63,8,0,63,7,0,63,6,0,63,5,0,63,4,0,63,3,0,63,2,0,63,1,0,63,0,0,63,0,0,62,0,0 DATA 61,0,0,61,0,0,60,0,0,59,0,0,58,0,0,58,0,0,57,0,0,56,0,0,56,0,0,55,0,0,54,0,0 DATA 53,0,0,53,0,0,52,0,0,51,0,0,51,0,0,50,0,0,49,0,0,48,0,0,48,0,0,47,0,0,46,0,0 DATA 46,0,0,45,0,0,44,0,0,43,0,0,43,0,0,42,0,0,41,0,0,40,0,0,40,0,0,39,1,1,38,1,1 DATA 37,2,2,36,2,2,35,3,3,35,3,3,34,4,4,33,4,4,32,5,5,31,5,5,30,6,6,30,6,6,29,7,7 DATA 28,7,7,27,8,8,26,8,8,25,9,9,25,9,9,24,10,10,23,10,10,22,11,11,21,11,11,20,12,12 DATA 20,12,12,19,13,13,18,13,13,17,14,14,16,14,14,15,15,15,15,15,15,15,15,15