Typo
This commit is contained in:
parent
4806ac3170
commit
ac29f0267e
1 changed files with 1 additions and 1 deletions
|
@ -23,7 +23,7 @@ object InputReceiver : BaseBehavior<GameContext>() {
|
|||
if (uiEvent is KeyboardEvent) {
|
||||
// We use when which is similar to switch in Java to check which key was pressed.
|
||||
// Zircon has a KeyCode for all keys which can be pressed. when in Kotlin is also an expression,
|
||||
// and not a statement so it returns a value. We can change it into our newPosition variable.
|
||||
// and not a statement, so it returns a value. We can change it into our newPosition variable.
|
||||
|
||||
val newPosition = when (uiEvent.code) {
|
||||
KeyCode.KEY_W -> currentPos.withRelativeY(-1)
|
||||
|
|
Loading…
Reference in a new issue