Emitters

key option type example notes
direction string "none"
"top"
"top-right"
"right"
"bottom-right"
"bottom"
"bottom-left"
"left"
"top-left"
The generated particles direction
life.count number 1 The emitter number of times will appear
life.duration number 5 The emitter life duration, in seconds
life.delay number 0.1 The emitter delay between any appearance
particles object See Particles options here {@link IParticlesOptions}
position object { "x": 50, "y": 50 } The position specified is not absolute, it will be used as a percent value of the canvas size.
size.width number 10
size.height number 10
size.mode string "precise" / "percent" Specify how to use the size values, precise uses pixels, percent will be calculated on canvas size
rate.quantity number 1 The particles generated everytime the rate event occurs
rate.delay number 0.1 The rate event event delay time, in seconds

Implements

Constructors

Properties

autoPlay: boolean

Starts the emitter automatically

direction?: number | "none" | "left" | "top" | "bottom" | "right" | "outside" | "inside" | MoveDirectionAlt | MoveDirection | "bottomLeft" | "bottomRight" | "topLeft" | "topRight"

The direction of the emitted particles, MoveDirection is the enum used for values

domId?: string

Using this id to link the emitter to an HTML element

fill: boolean

Sets if the particles will spawn at the emitter perimeter or inside the area

The emitter life options

name?: string

The emitter name

Particles emitted customization. These settings will overrides other particles settings for the particles emitted by this emitter Particles number options won't override anything, they will be ignored completely

The relative position (in percent) of the emitter, where particles spawns. If size is specified the position will be the center of the size options

The particles emitting rate options

The emitter shape type (circle or square)

The size of the particles emitter area

spawnColor?: AnimatableColor

The particle spawn color

startCount: number

The number of starting particles of the emitter

Methods