diff options
author | David Snopek <dsnopek@gmail.com> | 2024-01-19 07:26:45 -0600 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-01-19 07:26:45 -0600 |
commit | 480a0f8c069576050e192b202248e66976982456 (patch) | |
tree | 75d8dfe291a5da3294552d16525b7fef5a62b528 /include/godot_cpp/variant/aabb.hpp | |
parent | 0ddef6ed96bf1acac408291907d73cdbe69fb58f (diff) | |
parent | 3943e41d2f17a1eef2cdd472333ab1a7585187d8 (diff) | |
download | redot-cpp-480a0f8c069576050e192b202248e66976982456.tar.gz |
Merge pull request #1360 from AThousandShips/aabb_fix
Fix `AABB.encloses` failing on shared upper bound
Diffstat (limited to 'include/godot_cpp/variant/aabb.hpp')
-rw-r--r-- | include/godot_cpp/variant/aabb.hpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/include/godot_cpp/variant/aabb.hpp b/include/godot_cpp/variant/aabb.hpp index dde392b..7706d51 100644 --- a/include/godot_cpp/variant/aabb.hpp +++ b/include/godot_cpp/variant/aabb.hpp @@ -201,11 +201,11 @@ inline bool AABB::encloses(const AABB &p_aabb) const { return ( (src_min.x <= dst_min.x) && - (src_max.x > dst_max.x) && + (src_max.x >= dst_max.x) && (src_min.y <= dst_min.y) && - (src_max.y > dst_max.y) && + (src_max.y >= dst_max.y) && (src_min.z <= dst_min.z) && - (src_max.z > dst_max.z)); + (src_max.z >= dst_max.z)); } Vector3 AABB::get_support(const Vector3 &p_normal) const { |