Struct ParticleEmitter
The core particle emitter component. Adding this component to an entity turns the entity into an emitter with the specified characteristics. You can add other components (for example, EmitterInitialScale, EmitterConeSource, and so on) to the same entity after the initial emission to further control how particles are emitted.
Namespace: Unity.Tiny.Particles
Syntax
public struct ParticleEmitter : IComponentData
Fields
attachToEmitter
Specifies whether the Transform of the emitted particles is a child of this emitter.
If true, the emission position is set to the entity's local position, and the particle is added as a child transform.
If false, the emitter's world position is added to the emission position, and that result set as the local position.
Declaration
public bool attachToEmitter
Field Value
Type | Description |
---|---|
System.Boolean |
emitRate
Number of particles per second to emit.
Declaration
public float emitRate
Field Value
Type | Description |
---|---|
System.Single |
lifetime
Lifetime of each particle, in seconds.
Declaration
public Range lifetime
Field Value
Type | Description |
---|---|
Range |
maxParticles
Maximum number of particles to emit.
Declaration
public uint maxParticles
Field Value
Type | Description |
---|---|
System.UInt32 |
particle
Declaration
public Entity particle
Field Value
Type | Description |
---|---|
Entity |