diff options
Diffstat (limited to 'core/variant.cpp')
-rw-r--r-- | core/variant.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/core/variant.cpp b/core/variant.cpp index 2e26169bfe..5d48c8785e 100644 --- a/core/variant.cpp +++ b/core/variant.cpp @@ -1607,6 +1607,8 @@ Variant::operator Vector3() const { if (type == VECTOR3) return *reinterpret_cast<const Vector3 *>(_data._mem); + else if (type == VECTOR2) + return Vector3(reinterpret_cast<const Vector2 *>(_data._mem)->x, reinterpret_cast<const Vector2 *>(_data._mem)->y, 0.0); else return Vector3(); } |