Class: Phaser.Particles
Constructor
new Particles(game)
Phaser.Particles is the Particle Manager for the game. It is called during the game update loop and in turn updates any Emitters attached to it.
Parameters
| Name | Type | Description |
|---|---|---|
game | Phaser.Game | A reference to the currently running game. |
- Source code: particles/Particles.js (Line 14)
Classes
Public Properties
- Source code: particles/Particles.js (Line 24)
- Source code: particles/Particles.js (Line 19)
- Source code: particles/Particles.js (Line 30)
emitters : Object
Internal emitters store.
game : Phaser.Game
A reference to the currently running Game.
ID : number
-
Public Methods
- Source code: particles/Particles.js (Line 36)
- Source code: particles/Particles.js (Line 50)
- Internal:
- This member is internal (protected) and may be modified or removed in the future.
- Source code: particles/Particles.js (Line 61)
add(emitter) → {Phaser.Emitter}
Adds a new Particle Emitter to the Particle Manager.
Parameters
| Name | Type | Description |
|---|---|---|
emitter | Phaser.Emitter | The emitter to be added to the particle manager. |
Returns
Phaser.Emitter -
The emitter that was added.
remove(emitter)
Removes an existing Particle Emitter from the Particle Manager.
Parameters
| Name | Type | Description |
|---|---|---|
emitter | Phaser.Emitter | The emitter to remove. |
<internal> update()
Called by the core game loop. Updates all Emitters who have their exists value set to true.
© 2016 Richard Davey, Photon Storm Ltd.
Licensed under the MIT License.
http://phaser.io/docs/2.6.2/Phaser.Particles.html