newVelocity = oldVelocity - oldVelocity * friction * elapsedTime
The results are not consistent between 60 Hz and 30 Hz. But then I thought about how continuous compound interest is calculated, and I came up with this:
newVelocity = oldVelocity * exp(-friction * elapsedTime)
It works perfectly, at least on paper. Has anyone else ever used an approach like this? Or is there a better way to do it?
Edit: I should mention that the game is using a fixed time step. At 30 Hz it's 1/30 seconds and at 60 Hz it's 1/60.
Edited by BradDaBug, 28 April 2012 - 07:24 PM.