diff options
Diffstat (limited to 'core/math/vector2.cpp')
-rw-r--r-- | core/math/vector2.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/core/math/vector2.cpp b/core/math/vector2.cpp index f9c2eeb57d..7d5a051a34 100644 --- a/core/math/vector2.cpp +++ b/core/math/vector2.cpp @@ -122,10 +122,10 @@ Vector2 Vector2::project(const Vector2 &p_to) const { return p_to * (dot(p_to) / p_to.length_squared()); } -Vector2 Vector2::snapped(const Vector2 &p_by) const { +Vector2 Vector2::snapped(const Vector2 &p_step) const { return Vector2( - Math::stepify(x, p_by.x), - Math::stepify(y, p_by.y)); + Math::snapped(x, p_step.x), + Math::snapped(y, p_step.y)); } Vector2 Vector2::clamped(real_t p_len) const { |