diff options
author | Aaron Franke <arnfranke@yahoo.com> | 2019-08-20 21:12:56 -0400 |
---|---|---|
committer | Aaron Franke <arnfranke@yahoo.com> | 2019-08-27 22:05:18 -0400 |
commit | 34ab6549b112f5a59f7d0ee73e2806ad602af13e (patch) | |
tree | 2ef5d6a0b169032c9b00a362f926e7b56f2db716 /core/math | |
parent | c59da91aad4c73c68e5e2884674f5fb3c3340751 (diff) |
[Mono] Various Color improvements
I also slid in a fix to C++ Vector3 > and >=
Diffstat (limited to 'core/math')
-rw-r--r-- | core/math/vector3.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/core/math/vector3.h b/core/math/vector3.h index 597d3c22a8..c68b075613 100644 --- a/core/math/vector3.h +++ b/core/math/vector3.h @@ -369,8 +369,8 @@ bool Vector3::operator<(const Vector3 &p_v) const { bool Vector3::operator>(const Vector3 &p_v) const { - if (x == p_v.x) { - if (y == p_v.y) + if (Math::is_equal_approx(x, p_v.x)) { + if (Math::is_equal_approx(y, p_v.y)) return z > p_v.z; else return y > p_v.y; @@ -393,8 +393,8 @@ bool Vector3::operator<=(const Vector3 &p_v) const { bool Vector3::operator>=(const Vector3 &p_v) const { - if (x == p_v.x) { - if (y == p_v.y) + if (Math::is_equal_approx(x, p_v.x)) { + if (Math::is_equal_approx(y, p_v.y)) return z >= p_v.z; else return y > p_v.y; |