class ParticleSourceSource
ParticleSource › Particle › ParticleBase › Entity › ObjectTyped › Object › IEntity › Managed
All members, including inherited
Entity which has the particle instance as an ObjectComponent
Constructors 2
void ~ParticleSource()dtor
Methods 73
override protected void ParticleInit()Empty - Only needed for Particle
proto native void SetParticleAutoDestroyFlags(ParticleAutoDestroyFlags flags)Enables the particle to automatically clean up itself when ending or stopping
flagsParticleAutoDestroyFlagsFlags enabling when the particle should be auto destroyed
void DisableAutoDestroy()Disables the particle automatically cleaning up itself when ending or stopping
proto native int GetParticleAutoDestroyFlags()Gets the currently set ParticleAutoDestroyFlags flags set on this ParticleSource
Returns: int Currently set ParticleAutoDestroyFlags flags set on this ParticleSource
static ParticleSource CreateParticle(int id, vector pos, bool playOnCreation = false, Object parent = null, vector ori = vector.Zero, bool forceWorldRotation = false, Class owner = null)Create function
idintParticle ID registered in ParticleListposvectorPosition of ParticleSource in LS (WS when no parent)playOnCreationboolWhether to play immediately after creation (Optional)parentObjectParent Object which will child the ParticleSource (Optional)orivectorOrientation of ParticleSource in LS (WS when no parent) (Pitch, Yaw, Roll in degrees) (Optional)forceWorldRotationboolForces orientation to rotate relative to the world and not with the parent (Optional)ownerClassThe owning instance for this particle (Optional)
Returns: ParticleSource Created particle instance when successful
static ParticleSource CreateParticleEx(int id, vector pos, int flags = ParticlePropertiesFlags.NONE, Object parent = null, vector ori = vector.Zero, Class owner = null)Master create function
idintParticle ID registered in ParticleListposvectorPosition of ParticleSource in LS (WS when no parent)flagsintSee ParticlePropertiesFlags (Optional)parentObjectParent Object which will child the ParticleSource (Optional)orivectorOrientation of ParticleSource in LS (WS when no parent) (Pitch, Yaw, Roll in degrees) (Optional)ownerClassThe owning instance for this particle (Optional)
Returns: ParticleSource Created particle instance when successful
override 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
particle_idintParticle ID registered in ParticleListparent_objObjectInstance on which this particle will be attachedlocal_posvectorAttachment position local to the parent (Optional)local_orivectorOrientation local to the parent (Pitch, Yaw, Roll in degrees) (Optional)force_world_rotationboolForces particle's orientation to rotate relative to the world and not with the object (Optional)
Returns: Particle Created particle instance
override 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
override 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
particle_idintParticle ID registered in ParticleListglobal_posVectorPosition where the particel will be createdglobal_orivectorOrientation (Pitch, Yawn, Roll in degrees) (Optional)force_world_rotationboolHas absolutely no effect here as there is no parent
Returns: Particle Created particle instance
override static ParticleSource Create(int particle_id, vector global_pos, vector global_ori = "0 0 0")Legacy function for backwards compatibility with 1.01 and below
override 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
particle_idintParticle ID registered in ParticleListparent_objObjectInstance on which this particle will be attachedlocal_posvectorAttachment position local to the parent (Optional)local_orivectorOrientation local to the parent (Pitch, Yaw, Roll in degrees) (Optional)force_world_rotationboolForces particle's orientation to rotate relative to the world and not with the object (Optional)
Returns: Particle Created particle instance
override 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
Creates a particle emitter on the given position and activates it
particle_idintParticle ID registered in ParticleListglobal_posVectorPosition where the particel will be created
Returns: Particle Created particle instance
Legacy function for backwards compatibility with 1.01 and below
Method to tell the particle to start playing
Returns: bool Whether the particle successfully started
Method to tell the particle to start playing
particle_idintParticle ID registered in ParticleList to start playing
Returns: bool Whether the particle successfully started
Method to tell the particle to stop playing
flagsintFlags to pass to the stopping (StopParticleFlags)
Returns: bool Whether the particle successfully stopped
Method to tell the particle to stop playing
flagsintFlags to pass to the stopping (StopParticleFlags)
Returns: bool Whether the particle successfully stopped
private proto native bool ResetParticleNative()Method to tell the particle to reset
Returns: bool Whether the particle successfully reset
override bool ResetParticle()Method to tell the particle to reset
Returns: bool Whether the particle successfully reset
private proto native bool RestartParticleNative()Method to tell the particle to restart (reset + play)
Returns: bool Whether the particle successfully restarted
override bool RestartParticle()Method to tell the particle to restart (reset + play)
Returns: bool Whether the particle successfully restarted
private proto bool IsParticlePlayingNative()Ask if the particle is still playing
Returns: bool Whether the particle is playing
override bool IsParticlePlaying()Ask if the particle is still playing
Returns: bool Whether the particle is playing
Assigns a particle to the ParticleSource
pathstringPath of particle effect
Returns: bool Whether the creating and assigning of particle was successful
Assigns a particle to the ParticleSource
pathstringPath of particle effect
Returns: bool Whether the creating and assigning of particle was successful
Assigns a particle to the ParticleSource
idintID of particle registered in ParticleList
Returns: bool Whether the creating and assigning of particle was successful
override void SetSource(int particle_id)Sets particle id
particle_idintParticle ID registered in ParticleList to start playing
private proto bool GetParticleNative(out string path, EGetParticleMode mode)Gets the path to the currently assigned particle
pathstringPath of particle effectmodeEGetParticleModeWhat path to return
Returns: bool Whether the path is filled in or not
bool GetParticle(out string path, EGetParticleMode mode)Gets the path to the currently assigned particle
pathstringPath of particle effectmodeEGetParticleModeWhat path to return
Returns: bool Whether the path is filled in or not
override int GetParticleID()Gets the ParticleList ID of the currently assigned particle
Returns: int ID of particle registered in ParticleList
int GetParticleIDLegacy()Gets the ParticleList ID of the currently assigned particle
Returns: int ID of particle registered in ParticleList
private proto native bool ApplyPropertiesNative(ParticleProperties properties)Applies the properties given to the ParticleSource
propertiesParticlePropertiesThe properties to apply
Returns: bool Whether the properties were successfully applied
bool ApplyProperties(ParticleProperties properties)Applies the properties given to the ParticleSource
propertiesParticlePropertiesThe properties to apply
Returns: bool Whether the properties were successfully applied
override Object GetDirectParticleEffect()override Object GetParticleParent()private proto bool HasActiveParticleNative()Returns if there is any particle active
Returns: bool Whether there is any particle active
override bool HasActiveParticle()Returns if there is any particle active
Returns: bool Whether there is any particle active
private proto int GetParticleCountNative()Returns the total count of active particles in all emitors
Returns: int Total count of active particles
override int GetParticleCount()Returns the total count of active particles in all emitors
Returns: int Total count of active particles
private proto bool IsRepeatNative()Returns whether there is a repeating particle
Returns: bool whether there is a repeating particle
override bool IsRepeat()Returns whether there is a repeating particle
Returns: bool whether there is a repeating particle
private proto float GetMaxLifetimeNative()Returns the approx. max lifetime
Returns: float The largest lifetime sum among the emitors
override float GetMaxLifetime()Returns the approx. max lifetime
Returns: float The largest lifetime sum among the emitors
proto native Class GetOwner()Get the owner of this ParticleSource
Returns: Class The owner or null
proto native void SetOwner(Class owner)Set the owner of this ParticleSource
ClassThe owner or null
proto native void Orphan()null the owner of this ParticleSource
proto native ParticleManager GetParticleManager()Get the ParticleManager the ParticleSource belongs to if any
Returns: ParticleManager The ParticleManager which created the ParticleSource or null
proto native int GetIndex()Get the index of this ParticleSource in the owning ParticleManager
Returns: int The index in the pool in the owning ParticleManager, -1 if no owner
proto int GetCountID()Gets the ID for the ParticleSource
Returns: int ID for the ParticleSource
proto native static int GetStaticCount()Gets the amount of ParticleSource that have been created since the start of the program
Returns: int Amount of ParticleSource that have been created since the start of the program
proto native static int GetStaticActiveCount()Gets the amount of ParticleSource that are currently existing
Returns: int Amount of ParticleSource that are currently existing
override protected void OnParticleParented(IEntity parent)Event when the particle receives a parent
override protected void OnParticleUnParented(IEntity parent)Event when the particle is orphaned
override protected void OnParticleStop()Event when the particle stops
Show 1 more
, Particle.m_RandomizeOrioverride void AddAsChild(Object parent, vector local_pos = "0 0 0", vector local_ori = "0 0 0", bool force_rotation_to_world = false)Attaches this particle onto some object. If null value is provided then the particle will be detached from the current parent.
parentObjectParent onto which this particle will be attachedlocal_posvectorAttachment position local to the parent (optional)local_orivectorOrientation local to the parent (Pitch, Yawn, Roll in degrees) (Optional)force_rotation_to_worldboolForce rotation to be in WS (Optional)
Set the value of a parameter of all emitors in the particle
parameterintThe parameter to apply the new value to (enum EmitorParam)valuefloatThe value to apply
Set the value of a parameter of an emitor in the particle
emitterintThe emitter to apply the new value to, -1 for all emitterparameterintThe parameter to apply the new value to (enum EmitorParam)valuefloatThe value to apply
Get the value of a parameter of an emitor in the particle
emitterintThe emitor to get the value fromparameterintThe parameter to get the value from (enum EmitorParam)valuefloatThe value
Get the value of a parameter of an emitor in the particle
emitterintThe emitor to get the value fromparameterintThe parameter to get the value from (enum EmitorParam)
Returns: float The value
Scales the given parameter on all emitors relatively to their ORIGINAL value.
parameter_idintThe parameter to adjust (enum EmitorParam)coeffloatThe multiplier to apply
Scales the given parameter on all emitors relatively to their CURRENT value.
parameter_idintThe parameter to adjust (enum EmitorParam)coeffloatThe multiplier to apply
Increments the value of the given parameter relatively from the ORIGINAL value.
parameter_idintThe parameter to adjust (enum EmitorParam)valuefloatThe value to sum
Increments the value of the given parameter relatively from the CURRENT value.
parameter_idintThe parameter to adjust (enum EmitorParam)valuefloatThe value to sum
Makes the particle change direction by random_angle every random_interval seconds.
random_anglefloatWill be the range [-random_angle, random_angle[ to wiggle betweenrandom_intervalfloatWill be the time range [0, random_interval] to wiggle next time
Show 12 more
, IEntity.GetYawPitchRoll(), IEntity.IsHierarchyPositionOnly(), Particle.IsWiggling(), Particle.SetWiggle(), IEntity.Update(), Particle.m_DefaultOri, Particle.m_DefaultPos, Particle.m_DefaultWorldOri, Particle.m_DefaultWorldPos, Particle.m_ForceOrientationRelativeToWorld, Particle.m_MaxOriInterval, and Particle.m_MaxOriWiggleoverride void StopWiggle()Stops randomized wiggle
override private void RandomizeOrientation()Randomizes a new orientation and applies it