Rocco Posted June 3, 2014 Share Posted June 3, 2014 var tween = this.add.tween(s.angle).to({angle:s.angle +=90}, 850, Phaser.Easing.Linear.None, true, 100);this is my code, and something must be wrong with it.it does the rotation, but immediatly like the code is onlys.angle +=90;without the tweening effect, don't know why.thanks for help! Link to comment Share on other sites More sharing options...
XekeDeath Posted June 3, 2014 Share Posted June 3, 2014 This part: s.angle +=90That is not needed, you only need to have +90 in there. Also, what you are attempting to tween there is s.angle.angle.Try:var tween = this.add.tween(s).to({angle:'+90'}, 850, Phaser.Easing.Linear.None, true, 100); Rocco 1 Link to comment Share on other sites More sharing options...
Rocco Posted June 3, 2014 Author Share Posted June 3, 2014 yes, thank you very much it works perfect now. the second issue with this.add.tween(s.angle) was the main problem. Link to comment Share on other sites More sharing options...
Recommended Posts