View more

View more

View more

### Image of the Day Submit

IOTD | Top Screenshots

### The latest, straight to your Inbox.

Subscribe to GameDev.net Direct to receive the latest updates and exclusive content.

# Angular velocity in direction of linear velocity

Old topic!

Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

2 replies to this topic

### #1mind in a box  Members

Posted 06 November 2013 - 01:39 PM

Hi there!

My situation is the following:

I have a ball, which I can give a kick. When it hits one of of the reflectors in our world I would like it to bounce off at the exact angle it came in. This is working pretty fine so far, but there is the problem of angular velocity.

After the ball hits a reflector it sometimes starts spinning and changes its direction. Therefore I could just set the angular velocity after hitting a reflector to zero, but since this stops the spinning completely it looks very unrealistic.

What I'm looking for now, is a solution of how to get the ball to spin into the exact direction it is reflected to.

Has someone maybe done something similar or just knows what do do here?

Help would be very appreciated.

### #2MaxDZ8  Members

Posted 07 November 2013 - 01:35 AM

I'm not familiar with the behavior you describe. In my tests, balls get bounced correctly and always rolled correctly. In general, you should manipulate dynamic objects by only injecting forces and not by direct velocity manipulation. And you shouldn't have the need to make it bounce manually... are you using kinematics?

Previously "Krohm"

### #3DT....  Members

Posted 08 November 2013 - 06:51 PM

Has someone maybe done something similar or just knows what do do here?

http://en.wikipedia.org/wiki/Angular_velocity

Where:

v = new (or old) linear velocity

r = contact point  -  center of gravity  // If you don't have this info, try using r = contact normal

w = new angular velocity

(I think the eq is backwards.  Just negate it or reverse the cross product.  Also, you may need a coefficient of restitution.)

Old topic!

Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.