C# Class geek.GameEngine.Visuals.ParticleSystem

The class that manages a swarm of particles.
Inheritance: ObjectGroup
Mostra file Open project: impworks/xna.geek.engine

Public Properties

Property Type Description
Generator Func
IsActive bool
ParticleAngle geek.GameEngine.Utils.JitteryValue
ParticleLimit int
ParticleOrigin geek.GameEngine.Utils.JitteryVector2
ParticlePropulsion geek.GameEngine.Utils.JitteryValue
TimeToLive geek.GameEngine.Utils.JitteryValue

Public Methods

Method Description
ParticleSystem ( int rate, Func generator = null ) : System
ParticleSystem ( int rate, string particleAssetName ) : System
Reset ( ) : void

Reinitialize the particle system properties.

Update ( ) : void

Protected Methods

Method Description
createParticle ( ) : void

Create a new particle in the swarm.

tweakParticle ( DynamicObject obj ) : void

Set the particle's default properties.

Private Methods

Method Description
createDefaultParticle ( string assetName ) : GameObject

Create a particle out of an asset.

Method Details

ParticleSystem() public method

public ParticleSystem ( int rate, Func generator = null ) : System
rate int
generator Func
return System

ParticleSystem() public method

public ParticleSystem ( int rate, string particleAssetName ) : System
rate int
particleAssetName string
return System

Reset() public method

Reinitialize the particle system properties.
public Reset ( ) : void
return void

Update() public method

public Update ( ) : void
return void

createParticle() protected method

Create a new particle in the swarm.
protected createParticle ( ) : void
return void

tweakParticle() protected method

Set the particle's default properties.
protected tweakParticle ( DynamicObject obj ) : void
obj DynamicObject Particle to tweak.
return void

Property Details

Generator public_oe property

The generator of new particles.
public Func Generator
return Func

IsActive public_oe property

Checks if the PS should create new particles.
public bool IsActive
return bool

ParticleAngle public_oe property

The angle to propel objects to.
public JitteryValue,geek.GameEngine.Utils ParticleAngle
return geek.GameEngine.Utils.JitteryValue

ParticleLimit public_oe property

The number of particles the system may produce before self-destruction.
public int ParticleLimit
return int

ParticleOrigin public_oe property

The location at which to create
public JitteryVector2,geek.GameEngine.Utils ParticleOrigin
return geek.GameEngine.Utils.JitteryVector2

ParticlePropulsion public_oe property

The strength of the propulsion.
public JitteryValue,geek.GameEngine.Utils ParticlePropulsion
return geek.GameEngine.Utils.JitteryValue

TimeToLive public_oe property

Each particle's lifefime length before it gets destroyed.
public JitteryValue,geek.GameEngine.Utils TimeToLive
return geek.GameEngine.Utils.JitteryValue