Constructor
new ParticleSet() → {ParticleSet}
- Source:
Returns:
a new ParticleSet instance
- Type
- ParticleSet
Extends
Methods
addEmitterAt(x, y, n, func)
Add a new ParticleEmitter to the lsit
Parameters:
| Name | Type | Description |
|---|---|---|
x |
float | X world coordinate position for this Emitter |
y |
float | Y world coordinate position for this Emitter |
n |
int | number of Particles to emit |
func |
function | function for the emitter to use for Particle Generation |
- Source:
addToSet(obj)
Adds an GameObject to this GameObjectSet
Parameters:
| Name | Type | Description |
|---|---|---|
obj |
GameObject | GameObject to add to the set |
- Inherited From:
- Source:
draw(aCamera)
Draw the Particles in this ParticleSet using additive blending
Parameters:
| Name | Type | Description |
|---|---|---|
aCamera |
Camera | the Camera to draw to |
- Overrides:
- Source:
drawMarkers(aCamera)
Draw the markers of the Particles in this ParticleSet
Parameters:
| Name | Type | Description |
|---|---|---|
aCamera |
Camera | the Camera to draw to |
- Source:
getObjectAt(index) → {GameObject}
Returns the GameObject at a specified index of this GameObjectSet
Parameters:
| Name | Type | Description |
|---|---|---|
index |
integer | the set index to access |
- Inherited From:
- Source:
Returns:
GameObject at the specified index
- Type
- GameObject
moveToLast(obj)
Adds the GameObject to the end of set, removing it if already present
Parameters:
| Name | Type | Description |
|---|---|---|
obj |
GameObject | the GameObject to be appened |
- Inherited From:
- Source:
removeFromSet(obj)
Remove an GameObject from this GameObjectSet if present
Parameters:
| Name | Type | Description |
|---|---|---|
obj |
GameObject | the GameObject to be removed |
- Inherited From:
- Source:
size() → {integer}
Returns the number of GameObjects contained in this GameObjectSet
- Inherited From:
- Source:
Returns:
the length of this set
- Type
- integer
toggleDrawBound()
Toggles the drawing of each BoundingBox in this GameObjectSet
- Inherited From:
- Source:
toggleDrawRenderable()
Toggles the drawing of each renderable in this GameObjectSet
- Inherited From:
- Source:
toggleDrawRigidShape()
Toggles the drawing of each rigidShape in this GameObjectSet
- Inherited From:
- Source:
update()
Emit Particles and prune expired objects
- Overrides:
- Source: