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/engine/data | |
parent | 9629a8d61e43ba15e87834801f581778625b7a14 (diff) |
fix: index cursor x position from 0
Diffstat (limited to 'src/engine/data')
-rw-r--r-- | src/engine/data/bounds.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/engine/data/bounds.cpp b/src/engine/data/bounds.cpp index ca67008..0cbe9c3 100644 --- a/src/engine/data/bounds.cpp +++ b/src/engine/data/bounds.cpp @@ -32,7 +32,7 @@ auto Bounds::validate_coords(const Vector2 &coords) const noexcept -> CoordsVali return CoordsValidation::X_HIGH; } - if (static_cast<Bounds::Value>(coords.get_x()) <= 0) + if (static_cast<Bounds::Value>(coords.get_x()) < 0) { return CoordsValidation::X_LOW; } @@ -42,7 +42,7 @@ auto Bounds::validate_coords(const Vector2 &coords) const noexcept -> CoordsVali return CoordsValidation::Y_HIGH; } - if (static_cast<Bounds::Value>(coords.get_y()) <= 0) + if (static_cast<Bounds::Value>(coords.get_y()) < 0) { return CoordsValidation::Y_LOW; } |