Skip to main content

Class: TGameState

Defined in: core/game-state.ts:55

Extended by​

Constructors​

Constructor​

new TGameState(engine): TGameState

Defined in: core/game-state.ts:67

Parameters​

engine​

TEngine

Returns​

TGameState

Properties​

created​

created: boolean = false

Defined in: core/game-state.ts:56


events​

events: TEventQueue

Defined in: core/game-state.ts:62

Event queue for the game state which will recieve all events when the state is active.


jobs​

jobs: TJobManager

Defined in: core/game-state.ts:64


postProcessing​

postProcessing: TPostProcessingStack

Defined in: core/game-state.ts:65


world?​

optional world?: TWorld

Defined in: core/game-state.ts:57

Methods​

destroy()​

destroy(): Promise<void>

Defined in: core/game-state.ts:195

Currently only calls destroy on the world which stops the physics worker

Returns​

Promise<void>


getLighting()​

getLighting(): TSerializedLighting

Defined in: core/game-state.ts:112

Returns​

TSerializedLighting


getRenderTasks()​

getRenderTasks(): TSerializedRenderTask[]

Defined in: core/game-state.ts:108

Returns​

TSerializedRenderTask[]