Particle and emmiter actors

Ideas for Game Editor evolution.

Particle and emmiter actors

Postby Novice » Mon Oct 23, 2006 10:21 pm

This would be great. It would make simulating smoke and stuff much easier and less processor intensive.

There could be three types of emitters point, curve, and surface.
The emitter should have a simple drop menu that allows the user to select which particles should be emitted and at what rate, direction... should they be emitted. Something like this:
Code: Select all
Particle 1: "Particle1Actor"//here we select which particle actor to emmit
Direction:rand(150);//at what starting direction to emit it
Spread:30;//what is the allowed spread
Rate:50;//how many particles are created per frame
Speed:rand(10)//the starting speed of the particles
____________________________
Particle 2: "Particle2Actor"
Direction:60;
Spread:90;
Rate:100;
...

Particles should be simplified actors with only animations, transparency, life(how long they exist), zdepth, direction and speed.

This would be a good addition to GE because simulating explosions and stuff with normal actor really kicks the processor. :wink:
Why do i always get stuck?
User avatar
Novice
 
Posts: 399
Joined: Mon Aug 29, 2005 10:54 am
Location: Relative
Score: 5 Give a positive score

Re: Particle and emmiter actors

Postby Clokio » Mon Jun 13, 2011 3:21 pm

Ya particules it's a minimum for a 2D game engine that want to attract profesionnals. :wink:
I am sure it can be done with a free ODE or bullet physic engine.Or 2D boxhttp://www.box2d.org/
Clokio
 
Posts: 229
Joined: Tue May 17, 2011 2:18 pm
Score: 32 Give a positive score

Re: Particle and emmiter actors

Postby MrJolteon » Tue Jun 14, 2011 2:55 pm

Dude, this topic is old.
Particles is possible in GE even now, just make a canvas actor, add the particle actor, make a timer around 20 ms, then on Draw Actor(On the canvas), start the timer, then on Timer, enter this line of code:
Code: Select all
CreateActor("particle", "", etc you know what I mean, just instead of the x(Or y) coordinates put rand(any number you want)


Then, over to the particles(For smoke, flames, etc)
Make a timer, somewhat longer than the first one, on Draw Actor, also write
Code: Select all
yvelocity -= 5;
in the Script Editor or something, then on Timer, add a Destroy Actor/Event Actor action.

For water, etc:
Just add the downwards gravity as you would do anyways
Owner of the #GameEditor IRC channel at esper.net
User avatar
MrJolteon
 
Posts: 1924
Joined: Sat Aug 09, 2008 3:25 pm
Location: Fifth Layer
Score: 75 Give a positive score

Re: Particle and emmiter actors

Postby Game A Gogo » Tue Jun 14, 2011 8:02 pm

viewtopic.php?f=6&t=9633
This probably will help you :)
Programming games is an art,
    Respect it.
User avatar
Game A Gogo
 
Posts: 3464
Joined: Wed Jun 29, 2005 10:49 pm
Location: French Canada *laughs*
Score: 181 Give a positive score

Re: Particle and emmiter actors

Postby Clokio » Wed Jun 15, 2011 9:13 am

Thanks guy's, but I will keep my point, we need a particule system actor, where size start, size end, color start color end. Something you can adjust live with sliders. All particules in 3D engines use 2D,

Simple example.
http://www.youtube.com/watch?v=vJv-cErKVNE
Clokio
 
Posts: 229
Joined: Tue May 17, 2011 2:18 pm
Score: 32 Give a positive score

Re: Particle and emmiter actors

Postby Game A Gogo » Wed Jun 15, 2011 9:16 am

But by making the system yourself in scripts (Not really hard) you can even control the number of particles that will appear on the screen! So you can have some sort of "quality" setting for the different power of computers. Now don't get me wrong, I'm not trying to bash your idea, just discussion :)
Programming games is an art,
    Respect it.
User avatar
Game A Gogo
 
Posts: 3464
Joined: Wed Jun 29, 2005 10:49 pm
Location: French Canada *laughs*
Score: 181 Give a positive score

Re: Particle and emmiter actors

Postby Clokio » Wed Jun 15, 2011 9:36 am

I am here to learn, why not, "on se comprend"
Clokio
 
Posts: 229
Joined: Tue May 17, 2011 2:18 pm
Score: 32 Give a positive score

Re: Particle and emmiter actors

Postby Game A Gogo » Wed Jun 15, 2011 10:24 pm

You simply need a variable that will hold how many particles there are!
on particle create:
Code: Select all
ParticleC++;
//More code about particles...

and where-ever you'll have your
Code: Select all
DestroyActor();
(Most likely when it's done fading out), you can do
Code: Select all
ParticleC--;
Note: ++ increments by one and -- decrements by one. ++var increments before you read the var (That change is made before) and var++ increments after you read the var (That change is made after)

Now that you have a variable that holds the particle count, you can check that variable to determine if you should create a new particle or not!
Remember that particle are simply eye candy, so even if they are not present it shouldn't bother the gameplay!

So you probably have a generator actor, or even action (like an explosion) but either the case, wherever you'd create your actors, make it like this:
Code: Select all
if(ParticleC<100)
{
    CreateActor(particle);
}


and there you have it! A particle limiter, that 100 value can be a variable also! so the user can choose what limit there should be, and you can even make a code that can detect the best performance for the current computer! (my demo P2040 holds this system, but I warn it's not very friendly demo since it's for more advance users)
Programming games is an art,
    Respect it.
User avatar
Game A Gogo
 
Posts: 3464
Joined: Wed Jun 29, 2005 10:49 pm
Location: French Canada *laughs*
Score: 181 Give a positive score


Return to Feature Requests

Who is online

Users browsing this forum: No registered users and 1 guest