diff options
author | Aaron Franke <arnfranke@yahoo.com> | 2019-01-16 10:42:53 -0500 |
---|---|---|
committer | Aaron Franke <arnfranke@yahoo.com> | 2019-04-25 13:20:29 -0400 |
commit | b659e1eb2b732ebc836614735438ca0bcdc8a32d (patch) | |
tree | fdc9e58e4e573c08eb9004650476e43bc66a0e43 /servers/physics_2d | |
parent | c577ec6ae46f8c6d848cae46c0e447e6607b3f33 (diff) |
Use approximate equallity methods in many places
Diffstat (limited to 'servers/physics_2d')
-rw-r--r-- | servers/physics_2d/collision_solver_2d_sat.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/servers/physics_2d/collision_solver_2d_sat.cpp b/servers/physics_2d/collision_solver_2d_sat.cpp index d6c3fff421..f4bff66389 100644 --- a/servers/physics_2d/collision_solver_2d_sat.cpp +++ b/servers/physics_2d/collision_solver_2d_sat.cpp @@ -237,8 +237,8 @@ public: Vector2 axis = p_axis; - if (Math::abs(axis.x) < CMP_EPSILON && - Math::abs(axis.y) < CMP_EPSILON) { + if (Math::is_zero_approx(axis.x) && + Math::is_zero_approx(axis.y)) { // strange case, try an upwards separator axis = Vector2(0.0, 1.0); } |