MCPcopy
hub / github.com/EngoEngine/engo / Setup

Method Setup

demos/input/input.go:16–24  ·  view source on GitHub ↗
(u engo.Updater)

Source from the content-addressed store, hash-verified

14
15func (*DefaultScene) Preload() {}
16func (*DefaultScene) Setup(u engo.Updater) {
17 w, _ := u.(*ecs.World)
18
19 w.AddSystem(&common.RenderSystem{})
20 w.AddSystem(&InputSystem{})
21
22 engo.Input.RegisterAxis("sideways", engo.AxisKeyPair{engo.KeyA, engo.KeyD})
23 engo.Input.RegisterButton("action", engo.KeySpace, engo.KeyEnter)
24}
25
26func (*DefaultScene) Type() string { return "Game" }
27

Callers

nothing calls this directly

Calls 2

RegisterAxisMethod · 0.80
RegisterButtonMethod · 0.80

Tested by

no test coverage detected