a structure provided to all called methods of a Scene.
It provides additional pieces of information and functions, that the Scene can use to operate.
type EngineState struct {
DeltaTime float64
Mouse MouseState
Keyboard KeyboardState
// ...
}
Property | Type | Description |
---|---|---|
DeltaTime |
float64 |
how many seconds have passed since the last Tick (1 = 1 second, .5 = half a second, etc. ) |
Property | Type | Description |
---|---|---|
Mouse |
MouseState |
see Mouse - Input Mouse-Cursor Position and what Buttons are Pressed/Held/Released |
Keyboard |
KeyboardState |
see Keyboard - Input What Keys have been Pressed/Held/Released Also contains history of the last 64 entered characters |
Property | Type | Description |
---|---|---|
Text |
TextDisplay |
Direct access to the Text-Display controlling the UI/Text-Layer |
Map1 |
TileMap |
Direct access to the Map1/Backround TileMap |
Map2 |
TileMap |
Direct access to the Map2/Foreground TileMap |
Function | Description |
---|---|
EnableTextLayer() |
Makes the Text-Layer visible |
DisableTextLayer() |
Make the Text-Layer invisible |
EnableMap2Layer(*core.TileSet) |
Makes the Map2-Layer visible |
DisableMap2Layer() |
Make the Map2-Layer invisible |
EnableSpriteLayer() |
Makes the Sprite-Layer visible |
DisableSpriteLayer() |
Make the Sprite-Layer invisible |
EnableMap1Layer(*core.TileSet) |
Makes the Map1-Layer visible |
DisableMap1Layer() |
Make the Map1-Layer invisible |