Jump to content

  • Log In with Google      Sign In   
  • Create Account


softdev

Member Since 18 Mar 2012
Offline Last Active Mar 18 2012 11:34 PM
-----

Posts I've Made

In Topic: How would you simulate gun recoil in a FPS ?

18 March 2012 - 11:08 PM

By the looks of the plot in the link you provided, the curve looks right to what you said. I changed the 5 in the exponent to 9 and got the spike I think you are referring to. To cut a long story short, unless you have a downward force applied through whatever physics engine you use, it won't work. However it works perfectly fine if you simply limit the y with whatever you get for the result. So each gun can have a different limit. This would be up to you and how you are processing the recoil. Don't change the curve, the algorithm is fine. Just don't forget, that if you later want to use more accurate physics for the character (ie. 3rd person view), you are getting a visual translation as opposed to a gravity calculation.

PARTNERS