diff options
Diffstat (limited to 'core/math/vector3.h')
-rw-r--r-- | core/math/vector3.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/core/math/vector3.h b/core/math/vector3.h index 5fc412628f..3e35a5bba2 100644 --- a/core/math/vector3.h +++ b/core/math/vector3.h @@ -256,6 +256,7 @@ Vector3 &Vector3::operator-=(const Vector3 &p_v) { z -= p_v.z; return *this; } + Vector3 Vector3::operator-(const Vector3 &p_v) const { return Vector3(x - p_v.x, y - p_v.y, z - p_v.z); } @@ -266,6 +267,7 @@ Vector3 &Vector3::operator*=(const Vector3 &p_v) { z *= p_v.z; return *this; } + Vector3 Vector3::operator*(const Vector3 &p_v) const { return Vector3(x * p_v.x, y * p_v.y, z * p_v.z); } |