summaryrefslogtreecommitdiff
path: root/core/math/transform_2d.cpp
diff options
context:
space:
mode:
authorAnilforextra <anilforextra@gmail.com>2021-09-06 12:17:50 +0545
committerAnilforextra <anilforextra@gmail.com>2021-09-07 08:30:26 +0545
commita1f616dcfc9b4efa08a5e69e1b979ea7911dc1f8 (patch)
treec4e66098d479a7fe22ca4fcc89a211fdd6ec69c8 /core/math/transform_2d.cpp
parentc97afc033f720a68b3ea8dabb2956d836d13613e (diff)
Use builtin Vector2 functions for calculation of angles.
.
Diffstat (limited to 'core/math/transform_2d.cpp')
-rw-r--r--core/math/transform_2d.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/math/transform_2d.cpp b/core/math/transform_2d.cpp
index 16934d67df..e4f1626646 100644
--- a/core/math/transform_2d.cpp
+++ b/core/math/transform_2d.cpp
@@ -271,7 +271,7 @@ Transform2D Transform2D::interpolate_with(const Transform2D &p_transform, real_t
}
//construct matrix
- Transform2D res(Math::atan2(v.y, v.x), p1.lerp(p2, p_c));
+ Transform2D res(v.angle(), p1.lerp(p2, p_c));
res.scale_basis(s1.lerp(s2, p_c));
return res;
}