Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
green bubbles of plazma acid stuff!!!
#1
i made this green plasma junk, i found the algo and adjusted it a bit to make it look "cooler"

Code:
SCREEN 18,32,2

dim screen_width as single
dim screen_height as single
dim plasma_speed as single  
dim scrn_xpos as integer     'x position of plasma area
dim scrn_ypos as integer     'y position of plasma area
dim plaz_color as integer    'effects the color of the plasma (and maybe more)
dim plaz_sequance as integer 'sequances the plasma to give it bubbling effect

screen_width = 640           'width of plasma area
screen_height = 300          'height of plasma area

plas_Xsize = 180             'width of single plasma bubble
plas_Ysize = 100             'height of single plasma bubble


plasma_speed = 2             'speed of plasma bubble sequance


while inkey$ = ""            'start loop here, and end loop if there's keypress
    
plaz_sequance = plaz_sequance + plasma_speed          'sequance the plasma at a set speed

FOR scrn_xpos = 0 TO screen_width
    
    FOR scrn_ypos = 200 TO screen_height
        
        plaz_color = ABS(COS((scrn_xpos + plaz_sequance) * 4 / plas_Xsize) + sin((scrn_ypos + plaz_sequance) * 4 / plas_Ysize) + cos((scrn_xpos + scrn_ypos) * 1 / 23)) * 5 / 1 + 16
        
        PSET (scrn_xpos , scrn_ypos), RGB(0, plaz_color * 800 / 50, 0)      'draw pixels!!!!!! (xpos,ypos), color    
        
scrn_ypos = scrn_ypos + 1                            'makes it skip everyother line, adds speed!!!

    NEXT scrn_ypos
    
NEXT scrn_xpos

wend

tell me what you think
url=http://www.random-seed.net][Image: asylumsig.png][/url]
Reply
#2
Wow, very nice! I need to learn how to make plasmas sometime. Smile
Reply
#3
cool =)

check this:

Code:
Screen 18,32,2

Dim As Integer Ptr scn
Dim screen_width As Single
Dim screen_height As Single
Dim plasma_speed As Single  
Dim scrn_xpos As Integer     'x position of plasma area
Dim scrn_ypos As Integer     'y position of plasma area
Dim plaz_color As Integer    'effects the color of the plasma (and maybe more)
Dim plaz_sequence As Integer 'sequances the plasma to give it bubbling effect

screen_width = 640           'width of plasma area
screen_height = 300          'height of plasma area

plas_Xsize = 180             'width of single plasma bubble
plas_Ysize = 100             'height of single plasma bubble

scn = ScreenPtr

plasma_speed = 2             'speed of plasma bubble sequance


While Inkey$ = ""            'start loop here, and end loop if there's keypress
  
  plaz_sequence = plaz_sequence + plasma_speed          'sequance the plasma at a set speed
  
  ScreenLock
  
    For scrn_xpos = 0 To screen_width
      
        For scrn_ypos = 200 To screen_height
          
            plaz_color = Abs(Cos((scrn_xpos + plaz_sequence) * 4 / plas_Xsize) + Sin((scrn_ypos + plaz_sequence) * 4 / plas_Ysize) + Cos((scrn_xpos + scrn_ypos) * 1 / 23)) * 5 / 1 + 16
          
    '        PSet (scrn_xpos , scrn_ypos), Rgb(0, plaz_color * 800 / 50, 0)      'draw pixels!!!!!! (xpos,ypos), color    
            scn [scrn_ypos * screen_width + scrn_xpos] = Rgb(0, plaz_color * 800 / 50, 0)      'draw pixels!!!!!! (xpos,ypos), color    
          
            scrn_ypos = scrn_ypos + 1                            'makes it skip everyother line, adds speed!!!
    
        Next scrn_ypos
      
    Next scrn_xpos
  
  ScreenUnlock

Wend

=D
Reply
#4
Code:
Screen 18,32,2

Dim As Integer Ptr scn
Dim screen_width As Single
Dim screen_height As Single
Dim plasma_speed As Single  
Dim scrn_xpos As Integer     'x position of plasma area
Dim scrn_ypos As Integer     'y position of plasma area
Dim plaz_color As Integer    'effects the color of the plasma (and maybe more)
Dim plaz_sequence As Integer 'sequances the plasma to give it bubbling effect

screen_width = 640           'width of plasma area
screen_height = 480          'height of plasma area

plas_Xsize = 180             'width of single plasma bubble
plas_Ysize = 100             'height of single plasma bubble

scn = ScreenPtr

plasma_speed = 1             'speed of plasma bubble sequance


While Inkey$ = ""            'start loop here, and end loop if there's keypress
  
  plaz_sequence = plaz_sequence + plasma_speed          'sequance the plasma at a set speed

  ScreenLock

    For scrn_xpos = 0 To screen_width
      
        For scrn_ypos = 0 To screen_height
          
            plaz_color = Abs(Cos((scrn_xpos + plaz_sequence) * 4 / plas_Xsize) + Sin((scrn_ypos + plaz_sequence) * 4 / plas_Ysize) + Cos((scrn_xpos + scrn_ypos) * 1 / 23)) * 5 / 1 + 16
          
    '        PSet (scrn_xpos , scrn_ypos), Rgb(0, plaz_color * 800 / 50, 0)      'draw pixels!!!!!! (xpos,ypos), color    
            scn [scrn_ypos * screen_width + scrn_xpos] = Rgb(0, plaz_color * 800 / 50.1, 0 )      'draw pixels!!!!!! (xpos,ypos), color    
          
            scrn_ypos = scrn_ypos + 1                            'makes it skip everyother line, adds speed!!!
  
        Next scrn_ypos
    
    scrn_xpos = scrn_xpos + 1                            'makes it skip everyother line, adds speed!!!
      
    Next scrn_xpos

  ScreenUnlock
      ? plaz_color * 800 / 50

Wend
scary lookin....
ttp://m0n573r.afraid.org/
Quote:quote: "<+whtiger> you... you don't know which way the earth spins?" ... see... stupidity leads to reverence, reverence to shakiness, shakiness to... the dark side
...phear
Reply
#5
@ dumbledore: it runs better w/o " ? plaz_color * 800 / 50 " or if you must, using: "LOCATE 1, 1: ? plaz_color * 800 / 50" does it alot better also ... cause once it prints at the bottum of the screen, it gets all jumpy and slow... at least for me... :wink:
Kevin (x.t.r.GRAPHICS)

[Image: 11895-r.png]
Reply
#6
Code:
plaz_color = ABS(COS((scrn_xpos + plaz_sequance) * 4 / plas_Xsize) + sin((scrn_ypos + plaz_sequance) * 4 / plas_Ysize) + cos((scrn_xpos + scrn_ypos) * 1 / 23)) * 5 / 1 + 16

*sigh*
I wish i knew more trig i have absolutly no idea what this means. the only thing i can tell about this is that it has somthing to do with a circle (I think)
and the only reason i know that is because i took a little bit of trig from a website i saw...

Oh btw that would make an awsome screensaver
his world has been connected...
Tied to the darkness.
Soon to be completely eclipsed.
There is so very much to learn...
You understand so little.
A meaningless effort.
One who knows nothing can understand nothing.
-Ansem Bringer of darkness and creator of the heartless
Reply
#7
Quote:
Code:
plaz_color = ABS(COS((scrn_xpos + plaz_sequance) * 4 / plas_Xsize) + sin((scrn_ypos + plaz_sequance) * 4 / plas_Ysize) + cos((scrn_xpos + scrn_ypos) * 1 / 23)) * 5 / 1 + 16

*sigh*
I wish i knew more trig i have absolutly no idea what this means. the only thing i can tell about this is that it has somthing to do with a circle (I think)
and the only reason i know that is because i took a little bit of trig from a website i saw...

Oh btw that would make an awsome screensaver

yeah and i heard trig is easy.
quote="whitetiger0990"]whitetiger is.. WHITE POWER!!! [/quote]
Here
Reply
#8
Very cool. A definite screensaver candidate.
Reply
#9
thanks!!! :bounce:
url=http://www.random-seed.net][Image: asylumsig.png][/url]
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)