mirror of
https://github.com/godotengine/godot.git
synced 2026-01-05 06:11:29 +03:00
Bullet picking will now ignore objects without input_ray_pickable
(cherry picked from commit 7323f7998b)
This commit is contained in:
committed by
Rémi Verschelde
parent
7624e1009a
commit
75f1731232
@@ -51,8 +51,8 @@ bool GodotClosestRayResultCallback::needsCollision(btBroadphaseProxy *proxy0) co
|
||||
if (needs) {
|
||||
btCollisionObject *btObj = static_cast<btCollisionObject *>(proxy0->m_clientObject);
|
||||
CollisionObjectBullet *gObj = static_cast<CollisionObjectBullet *>(btObj->getUserPointer());
|
||||
if (m_pickRay && gObj->is_ray_pickable()) {
|
||||
return true;
|
||||
if (m_pickRay && !gObj->is_ray_pickable()) {
|
||||
return false;
|
||||
} else if (m_exclude->has(gObj->get_self())) {
|
||||
return false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user