Skip to content
On this page

Interface: LayerEvents

game/layers.LayerEvents

All types of events able to be sent or emitted from a layer's emitter.

Properties

postUpdate

postUpdate: (diff: number) => void

Type declaration

▸ (diff): void

Sent every game tick, after the update event. Intended for checking state.

Parameters
NameType
diffnumber
Returns

void

Defined in

profectus/src/game/layers.tsx:61


preUpdate

preUpdate: (diff: number) => void

Type declaration

▸ (diff): void

Sent every game tick, before the update event. Intended for "generation" type actions.

Parameters
NameType
diffnumber
Returns

void

Defined in

profectus/src/game/layers.tsx:57


update

update: (diff: number) => void

Type declaration

▸ (diff): void

Sent every game tick. Intended for "automation" type actions.

Parameters
NameType
diffnumber
Returns

void

Defined in

profectus/src/game/layers.tsx:59