Even forcing 60 fps using doesn’t work properly:
game.forceSingleUpdate = false;
game.time.desiredFps = 60
On 120 Hz is 2x faster and on 30Hz is slower by 50%. How to solve this problem? Why forcing 60 fps doesn’t work properly on different monitors?
samme
2
Which Phaser version are you using?
Try Phaser CE game loop plot. Set forceSingleUpdate
and desiredFps
in the panel. Screenshot.
Which things are faster/slower, and how can you tell?
I’m using Phaser CE v2.20.0
Basically player ship movement is 2x faster on 120 Hz monitor
Here’s example
How to use this https://codepen.io/samme/full/RZKMMw ? WHat should I input there?
Or what’s the best way to control player speed as looks update function isn’t best place.
Ok I have sorted using trick. So lets say I need default value of 2:
player_ship.speed = 120 * 0.001 * game.time.delta;
this works like a harm on any refresh rate