[ODE] One Body AMotors

Timothy Wayper timmy at wunderbear.com
Sat Oct 25 15:39:43 MST 2003


Hi there,

I'm replacing the problematic custom physics engine in a game I'm 
writing with ODE at the moment, and I'd like to limit the rotation of 
some bodies to one dimension. Well, not quite, but I'd at least like to 
be able to provide a "balance" torque to stop characters falling over, 
while allowing controlled "foot" rotation.

My attempted solution was to connect an AMotor between the body and the 
"ether". One axis of the AMotor would provide directional control, the 
other two would resist topple. This seems to make sense to me, but now 
I've tried it I see that AMotors must be connected between two real 
bodies. Ie, dJointAttach(joint, body, 0) fails.

Am I going about this totally the wrong way? One solution I can imagine 
is to connect an AMotor between the character's body and a "dummy" 
body, then fix the dummy body to the static environment. Is this 
feasible? Any alternative suggestions?

Cheers,
Tim Wayper



More information about the ODE mailing list