InsaneHero Posted December 3, 2014 Share Posted December 3, 2014 I can't find the change responsible in the commit logs, but until recently I was able to delay the start of a tween:game.add.tween(this.tbt).delay(1000).to({alpha:1.0}, 500, Phaser.Easing.Linear.None, true);After updating my dev branch today, this now fails in the delay function (the access of timeline[index].delay is invalid if index = 0 and timeline is an empty array).this.timeline[index].delay = duration;I suspect this must be a side-effect of some other recent tween changes. I'll keep looking but maybe someone will go "aha" and know what the problem or fix is (/fingerscrossed). Link to comment Share on other sites More sharing options...
InsaneHero Posted December 3, 2014 Author Share Posted December 3, 2014 Ah, ok... I just diffed the dev branch and my old stable version and I see that the entire approach to tweening has changed recently. 'timeline' didn't even exist previously.I suspect that this is a corner case that wasn't caught during the change. It looks like it might work if I just do the delay AFTER the .to Link to comment Share on other sites More sharing options...
rich Posted December 3, 2014 Share Posted December 3, 2014 Yes you will need to either set the delay after creating one (or more) "to" tweens, or just use the delay parameter in to:game.add.tween(this.tbt).to( { alpha:1.0 }, 500, "Linear", true, 1000); Link to comment Share on other sites More sharing options...
Recommended Posts