The Angular Motor (AMotor) joint is what you want. It constraints
1. Attach between the body and the world.
2. Set it to Euler mode.
3. Set the first axis to (1,0,0), anchored on body 1.
4. Set the thrid axis to (0,0,1), anchored to the world.
5. Constrain both first and third axis to stop rotations.
dJointID j = dJointCreateAMotor(world, 0);
dJointAttach(j, body, 0);
dJointSetAMotorAxis(j, 0, 1, 1, 0, 0);
dJointSetAMotorAxis(j, 2, 0, 0, 1, 0);
dJointSetAMotorParam(j, dParamLoStop, 0);
dJointSetAMotorParam(j, dParamHiStop, 0);
dJointSetAMotorParam(j, dParamLoStop3, 0);
dJointSetAMotorParam(j, dParamHiStop3, 0);
I found out why your capsule test is not working. It is a problem with the length and the radius of the capsule. You have to think of the capsule as a cylinder which has half a sphere added on both ends, so I calculate the radius of the capsule as it's "X" size and the length is it's "Z" size and two times the radius is subtracted. In your case this brought out a negative length, and ODE doesn't like that. I got it running by changing the Capsule Node's scale to
I'm not sure what you are saying? In the links I sent, you mentioned ODE hates negatives. Now it sounds like you are saying it "should" work ? I know your busy, trust me, I know busy but I have no clue where to begin here. Regardless, there is a bug in irrODE as myself and one other guy has discovered. Based on the info I submitted do you have any suggestions ?I think (although I don't use capsules myself) that you still get a negative value (1.5 - 2*1.0 = -0.5).
Users browsing this forum: soulless and 0 guests