|Interface||public interface Initializer extends Behaviour|
|Implementors||InitializerBase, TweenToCurrentPosition, TweenToZone|
An Initializer is a class that is used to set properties of a particle when it is created. Initializers may, for example, set an initial velocity for a particle.
Initializers are directly associated with emitters and act on all particles created by that emitter. Initializers are applied to all particles created by an emitter by using the emitter's addInitializer method. Initializers are removed from the emitter by using the emitter's removeInitializer method.
The key method in the Initializer interface is the initiaize method. This is called for every particle and is where the initializer modifies the particle's properties.
|priority : int|
The priority property is used to order the execution of behaviours.
The addedToEmitter method is called by the emitter when the Behaviour is added to it.
The initialize method is used by the emitter to apply the initialization to every particle.
The removedFromEmitter method is called by the emitter when the Behaviour is removed from it.
public function initialize(emitter:Emitter, particle:Particle):void
The initialize method is used by the emitter to apply the initialization to every particle. It is the key feature of the initializers and is used to initialize the state of every particle. This method is called within the emitter's createParticle method for every particle and need not be called by the user.