From 17c391b429145e01cbcc5744abb391c25e082dfb Mon Sep 17 00:00:00 2001 From: Erwin Coumans Date: Fri, 3 Oct 2008 21:42:19 +0000 Subject: bugfix: add Ghost support for soft bodies, so that they don't collide with ghosts, and can be ghost themselves. --- extern/bullet2/src/BulletSoftBody/btSoftBody.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'extern') diff --git a/extern/bullet2/src/BulletSoftBody/btSoftBody.cpp b/extern/bullet2/src/BulletSoftBody/btSoftBody.cpp index 0a27dbcedb5..1604167b6ef 100644 --- a/extern/bullet2/src/BulletSoftBody/btSoftBody.cpp +++ b/extern/bullet2/src/BulletSoftBody/btSoftBody.cpp @@ -2439,6 +2439,10 @@ void btSoftBody::PSolve_RContacts(btSoftBody* psb,btScalar kst,btScalar ti) for(int i=0,ni=psb->m_rcontacts.size();im_rcontacts[i]; + ///skip object that don't have collision response + if (!psb->getWorldInfo()->m_dispatcher->needsResponse(psb,c.m_cti.m_body)) + continue; + const sCti& cti=c.m_cti; const btVector3 va=cti.m_body->getVelocityInLocalPoint(c.m_c1)*dt; const btVector3 vb=c.m_node->m_x-c.m_node->m_q; -- cgit v1.2.3