|
|
|
|
|
by bruce343434
5 days ago
|
|
The accumulator pattern keeps simulations stable in the face of variable frame rate. Accumulate the frame dt into an accum variable. If accum>fixed_physics_dt then step_physics until false. I'm assuming the author did something like that because it's standard practise. https://www.gafferongames.com/post/fix_your_timestep/ |
|
That is one place where an analytical solution is a benefit, even if it is a bit less realistic. You just have a position(t) parametric function you can evaluate when rendering sporadically.