Realistic Smoke (With collision)

Post here your demos and examples with the source files.
Forum rules
Always post the games with a screenshot.
The file must have the ged and data files (complete game source)
Use the forum attachment to post the files.
It is always better to use the first post to put the game files

Realistic Smoke (With collision)

Postby Game A Gogo » Tue Dec 28, 2010 4:09 pm

Alright, this morning I woke up and remembered my old old (almost ancient) smoke bomb demo, so I wanted to make a smoke generator demo.
But I didn't just wanted to make one, I wanted it to be realistic. So I tried to remember all those chemistry and physics notes in my head to figure out, how do particle react together?
I got a few notes down and integrated it in my concept and this nifty demo came out!

Yes, the particles collide with themselves, but only the middle, since one particle is suppose to represent several atoms of gas mixed with air. (It would be extremly CPU costly if I were to make 1x1 smoke particle ;) )

So I hope you enjoy this, learn a bit, and may it be helpful in a game for cool effects :D
too bad it requires a not so decent amount of CPU processing.

Note: make the smoke blue and what do you have? Watery slime! (hint for possible usage ;) )
Attachments
RealisticSmoke.PNG
Realistic Smoke.zip
(68.75 KiB) Downloaded 208 times
Programming games is an art,
    Respect it.
User avatar
Game A Gogo
 
Posts: 3466
Joined: Wed Jun 29, 2005 10:49 pm
Location: French Canada *laughs*
Score: 181 Give a positive score

Re: Realistic Smoke (With collision)

Postby Camper1995 » Tue Dec 28, 2010 5:04 pm

Very good! ;) By the way, it looks little bit like soap-bubbles :D
Say hello to my little friend.
User avatar
Camper1995
 
Posts: 707
Joined: Tue Dec 30, 2008 7:20 pm
Location: Lost in the past.
Score: 44 Give a positive score

Re: Realistic Smoke (With collision)

Postby Game A Gogo » Tue Dec 28, 2010 6:48 pm

haha
to have super realistic smoke would require smaller particles and a lot more cpu :)
Programming games is an art,
    Respect it.
User avatar
Game A Gogo
 
Posts: 3466
Joined: Wed Jun 29, 2005 10:49 pm
Location: French Canada *laughs*
Score: 181 Give a positive score

Re: Realistic Smoke (With collision)

Postby Camper1995 » Wed Dec 29, 2010 10:19 am

Hm, yes. But maybe it's just easier to make animation that begins from small smoke cloud and ends and bigger smoke cloud.

And make the animation disaper.. Maybe this will look more realistic. I can try to make some animations if you want ;)
Say hello to my little friend.
User avatar
Camper1995
 
Posts: 707
Joined: Tue Dec 30, 2008 7:20 pm
Location: Lost in the past.
Score: 44 Give a positive score

Re: Realistic Smoke (With collision)

Postby Game A Gogo » Thu Dec 30, 2010 5:07 pm

and like I said, it can be used for say, a water jet stream from a gun or something, something like that can be made efficiently with this, :)
Programming games is an art,
    Respect it.
User avatar
Game A Gogo
 
Posts: 3466
Joined: Wed Jun 29, 2005 10:49 pm
Location: French Canada *laughs*
Score: 181 Give a positive score

Re: Realistic Smoke (With collision)

Postby makslane » Fri Dec 31, 2010 11:38 pm

This is great :-)
Game Editor is an open source game creator software that's wants to pay it's developers to keep evolving.
If you like Game Editor, make a review!
makslane
Site Admin
 
Posts: 3947
Joined: Sat Apr 05, 2003 6:47 pm
Score: 182 Give a positive score

Re: Realistic Smoke (With collision)

Postby lcl » Sat Jan 01, 2011 9:12 am

One thing that makes it run better..
Change the code in SmokePartC's draw actor code.
The line that is commented as "Disipation".
Code: Select all
transp += 0.002; //Instead of 0.001

Now, the actor fades faster and it runs better. :D
This is very nice demo! Good job!
User avatar
lcl
 
Posts: 2339
Joined: Thu Mar 25, 2010 5:55 pm
Location: Finland
Score: 276 Give a positive score

Re: Realistic Smoke (With collision)

Postby tintran » Sat Jan 08, 2011 3:56 am

sweet!
User avatar
tintran
 
Posts: 157
Joined: Fri Dec 24, 2010 1:34 am
Score: 30 Give a positive score


Return to Game Demos

Who is online

Users browsing this forum: No registered users and 1 guest