context

package
v0.1.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 15, 2023 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GameplayContext

type GameplayContext struct {
	CurrentFrameTicks       uint64
	PreviousFrameTicks      uint64
	DeltaTicks              uint64
	Paused                  bool
	CurrentScene            string
	KeysPressed             []sdl.Scancode
	ControllerButtonPressed []sdl.GameControllerButton
	GameController          *sdl.GameController
}

func NewGameplayContext

func NewGameplayContext(controller *sdl.GameController) *GameplayContext

func (*GameplayContext) IsKeyPressed

func (context *GameplayContext) IsKeyPressed(scancode sdl.Scancode, includeHeldKey bool) bool

func (*GameplayContext) StartNewFrame

func (context *GameplayContext) StartNewFrame()

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL