![]() |
Dayz Explorer 1.28.160049
|
Legacy way of using particles in the game. More...
Protected Member Functions | |
Playback | |
Methods regarding playing/stopping of particle | |
| override void | PlayParticle (int particle_id=-1) |
| Method to tell the particle to start playing. | |
| override bool | PlayParticleEx (int particle_id=-1, int flags=0) |
| Method to tell the particle to start playing. | |
| void | Play (int particle_id=-1) |
| Legacy function for backwards compatibility with 1.01 and below. | |
| override bool | StopParticle (int flags=0) |
| Method to tell the particle to stop playing. | |
| void | Stop () |
| Legacy function for backwards compatibility with 1.14 and below. | |
Properties and state | |
Obtain information or set properties regarding the state of the Particle | |
| void | SetSource (int particle_id) |
| Sets particle id. | |
| int | GetParticleID () |
| Gets particle id. | |
| Object | GetDirectParticleEffect () |
| Returns direct particle effect entity which is usually handled by this class 'Particle' if there is one. | |
| Object | GetParticleParent () |
| Returns the parent of this Particle if there is one. | |
| bool | HasActiveParticle () |
| Returns if there is any particle active. | |
| int | GetParticleCount () |
| Returns the total count of active particles in all emitors. | |
| bool | IsRepeat () |
| Returns whether there is a repeating particle. | |
| float | GetMaxLifetime () |
| Returns the approx. max lifetime. | |
Static Protected Member Functions | |
Create a particle (static) | |
You can create a particle either at some position, or create it as a child on some object. | |
| static Particle | CreateOnObject (int particle_id, Object parent_obj, vector local_pos="0 0 0", vector local_ori="0 0 0", bool force_world_rotation=false) |
| Creates a particle emitter and attaches it on the given object. | |
| static Particle | Create (int particle_id, Object parent_obj, vector local_pos="0 0 0", vector local_ori="0 0 0") |
| Legacy function for backwards compatibility. | |
| static Particle | CreateInWorld (int particle_id, vector global_pos, vector global_ori="0 0 0", bool force_world_rotation=false) |
| Creates a particle emitter on the given position. | |
| static Particle | Create (int particle_id, vector global_pos, vector global_ori="0 0 0") |
| Legacy function for backwards compatibility with 1.01 and below. | |
Static play on creation | |
You can use the following Play(...) functions to create and activate a particle in 1 line of your script. | |
| static Particle | PlayOnObject (int particle_id, Object parent_obj, vector local_pos="0 0 0", vector local_ori="0 0 0", bool force_world_rotation=false) |
| Creates a particle emitter, attaches it on the given object and activates it. | |
| static Particle | Play (int particle_id, Object parent_obj, vector local_pos="0 0 0", vector local_ori="0 0 0") |
| Legacy function for backwards compatibility with 1.01 and below. | |
| static Particle | PlayInWorld (int particle_id, vector global_pos) |
| Creates a particle emitter on the given position and activates it. | |
| static Particle | Play (int particle_id, vector global_pos) |
| Legacy function for backwards compatibility with 1.01 and below. | |
Generic data | |
Generic data for the Particle | |
| int | m_ParticleID |
| ID from ParticleList if assigned. | |
| float | m_Lifetime |
| Approx. remaining lifetime of particle. | |
| bool | m_IsRepeat |
| Whether this particle repeats. | |
Wiggle API | |
Settings to make the Particle wiggle | |
| Object | m_ParentObject |
| Parent Object the Particle is child of. | |
| Object | m_ParticleEffect |
| The child object which contains the actual particle. | |
| int | m_PreviousFrame |
| DEPRECATED. | |
| void | ParticleInit () |
| Purely here so that it can be emptied in ParticleSource. | |
| vector | RandWiggleVector () |
| Helper to get a randomized wiggle vector. | |
| float | RandWiggleFloat () |
| Helper to get a randomized wiggle float value. | |
Misc Particle specific helpers | |
Functionality specific for Particle | |
| void | UpdateState () |
| Creates/Destroys ParticleEffect child according to current state. | |
Legacy way of using particles in the game.
Definition at line 6 of file particle.c.
|
staticprotected |
Legacy function for backwards compatibility.
Definition at line 104 of file particle.c.
|
staticprotected |
Legacy function for backwards compatibility with 1.01 and below.
Definition at line 129 of file particle.c.
|
staticprotected |
Creates a particle emitter on the given position.
| particle_id | int Particle ID registered in ParticleList |
| global_pos | Vector Position where the particel will be created |
| global_ori | vector Orientation (Pitch, Yawn, Roll in degrees) (Optional) |
| force_world_rotation | bool Forces particle's orientation to rotate relative to the world and not with the object (Optional) |
Particle Created particle instance Definition at line 117 of file particle.c.
|
staticprotected |
Creates a particle emitter and attaches it on the given object.
| particle_id | int Particle ID registered in ParticleList |
| parent_obj | Object Instance on which this particle will be attached |
| local_pos | vector Attachment position local to the parent (Optional) |
| local_ori | vector Orientation local to the parent (Pitch, Yawn, Roll in degrees) (Optional) |
| force_world_rotation | bool Forces particle's orientation to rotate relative to the world and not with the object (Optional) |
Particle Created particle instance Definition at line 88 of file particle.c.
|
protected |
|
protected |
Returns the approx. max lifetime.
float The largest lifetime sum among the emitors Definition at line 380 of file particle.c.
|
protected |
Returns the total count of active particles in all emitors.
int Total count of active particles Definition at line 340 of file particle.c.
|
protected |
Gets particle id.
int The last set Particle ID registered in ParticleList Definition at line 297 of file particle.c.
|
protected |
Returns the parent of this Particle if there is one.
Object The registered parent or null Definition at line 316 of file particle.c.
|
protected |
Returns if there is any particle active.
bool Whether there is any particle active Definition at line 325 of file particle.c.
|
protected |
Returns whether there is a repeating particle.
bool whether there is a repeating particle Definition at line 354 of file particle.c.
|
protected |
Purely here so that it can be emptied in ParticleSource.
Definition at line 67 of file particle.c.
|
staticprotected |
Legacy function for backwards compatibility with 1.01 and below.
Definition at line 163 of file particle.c.
Legacy function for backwards compatibility with 1.01 and below.
Definition at line 185 of file particle.c.
|
protected |
Legacy function for backwards compatibility with 1.01 and below.
| particle_id | int Particle ID registered in ParticleList to start playing |
Definition at line 233 of file particle.c.
Creates a particle emitter on the given position and activates it.
| particle_id | int Particle ID registered in ParticleList |
| global_pos | Vector Position where the particel will be created |
Particle Created particle instance Definition at line 174 of file particle.c.
|
staticprotected |
Creates a particle emitter, attaches it on the given object and activates it.
| particle_id | int Particle ID registered in ParticleList |
| parent_obj | Object Instance on which this particle will be attached |
| local_pos | vector Attachment position local to the parent (Optional) |
| local_ori | vector Orientation local to the parent (Pitch, Yaw, Roll in degrees) (Optional) |
| force_world_rotation | bool Forces particle's orientation to rotate relative to the world and not with the object (Optional) |
Particle Created particle instance Definition at line 152 of file particle.c.
|
protected |
Method to tell the particle to start playing.
| particle_id | int Particle ID registered in ParticleList to start playing |
Definition at line 203 of file particle.c.
Method to tell the particle to start playing.
| particle_id | int Particle ID registered in ParticleList to start playing |
| flags | int Flags to pass to the playing (None on this level) |
bool Whether the particle successfully started Definition at line 215 of file particle.c.
|
protected |
Helper to get a randomized wiggle float value.
Definition at line 841 of file particle.c.
|
protected |
Helper to get a randomized wiggle vector.
Definition at line 833 of file particle.c.
|
protected |
Sets particle id.
| particle_id | int Particle ID registered in ParticleList to start playing |
Definition at line 285 of file particle.c.
|
protected |
Legacy function for backwards compatibility with 1.14 and below.
Definition at line 266 of file particle.c.
Method to tell the particle to stop playing.
| flags | int Flags to pass to the stopping (None on this level) |
bool Whether the particle successfully stopped Definition at line 245 of file particle.c.
|
protected |
Creates/Destroys ParticleEffect child according to current state.
Definition at line 425 of file particle.c.
|
protected |
Whether this particle repeats.
Definition at line 17 of file particle.c.
|
protected |
Approx. remaining lifetime of particle.
Definition at line 15 of file particle.c.
|
protected |
Parent Object the Particle is child of.
Definition at line 48 of file particle.c.
|
protected |
The child object which contains the actual particle.
Definition at line 50 of file particle.c.
|
protected |
ID from ParticleList if assigned.
Definition at line 13 of file particle.c.
|
protected |
DEPRECATED.
Definition at line 53 of file particle.c.