Aurora
import { Aurora } from 'pixi-silk/glow';
Light rising from the bottom of a box in three colours. The blobs blend additively, so the light
burns to white where it is strongest. A mask clips it to the box. It drifts while speed is not 0
and redraws every blob each frame.
Extends#
Container
Constructors#
Constructor#
new Aurora(options: AuroraOptions): Aurora;
Parameters#
| Parameter | Type |
|---|---|
options | AuroraOptions |
Returns#
Aurora
Overrides#
Container.constructor
Methods#
destroy()#
destroy(options?: DestroyOptions): void;
Removes all internal references and listeners as well as removes children from the display list.
Do not use a Container after calling destroy.
Parameters#
| Parameter | Type | Description |
|---|---|---|
options? | DestroyOptions | Options parameter. A boolean will act as if all options have been set to that value |
Returns#
void
Example#
container.destroy();
container.destroy(true);
container.destroy({ children: true });
container.destroy({ children: true, texture: true, textureSource: true });
Overrides#
Container.destroy
set()#
set(options: Partial<Omit<AuroraOptions, "ticker">>): this;
Merges new colours, rise, speed, size or radius and redraws. The ticker cannot change. Returns this.
Parameters#
| Parameter | Type |
|---|---|
options | Partial<Omit<AuroraOptions, "ticker">> |
Returns#
this
tick()#
tick(dt: number): boolean;
Advances by dt seconds, clamped to 0..0.1, for ticker: null. Returns false when speed is 0.
Parameters#
| Parameter | Type |
|---|---|
dt | number |
Returns#
boolean