public static void AttachConstraint(this IConstraintContainer world, TypedConstraint typedConstraint) { ConstraintCustomData cd = new ConstraintCustomData(world.GetNewConstraintId()); typedConstraint.UserObject = cd; world.Register(typedConstraint); }
public void RemoveConctraint(TypedConstraint cst, ConstraintCustomData cdata) { this.dynamicsWorld.DeleteAndDisposeConstraint(cst); if (this.ConstraintDeleted != null) { this.ConstraintDeleted(cst, cdata.Id); } }