Add a fixed update method to Engine and Entity class which attempts to maintain roughly 60fps, regardless of the current frame rate. If the browser FPS dips below, it should repeat N times, if it goes above, it should skip frames. The method could be used for physics or other simulations where accuracy is not critical, but good enough will suffice.
Add a fixed update method to Engine and Entity class which attempts to maintain roughly 60fps, regardless of the current frame rate. If the browser FPS dips below, it should repeat N times, if it goes above, it should skip frames. The method could be used for physics or other simulations where accuracy is not critical, but good enough will suffice.