(keycode sdl.Keycode)
| 113 | } |
| 114 | |
| 115 | func (keyboard Keyboard) Key(keycode sdl.Keycode) *InputState { |
| 116 | |
| 117 | if _, exists := keyboard.KeyState[keycode]; !exists { |
| 118 | keyboard.KeyState[keycode] = &InputState{} |
| 119 | } |
| 120 | |
| 121 | return keyboard.KeyState[keycode] |
| 122 | |
| 123 | } |
| 124 | |
| 125 | func (keyboard Keyboard) HeldKeys() []sdl.Keycode { |
| 126 | inputs := []sdl.Keycode{} |
no outgoing calls
no test coverage detected