Package | verlocity.components |
Class | public class verParticles |
Inheritance | verParticles Component Singleton Object |
Property | Defined By | ||
---|---|---|---|
className : Object [read-only]
Returns the class name of the component for
dictionary registration. | Component | ||
countEmitters : int [read-only]
Returns the current amount of emitters active. | verParticles | ||
countParticles : int [read-only]
Returns the current amount of alive particles. | verParticles | ||
deadParticles : int [read-only]
Returns the current dead particles. | verParticles | ||
maxEmitters : int [read-only]
Returns the max emitters allowed. | verParticles | ||
maxParticles : int [read-only]
Returns the max particles available. | verParticles |
Method | Defined By | ||
---|---|---|---|
Constructor of the component. | verParticles | ||
_Destruct():void [override]
Destructor of the component. | verParticles | ||
_IsNotUpdating():Boolean
Returns if the component is not updating (paused). | Component | ||
_IsValid():Boolean
Returns if this singleton is active/valid. | Singleton | ||
_SetUpdating(bUpdating:Boolean):void
Pauses/resumes the component updating, if it's pausable. | Component | ||
_UpdateComponent():void
Updates the component, if possible. | Component | ||
Create(sLayer:String, iSetMaxParticles:int = 800, iSetMaxEmitters:int = 25, nWidth:Number, nHeight:Number):void
Creates the particle system
| verParticles | ||
CreateEmitter(emitter:ParticleEmitter):void
Creates a particle emitter
| verParticles | ||
IsParticlePool():Boolean
Returns if the particle pool was created
| verParticles | ||
Remove():void
Removes the particle system
| verParticles | ||
RemoveAll():void
Removes all particles and emitters
| verParticles | ||
RemoveAllEmitters():void
Removes all emitters
| verParticles | ||
RemoveAllParticles():void
Removes all active particles. | verParticles | ||
RemoveEffects():void
Removes the effects applied to the particles completely
| verParticles | ||
SetEffectPreset(iPreset:int = 0):void
Sets the effect to a preset. | verParticles | ||
SetEffects(iRedrawSpeed:int = 15):void
Sets the effects (redraw speed)
| verParticles |
Method | Defined By | ||
---|---|---|---|
_Concommands():void [override]
Concommands of the component. | verParticles | ||
_Update():void [override]
Updates the particles, emitters, and effects. | verParticles |
Constant | Defined By | ||
---|---|---|---|
EFF_DEFAULT : int = 0 | verParticles | ||
EFF_EVERLASTING : int = 1 | verParticles | ||
EFF_HARDDOTS : int = 2 | verParticles |
countEmitters | property |
countEmitters:int
[read-only] Returns the current amount of emitters active.
public function get countEmitters():int
countParticles | property |
countParticles:int
[read-only] Returns the current amount of alive particles.
public function get countParticles():int
deadParticles | property |
deadParticles:int
[read-only] Returns the current dead particles.
public function get deadParticles():int
maxEmitters | property |
maxEmitters:int
[read-only] Returns the max emitters allowed.
public function get maxEmitters():int
maxParticles | property |
maxParticles:int
[read-only] Returns the max particles available.
public function get maxParticles():int
verParticles | () | Constructor |
public function verParticles()
Constructor of the component.
_Concommands | () | method |
override protected function _Concommands():void
Concommands of the component.
_Destruct | () | method |
override public function _Destruct():void
Destructor of the component.
_Update | () | method |
override protected function _Update():void
Updates the particles, emitters, and effects.
Create | () | method |
public function Create(sLayer:String, iSetMaxParticles:int = 800, iSetMaxEmitters:int = 25, nWidth:Number, nHeight:Number):void
Creates the particle system
Parameters
sLayer:String — The layer to spawn the bitmap (particles) in
| |
iSetMaxParticles:int (default = 800 ) — The max particles available (suggested 800)
| |
iSetMaxEmitters:int (default = 25 ) — The max emitters available (suggested 25)
| |
nWidth:Number (default = NaN ) — The width of the particle bitmap (defaults screen width)
| |
nHeight:Number (default = NaN ) — The height of the particle bitmap (defaults screen height)
|
CreateEmitter | () | method |
public function CreateEmitter(emitter:ParticleEmitter):void
Creates a particle emitter
Parameters
emitter:ParticleEmitter |
IsParticlePool | () | method |
public function IsParticlePool():Boolean
Returns if the particle pool was created
ReturnsBoolean —
|
Remove | () | method |
public function Remove():void
Removes the particle system
RemoveAll | () | method |
public function RemoveAll():void
Removes all particles and emitters
RemoveAllEmitters | () | method |
public function RemoveAllEmitters():void
Removes all emitters
RemoveAllParticles | () | method |
public function RemoveAllParticles():void
Removes all active particles.
RemoveEffects | () | method |
public function RemoveEffects():void
Removes the effects applied to the particles completely
SetEffectPreset | () | method |
public function SetEffectPreset(iPreset:int = 0):void
Sets the effect to a preset. Use EFF_ constants.
Parameters
iPreset:int (default = 0 )
|
SetEffects | () | method |
public function SetEffects(iRedrawSpeed:int = 15):void
Sets the effects (redraw speed)
Parameters
iRedrawSpeed:int (default = 15 ) — The speed to redraw the particles; -100 - 100 (higher the faster). Recommended 15.
|
EFF_DEFAULT | Constant |
public const EFF_DEFAULT:int = 0
EFF_EVERLASTING | Constant |
public const EFF_EVERLASTING:int = 1
EFF_HARDDOTS | Constant |
public const EFF_HARDDOTS:int = 2