diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2022-10-24 16:47:38 +0200 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2022-10-24 16:47:38 +0200 |
commit | 27a04888cfeca3d3db127744dde60b67fe497b94 (patch) | |
tree | 95fdea56cd0832e272ed853c38b5c412c0d6f8c2 /editor/camera.cpp | |
parent | bb17be56d2cd22949bf485c518d543a7e79a6b7d (diff) |
a
Diffstat (limited to 'editor/camera.cpp')
-rw-r--r-- | editor/camera.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/editor/camera.cpp b/editor/camera.cpp index 07dba901..7e9d4870 100644 --- a/editor/camera.cpp +++ b/editor/camera.cpp @@ -8,19 +8,19 @@ namespace floormat { void app::do_camera(float dt) { - if (_keys[key::camera_reset]) + if (keys[key::camera_reset]) reset_camera_offset(); else { Vector2d dir{}; - if (_keys[key::camera_up]) + if (keys[key::camera_up]) dir += Vector2d{0, -1}; - else if (_keys[key::camera_down]) + else if (keys[key::camera_down]) dir += Vector2d{0, 1}; - if (_keys[key::camera_left]) + if (keys[key::camera_left]) dir += Vector2d{-1, 0}; - else if (_keys[key::camera_right]) + else if (keys[key::camera_right]) dir += Vector2d{1, 0}; if (dir != Vector2d{}) |