mariogarranz Posted October 27, 2015 Share Posted October 27, 2015 After upgrading some games to Phaser 2.4.3 we noticed some animations were suddenly playing really fast or really slow (depending on devices). Some bug fixes regarding this were added on 2.4.4, but the problem was still there. This bug seemed to affect only Tween animations so I checked the docs and found this value:TweenManager.frameBased: A frame based tween will use the physics elapsed timer when updating. This means it will retain the same consistent frame rate, regardless of the speed of the device. The duration value given should be given in frames. If the Tween uses a time based update (which is the default) then the duration is given in milliseconds. In this situation a 2000ms tween will last exactly 2 seconds, regardless of the device and how many visual updates the tween has actually been through. For very short tweens you may wish to experiment with a frame based update instead. According to this, the default behavior should be the same as in previous versions of Phaser, however it seemed to be the opposite, since the animation duration was now being dependant on the speed of the device.I tried setting frameBased to true and everything appears to work fine now (even though I'm still sending the time parameter as milliseconds, not in frame numbers).Am I missing something here or is the functionality bugged? Tilde 1 Link to comment Share on other sites More sharing options...
samme Posted March 16, 2021 Share Posted March 16, 2021 Fixed in https://github.com/photonstorm/phaser-ce/releases/tag/v2.17.0 Link to comment Share on other sites More sharing options...
Recommended Posts