Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> For many games variable timestep is a good choice.

It really isn't.



You can use fixed time step. Choice is yours.


What's funny is that searching for "cute framework fixed timestep" in Google points to this Hacker News thread as the first result. What I would have wanted to find is this page:

https://randygaul.github.io/cute_framework/#/topics/game_loo...


Very sorry about that :D


LOL


If you divorce the game's time-step from your math it isn't too much of an issue. You just need to keep track of the time-delta so you have it for your calculations.


Gaffer has summarized most of this quite well years ago. E.g. https://gafferongames.com/post/fix_your_timestep/


Care to elaborate?


https://randygaul.github.io/cute_framework/#/topics/game_loo...

You can request a fixed timestep, and your own loop callback will be called at fixed intervals, which allows you to completely ignore delta time.


Assuming the timestep refers to the parts of code dealing with game logic updates, such as physics or motion, variable-sized steps tend to cause nasty issues. Collision detection is an example, where variability is undesired.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: