[ODE] These weird numbers make me crazy

Marco Bancale F104 at softhome.net
Sat Feb 8 11:43:01 2003


Hi all!

I'm getting crazy... I make this:

dBodySetLinearVel(body, 2, 2, 0);
dWorldStep(...);
dBodyGetLinearVel(body);

and the result is (463728574628.46837, -473828298.0, 0)
It's just an example. Actually the result is random.
Why?!!??! I've read that setting directly the linear velocity is not
a good idea and I should use a force. I tried, but the result is the
same.
The weird thing (besides the values) is that the simulation runs fine
and the game too. But I need to get these values to make some check and
graphic effect. How can I do?

I've also read on the docs there are "motor joints", but I didn't
understand what they are. Maybe I should use them?

My game is a kind of pool game... so the question is:
how should you implement the code to shoot the ball? Applying directly
a linear velocity (as I do)? Adding a force? Using a "motor joint"?

Last little question: when I use dBodyGetLinearVel() the resulting
values are referred to the world or to the body system?

Please help!

Thank you!

	Bye Bye
	F104/NA