Creates a new Emitter instance.
The scene the emitter belongs to.
Additional properties for the emitter.
Whether the object is active and should be updated
The angle to emit the particles.
How much to dampen particle angular speed.
The object's angular velocity
Optional
animationThe animation of the object sprite.
Whether the object is bounded by the scene and cannot move outside.
Whether particles collide against objects.
Whether particles collide against tiles.
Optional
colorThe color of the object (if no sprite).
The color at the end of the particle's life. It is randomized between end colors.
The color at the start of the particle's life. It is randomized between start colors.
How much to dampen particle speed.
Whether the object is dead and should be removed
The object's elasticity (0-1)
The local angle to apply velocity to particles from the emitter.
How many particles per second to spawn. If set to 0, no particles will be emitted.
The size of the emitter. It can be a float for circle diameter or a vec2 for rectangle dimensions.
How long the emitter stays alive (0 is forever).
How quickly particles fade in at the start/end in percent of life.
Optional
familyThe family of the object.
Whether the object is flipped horizontally (mirrored)
Whether the object is flipped vertically
The force applied to the object (acceleration)
The object's friction (0-1)
Optional
gidThe global ID of the object image from TMX map (if any).
How much gravity affects particles.
The ID of the object.
Optional
imageThe image of the object (if any).
Last position of the object
Optional
layerThe layer ID of the object (if any).
The object's mass (0 is static)
Maximum speed
Optional
nameThe name of the object.
Additional properties for the emitter.
The object the entity is standing on
The cone for the start particle angle.
The position of the emitter.
Custom properties of the object
The randomness percent.
The render order of particles.
The scene the emitter belongs to.
The shape of the particle.
The size of the object (scaled by tileSize)
The size of particles at the end.
The size of particles at the start.
Whether the object is solid and collides with other objects
Time the entity was spawned
The speed of particles when spawned.
The sprite of the object.
If set, the particle is drawn as a trail, stretched in the direction of velocity.
Time buffer for emit rate.
How long particles live.
The type of the emitter.
Whether the object is visible and should be drawn
Applies a force to the entity (affected by mass)
The force to be applied.
Checks if this entity collides with another entity.
The entity to check collision with.
true
if a collision occurs, false
otherwise.
Checks if the entity collides with a tile.
The ID of the tile to check collision with.
The position of the entity.
True if the entity collides with the tile, false otherwise.
Checks if the entity collides with a tile using raycasting.
The data of the tile to check collision with.
The position of the entity.
True if the entity collides with the tile, false otherwise.
Sets the animation for the entity.
The animation to set.
(Optional) Whether to flip the animation horizontally. Default is false.
(Optional) Whether to flip the animation vertically. Default is false.
Represents an emitter object that spawns particles in a scene.