diff options
author | HampusM <hampus@hampusmat.com> | 2022-06-07 14:49:51 +0200 |
---|---|---|
committer | HampusM <hampus@hampusmat.com> | 2022-06-13 17:57:01 +0200 |
commit | f778317bae709f397345a2d5e04e23864c6391b3 (patch) | |
tree | 9936789cd1d6b76ce7d41d6867e6887c18f28c14 /src/game/game.cpp | |
parent | 9629a8d61e43ba15e87834801f581778625b7a14 (diff) |
fix: index cursor x position from 0
Diffstat (limited to 'src/game/game.cpp')
-rw-r--r-- | src/game/game.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/game/game.cpp b/src/game/game.cpp index 2eef4cf..064b643 100644 --- a/src/game/game.cpp +++ b/src/game/game.cpp @@ -285,6 +285,11 @@ auto Game::_move_cursor(const Vector2 &direction) noexcept -> bool return false; } + if (dest_position.get_y() < 1) + { + return false; + } + _cursor_controller->move_to(dest_position); return true; |