void SetIgnoreCollisionCheck(RigidBodyPtr rigidBody, bool ignore){ auto colObj = dynamic_cast<btCollisionObject*>(rigidBody.get()); assert(colObj); if (ignore){ int i = mSelf->m_objectsWithoutCollisionCheck.findLinearSearch(colObj); if (i == mSelf->m_objectsWithoutCollisionCheck.size()){ mSelf->setIgnoreCollisionCheck(colObj, ignore); } } else{ mSelf->setIgnoreCollisionCheck(colObj, ignore); } }
void SetIgnoreCollisionCheck(RigidBodyPtr rigidBody, bool ignore){ auto colObj = dynamic_cast<btCollisionObject*>(rigidBody.get()); if (mSelf->checkCollideWithOverride(colObj) == ignore){ mSelf->setIgnoreCollisionCheck(colObj, ignore); } }