diff options
author | Juan Linietsky <reduzio@gmail.com> | 2018-11-28 11:16:06 -0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-11-28 11:16:06 -0300 |
commit | db595980bf1d996db361c04541f0ac88e4a6e4b7 (patch) | |
tree | 585055606b956f246887bf78ba755a69876152e8 | |
parent | 348708cad30c2fa60e7bba6d62f0104c56fb9e1c (diff) |
Revert "Construct Transform from Transform2D "
-rw-r--r-- | core/variant.cpp | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/core/variant.cpp b/core/variant.cpp index 7a84c953d4..edbe66ba31 100644 --- a/core/variant.cpp +++ b/core/variant.cpp @@ -1662,17 +1662,7 @@ Variant::operator Transform() const { return Transform(*_data._basis, Vector3()); else if (type == QUAT) return Transform(Basis(*reinterpret_cast<const Quat *>(_data._mem)), Vector3()); - else if (type == TRANSFORM2D) { - const Transform2D &t = *_data._transform2d; - Transform m; - m.basis.elements[0][0] = t.elements[0][0]; - m.basis.elements[1][0] = t.elements[1][0]; - m.basis.elements[0][1] = t.elements[0][1]; - m.basis.elements[1][1] = t.elements[1][1]; - m.origin[0] = t.elements[2][0]; - m.origin[1] = t.elements[2][1]; - return m; - } else + else return Transform(); } |