0

How can I get the velocity of a rigid body on impact so that I can add sound effects?

B-A: if I get the velocity right before impact by comparing the last two frames before the z component switches direction (negative/positive), then it will be too high.

C-B: if I get the velocity before and after impact by comparing the frames before the z component switches direction (negative/positive) with the frame after the z component switches direction, then it will be too low.

D-C: if I get the velocity right after impact by comparing the next two frames after the z component switches direction (negative/positive), then it will be too high.

A rigid body simluation doesn't always have a frame that's touching on the floor, so I have left it unlabelled.

wjwrpoyob
  • 123
  • 4

0 Answers0