[ODE] Slow down sphere

aldoric@gmx.de aldoric at gmx.de
Tue Aug 22 14:29:42 MST 2006


I've got a sphere and a trimesh (as world). I want the sphere to get slower if the ball is on a flat part of it (or of anything).

My first solution was something like that:

vel = (dReal*)dBodyGetLinearVel(ballBody);
vel[0] *= 0.994f;
vel[1] *= 0.994f;
vel[2] *= 0.994f;
vel = (dReal*)dBodyGetAngularVel(ballBody);
vel[0] *= 0.994f;
vel[1] *= 0.994f;
vel[2] *= 0.994f;

The problem is, that this solution doesn't work very fine for everything else than flat grounds.

Is there another solution for that?

Thanks :)

Der GMX SmartSurfer hilft bis zu 70% Ihrer Onlinekosten zu sparen!
Ideal für Modem und ISDN: http://www.gmx.net/de/go/smartsurfer

More information about the ODE mailing list