Package | com.desuade.partigen.controllers |
Class | public dynamic class ParticlePhysicsController |
Inheritance | ParticlePhysicsController ![]() |
Language Version : | ActionScript 3 |
Since : | 02.07.2009 |
Runtime Versions : | AIR 1.0, Flash Player 9.0.0 |
Property | Defined By | ||
---|---|---|---|
duration : Number
This sets/gets the duration for all the ParticleTweenControllers inside (velocity, acceleration, friction)
| ParticlePhysicsController | ||
flip : Boolean = false
The boolean flip (for cartesian reversal) value to be passed to the internal 'physics' object. | ParticlePhysicsController | ||
useAngle : Boolean = true
If this is set to true, the physics object will use the emitter's angle value. | ParticlePhysicsController |
Method | Defined By | ||
---|---|---|---|
ParticlePhysicsController(duration:Number, containerClass:Class = null, tweenClass:Class = null)
This is like a PhysicsMultiController from the Motion Package, but is used as a placeholder to configure emitters.
ParticlePhysicsControllers create PhysicsMultiControllers on each particle that's created, allowing the particles to change over their lives with physics.
Each one has 3 sub ParticleTweenControllers: velocity, acceleration, friction. | ParticlePhysicsController | ||
fromXML(xml:XML):ParticlePhysicsController
Configures the ParticlePhysicsController and creates all child ParticleTweenControllers.
Note: this does not include the "property" unless it's called from the ParticleController.
| ParticlePhysicsController | ||
toXML():XML
This creates an XML object representing the ParticlePhysicsController and it's child ParticleTweenControllers.
Note: this does not include the "property" unless it's called from the ParticleController.
| ParticlePhysicsController |
duration | property |
duration:Number
This sets/gets the duration for all the ParticleTweenControllers inside (velocity, acceleration, friction)
public function get duration():Number
public function set duration(value:Number):void
flip | property |
public var flip:Boolean = false
The boolean flip (for cartesian reversal) value to be passed to the internal 'physics' object.
See also
useAngle | property |
public var useAngle:Boolean = true
If this is set to true, the physics object will use the emitter's angle value. If false, no angle will be used in calculating the initial velocity.
ParticlePhysicsController | () | Constructor |
public function ParticlePhysicsController(duration:Number, containerClass:Class = null, tweenClass:Class = null)
This is like a PhysicsMultiController from the Motion Package, but is used as a placeholder to configure emitters.
ParticlePhysicsControllers create PhysicsMultiControllers on each particle that's created, allowing the particles to change over their lives with physics.
Each one has 3 sub ParticleTweenControllers: velocity, acceleration, friction. These can each be configured like normal ParticleTweenControllers.
Using the addPhysics() method is recommended over calling this directly.
Parametersduration:Number — The entire duration for the controller. If this is 0, the duration will be set to the particle's life.
| |
containerClass:Class (default = null ) — The class to use for Keyframes. Null will use the default.
| |
tweenClass:Class (default = null ) — The class to use for tweening on the controller. Null will use the default.
|
fromXML | () | method |
public function fromXML(xml:XML):ParticlePhysicsController
Configures the ParticlePhysicsController and creates all child ParticleTweenControllers.
Note: this does not include the "property" unless it's called from the ParticleController.
Parameters
xml:XML — The XML object to use for configuration
|
ParticlePhysicsController — The ParticlePhysicsController object (for chaining)
|
toXML | () | method |
public function toXML():XML
This creates an XML object representing the ParticlePhysicsController and it's child ParticleTweenControllers.
Note: this does not include the "property" unless it's called from the ParticleController.
ReturnsXML — And XML object for the ParticlePhysicsController
|