setContactNormalAcceleration ?

h3x0g3n

30-12-2006 12:55:04

What does setContactNormalAcceleration do exactly?
I've got two objects colliding and want to accelerate one object, so that it ricochete from the other object. Furthermore I want that the resulting normal-speed is always the same, no matter how fast the objects collide or what velocity each one has. Can I achieve this with setContactNormalAcceleration or is it easier otherwise?
Thanks for replies

walaber

30-12-2006 18:57:29

yes. this directly sets the acceleration along the contact normal. you should be able to calculate the desired final velocity, and set the acceleration here to achieve it.

h3x0g3n

31-12-2006 10:18:43

But what exactly means acceleration in this content? Is it the resulting velocity of physics plus the acceleration (velocity) or is it the resulting velocity of physics multiplied with the acceleration or anything else?