void ModifyCollisionFlag(int flag, bool enable){ if (enable) { mSelf->setCollisionFlags(mSelf->getCollisionFlags() | flag); } else { mSelf->setCollisionFlags(mSelf->getCollisionFlags() & ~flag); } }
void SetKinematic(bool enable){ if (enable) { int colFlag = mSelf->getCollisionFlags() | CF_KINEMATIC_OBJECT; mSelf->setCollisionFlags(colFlag); } else { int colFlag = mSelf->getCollisionFlags() & ~CF_KINEMATIC_OBJECT; mSelf->setCollisionFlags(colFlag); } }