Answer the question
In order to leave comments, you need to log in
How to set fixed draw speed and world steps in Box2D and SFML?
There is a simple project, Box2D does physics, SFML draws. On different machines with different performance, the speed of the program varies. How to set fixed speed? So what would the speed of the program (movement of objects) be the same on a powerful, medium and weak computer?
Answer the question
In order to leave comments, you need to log in
Start a timer and calculate the time difference between frames. From this difference you are already repelled.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question