public bool AddConstraint(BTypedConstraint c) { if (!_isDisposed) { if (m_worldType < WorldType.RigidBodyDynamics) { Debug.LogError("World type must not be collision only"); return(false); } if (debugType >= BDebug.DebugType.Debug) { Debug.LogFormat("Adding constraint {0} to world", c); } if (c._BuildConstraint()) { ((DiscreteDynamicsWorld)m_world).AddConstraint(c.GetConstraint(), c.disableCollisionsBetweenConstrainedBodies); c.m_isInWorld = true; } return(true); } else { return(false); } }
public bool AddConstraint(BTypedConstraint c) { if (!_isDisposed) { Debug.LogFormat("Adding constraint {0} to world", c); if (c._BuildConstraint()) { World.AddConstraint(c.GetConstraint(), c.disableCollisionsBetweenConstrainedBodies); } return(true); } return(false); }
public bool AddConstraint(BTypedConstraint c) { if (!_isDisposed) { if (m_worldType < WorldType.RigidBodyDynamics) { BDebug.LogError(debugType, "World type must not be collision only"); return false; } if (debugType >= BDebug.DebugType.Debug) Debug.LogFormat("Adding constraint {0} to world", c); if (c._BuildConstraint()) { ((DiscreteDynamicsWorld)m_world).AddConstraint(c.GetConstraint(), c.disableCollisionsBetweenConstrainedBodies); c.m_isInWorld = true; } return true; } return false; }
public bool AddConstraint(BTypedConstraint c) { if (!_isDisposed) { Debug.LogFormat("Adding constraint {0} to world", c); if (c._BuildConstraint()) { World.AddConstraint(c.GetConstraint(), c.disableCollisionsBetweenConstrainedBodies); } return true; } return false; }