Phaser 2.4.4 timing issue
HTML
<script src="//cdn.jsdelivr.net/phaser/2.4.4/phaser.min.js"></script>
<!-- Use the "External Resources" panel to the left to swap out the Phaser version.
Phaser 2.4.4 exhibits the timing problem: //cdn.jsdelivr.net/phaser/2.4.4/phaser.min.js
Phaser 2.4.3 and below do not: //cdn.jsdelivr.net/phaser/2.4.3/phaser.min.js
-->
JavaScript
var game = new Phaser.Game(500, 100, Phaser.AUTO, null, {
create: function () {
game.stage.backgroundColor = 0xffffff;
game.add.text(500, 10, 'Starting at: ' + Date.now()).anchor.x = 1;
var tween = game.add.tween({});
tween.to({}, 5000);
tween.onComplete.add(function () {
tweenNow = Date.now();
game.add.text(500, 60, 'Tween complete at: ' + tweenNow).anchor.x = 1;
});
tween.start();
},
});