From 606cfa9a47a945eefa6e4f2cf64599af9f0157ab Mon Sep 17 00:00:00 2001 From: Tomasz Chabora Date: Sun, 25 Oct 2020 13:24:08 +0100 Subject: Fix Vector2.angle_to_point() being reversed --- core/math/vector2.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'core/math/vector2.cpp') diff --git a/core/math/vector2.cpp b/core/math/vector2.cpp index 6259bdead0..1d3f93848e 100644 --- a/core/math/vector2.cpp +++ b/core/math/vector2.cpp @@ -79,7 +79,7 @@ real_t Vector2::angle_to(const Vector2 &p_vector2) const { } real_t Vector2::angle_to_point(const Vector2 &p_vector2) const { - return (*this - p_vector2).angle(); + return (p_vector2 - *this).angle(); } real_t Vector2::dot(const Vector2 &p_other) const { -- cgit v1.2.3