From what I've been able to get out of btGeneric6DofSpringConstraint, it seems that it only allows rotation at one end. In order to try to solve this, I've added a 'dummy' object inside of my two anchor points, attached these dummy objects to the intended spring anchor points with btPoint2PointConstraints, and using the following code to make the dummy objects not participate in collision
Code: Select all
bodyFirst->setCollisionFlags(bodyFirst->getCollisionFlags() | btCollisionObject::CF_NO_CONTACT_RESPONSE);
My questions are the following:
Is there an easy way to accomplish a distance-based spring? Whether I need to compute the forces myself or not, I don't mind.
Should the method I'm using actually work?
Thank you all!