Sign in to follow this  
Appolos

Tweens in Phaser

Recommended Posts

Hello !
Can anybody help with Tween in Phaser.

I need rewrite adding tween to game from Phaser 3 to Phaser 2.
 I have this code, how I  can write it on Phaser 2.

 

 this.tweens.add({

            // adding the knife to tween targets
            targets: [this.knife],

            // y destination
            y: this.target.y + this.target.width / 2,

            // tween duration
            duration: gameOptions.throwSpeed,

            // callback scope
            callbackScope: this,

            // function to be executed once the tween has been completed
            onComplete: function(tween){
                            some function ................
                        break;
                    }
                });

Thaks !

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.