Torque3D Documentation / _generateds / ParticleEmitterData

ParticleEmitterData

consoledoc.h

Defines particle emission properties such as ejection angle, period and velocity for a ParticleEmitter.

More...

ParticleEmitterData

int

Time (in milliseconds) between each particle ejection.

int

Variance in ejection period, from 1 - ejectionPeriodMS.

float

Particle ejection velocity.

float

Variance for ejection velocity, from 0 - ejectionVelocity.

float

Distance along ejection Z axis from which to eject particles.

float

Distance Padding along ejection Z axis from which to eject particles.

float

Minimum angle, from the horizontal plane, to eject from.

float

Maximum angle, from the horizontal plane, to eject particles from.

float

Angle variance from the previous particle, from 0 - 180.

float

Reference angle, from the vertical plane, to eject particles from.

float

Variance from the reference angle, from 0 - 360.

float

For soft particles, the distance (in meters) where particles will be faded based on the difference in depth between the particle and the scene geometry.

float

Used to generate the final particle color by controlling interpolation between the particle color and the particle color multiplied by the ambient light color.

bool

If false, particles emitted in the same frame have their positions adjusted. If true, adjustment is skipped and particles will clump together.

bool

If true, Particles will always face the camera.

bool

If true, particles will be oriented to face in the direction they are moving.

bool

If true, particles are rendered as a continous ribbon.

string

List of space or TAB delimited ParticleData datablock names.

int

Lifetime of emitted particles (in milliseconds).

int

Variance in particle lifetime from 0 - lifetimeMS.

bool

If true, use emitter specified sizes instead of datablock sizes.

bool

If true, use emitter specified colors instead of datablock colors.

String value that controls how emitted particles blend with the scene.

bool

If true, particles are sorted furthest to nearest.

bool

If true, reverses the normal draw order of particles.

string

Optional texture to override ParticleData::textureName.

bool

If true, particles always face along the axis defined by alignDirection.

Point3F

The direction aligned particles should face, only valid if alignParticles is true.

bool

This particle system should not use the mixed-resolution renderer. If your particle system has large amounts of overdraw, consider disabling this option.

bool

Controls whether particles are rendered onto reflective surfaces like water.

bool

If true, the particles are rendered to the glow buffer as well.

Public Functions

void

Reloads the ParticleData datablocks and other fields used by this emitter.

Detailed Description

Defines particle emission properties such as ejection angle, period and velocity for a ParticleEmitter.

datablock ParticleEmitterData( GrenadeExpDustEmitter )
{
   ejectionPeriodMS = 1;
   periodVarianceMS = 0;
   ejectionVelocity = 15;
   velocityVariance = 0.0;
   ejectionOffset = 0.0;
   thetaMin = 85;
   thetaMax = 85;
   thetaVariance = 0;
   phiReferenceVel = 0;
   phiVariance = 360;
   overrideAdvance = false;
   lifetimeMS = 200;
   particles = "GrenadeExpDust";
};

ParticleEmitterData

int ejectionPeriodMS 

Time (in milliseconds) between each particle ejection.

int periodVarianceMS 

Variance in ejection period, from 1 - ejectionPeriodMS.

float ejectionVelocity 

Particle ejection velocity.

float velocityVariance 

Variance for ejection velocity, from 0 - ejectionVelocity.

float ejectionOffset 

Distance along ejection Z axis from which to eject particles.

float ejectionOffsetVariance 

Distance Padding along ejection Z axis from which to eject particles.

float thetaMin 

Minimum angle, from the horizontal plane, to eject from.

float thetaMax 

Maximum angle, from the horizontal plane, to eject particles from.

float thetaVariance 

Angle variance from the previous particle, from 0 - 180.

float phiReferenceVel 

Reference angle, from the vertical plane, to eject particles from.

float phiVariance 

Variance from the reference angle, from 0 - 360.

float softnessDistance 

For soft particles, the distance (in meters) where particles will be faded based on the difference in depth between the particle and the scene geometry.

float ambientFactor 

Used to generate the final particle color by controlling interpolation between the particle color and the particle color multiplied by the ambient light color.

bool overrideAdvance 

If false, particles emitted in the same frame have their positions adjusted. If true, adjustment is skipped and particles will clump together.

bool orientParticles 

If true, Particles will always face the camera.

bool orientOnVelocity 

If true, particles will be oriented to face in the direction they are moving.

bool ribbonParticles 

If true, particles are rendered as a continous ribbon.

string particles 

List of space or TAB delimited ParticleData datablock names.

A random one of these datablocks is selected each time a particle is emitted.

int lifetimeMS 

Lifetime of emitted particles (in milliseconds).

int lifetimeVarianceMS 

Variance in particle lifetime from 0 - lifetimeMS.

bool useEmitterSizes 

If true, use emitter specified sizes instead of datablock sizes.

Useful for Debris particle emitters that control the particle size.

bool useEmitterColors 

If true, use emitter specified colors instead of datablock colors.

Useful for ShapeBase dust and WheeledVehicle wheel particle emitters that use the current material to control particle color.

ParticleBlendStyle blendStyle 

String value that controls how emitted particles blend with the scene.

bool sortParticles 

If true, particles are sorted furthest to nearest.

bool reverseOrder 

If true, reverses the normal draw order of particles.

Particles are normally drawn from newest to oldest, or in Z order (furthest first) if sortParticles is true. Setting this field to true will reverse that order: oldest first, or nearest first if sortParticles is true.

string textureName 

Optional texture to override ParticleData::textureName.

bool alignParticles 

If true, particles always face along the axis defined by alignDirection.

Point3F alignDirection 

The direction aligned particles should face, only valid if alignParticles is true.

bool highResOnly 

This particle system should not use the mixed-resolution renderer. If your particle system has large amounts of overdraw, consider disabling this option.

bool renderReflection 

Controls whether particles are rendered onto reflective surfaces like water.

bool glow 

If true, the particles are rendered to the glow buffer as well.

AFX

bool ejectionInvert 
bool fadeColor 
bool fadeAlpha 
bool fadeSize 
bool useEmitterTransform 

AFX Pooled Particles

afxParticlePoolData poolData 
int poolIndex 
bool poolDepthFade 
bool poolRadialFade 

Public Functions

reload()

Reloads the ParticleData datablocks and other fields used by this emitter.

// Get the editor's current particle emitter
%emitter = PE_EmitterEditor.currEmitter

// Change a field value
%emitter.setFieldValue( %propertyField, %value );

// Reload this emitter
%emitter.reload();