ActionScript 2.0; Flash Player 6
Partigen 1.0
PGemitter.freeze([a1, a2:Number])
a1 (PGparticle/Number) The particle for freezing a single particle or the start index for multiple particles.
a2 (Number) End index.
Array - of IDs of particles frozen.
Method; Freezes emitters specified child particles. This pauses all tweens on the particle, freezing it in place for both tween and physics modes. When the particle is thawed, it resumes where it left off.
Passing no parameters will freeze all living particles.
The first parameter is a single particle to freeze or the first index of the array of living particles.
The second parameter is the optional last index. If this is omitted, the first parameter will be the index of a single particle.
The following example only freezes the newest 10 particles when the user clicks:
Partigen.createEmitter(this, 'my_em', 0); //create an emitter with all the defaults
my_em._x = my_em._y = 200; //set the emitters x&y position to 200 so we can see it
my_em._mode = ['physics', 'line']; //set mode and emission type
my_em._eps = 10; //set eps to 10
my_em.start();
_root.onMouseDown = function() {
my_em.stop(); //stop the emitter
trace(my_em.freeze(0, 10)); //freeze particles and trace
}