PGemitter._physics_angle Property

Availability

ActionScript 2.0; Flash Player 6

Since

Partigen 1.0

Usage

PGemitter._physics_angle : Number

Description

Property, read/write; Physics emission angle. This is the angle at which a particle is emitted at. This value is in degrees, such as a circle.

So for instance, a value of 0 would emit right, 90 up, 180 left, and 270 down.

This also affects the x and y velocity of a particle. When the angle is exactly vertical (90, 270), x-velocity will always be 0. When the angle is exactly horizontal (0, 180), y-velocity will always be 0.

Example

The following example will emit particles straight down:

Partigen.createEmitter(this, 'my_em', 0); //create a new 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_mode = 'physics'; //set the mode to physics
my_em._physics_angle = 270; //shoot particles down
my_em.start();

See Also

PGemitter.setPhysics(), PGemitter._physics_vx, PGemitter._physics_vy, PGemitter._physics_ax, PGemitter._physics_ay, PGemitter._physics_fx, PGemitter._physics_fy, PGemitter._physics_anglerange


Documentation generated by BLDoc Community Edition from B-Line Express.