Archived

This topic is now archived and is closed to further replies.

dan parker

3d reflection

Recommended Posts

hi, thisis should be real easy to do, but for some reason I cant ge t it to work and its driving me mad! i want to work out the angle of reflection of a ball hitting a flat surface, not taking into account gravity etc.. i have so far tried this, but it doesnt work :0( newDir = oldDir - (planeNorm * (oldDir.dot(planeNorm))*2); anyone offer any help?

Share this post


Link to post
Share on other sites
Actually, that looks pretty good.


Is planenormal a unit vector?

[edited by - gumby on March 4, 2003 1:55:16 PM]

Share this post


Link to post
Share on other sites