The single particle object

Constructors

Properties

_calcPosition: ((container, position, zIndex, tryCount?) => Vector3d) = ...

Type declaration

_calculateVelocity: (() => Vector) = ...

Type declaration

_checkOverlap: ((pos, tryCount?) => boolean) = ...

Type declaration

    • (pos, tryCount?): boolean
    • Parameters

      Returns boolean

_engine: Engine

Gets the particle containing engine instance

_getRollColor: ((color?) => undefined | IHsl) = ...

Type declaration

    • (color?): undefined | IHsl
    • Parameters

      • Optional color: IHsl

      Returns undefined | IHsl

_initPosition: ((position?) => void) = ...

Type declaration

    • (position?): void
    • Parameters

      Returns void

backColor?: IHsl

Particles back color

Gets particles bubble data

Gets the particle color options

container: Container
destroyed: boolean

Checks if the particle is destroyed

direction: number

Gets particle direction, the value is an angle in rad

effect: string

Gets particle effect type

effectClose: boolean

Checks if the particle effect needs a closed path

effectData?: IShapeValues

Gets particle effect options

effectFill: boolean

Checks if the particle effect needs to be filled with a color

group?: string
id: number
ignoresResizeRatio: boolean

When this is enabled, the particle won't resize when the canvas resize event is fired

initialPosition: Vector

Gets particle initial position

initialVelocity: Vector

Gets particle initial velocity

interactivity: Interactivity
lastPathTime: number

Last path timestamp

misplaced: boolean

Check if the particle needs a fix on the position

moveCenter: ICenterCoordinates
moveDecay: number

Gets particle movement speed decay

offset: Vector

Gets particle offset position, used for parallax interaction

Gets the particle opacity options

Gets the particle options

pathDelay: number

Gets the delay for every path step

pathGenerator?: IMovePathGenerator

Gets the particle's path generator

pathRotation: boolean

Gets if the particle should rotate with path

position: Vector3d

Gets particle current position

randomIndexData?: number

The random index used by the particle

Gets the particle retina values

Gets the particle roll options

rotation: number

Gets the particle rotation angle

shadowColor?: IRgb

Gets particle shadow color

shape: string

Gets particle shape type

shapeClose: boolean

Checks if the particle shape needs a closed path

shapeData?: IShapeValues

Gets particle shape options

shapeFill: boolean

Checks if the particle shape needs to be filled with a color

sides: number

Gets the particle side count

Gets particle size options

spawning: boolean

Check if the particle is spawning, and can't be touched

strokeColor?: IParticleHslAnimation

Sets the particle stroke color

strokeOpacity?: number

Sets the particle stroke opacity

strokeWidth?: number

Sets the particle stroke width

unbreakable: boolean

Checks if the particle is unbreakable, if true the particle won't destroy on collisions

velocity: Vector

Gets particle current velocity

zIndexFactor: number

Gets the particle Z-Index factor

Methods

  • Parameters

    • Optional override: boolean

    Returns void

  • This method is used when the particle has lost a life and needs some value resets

    Returns void