Does destroying a sprite also destroy it's tween?

Recommended Posts

Let's say I start a tween like this:

// create sprite
let mySprite:Phaser.Sprite = this.create(300, 50, "my_atlas", "bee");

// tween sprite
let yTween:Phaser.Tween =;{y: 150}, 1500, Phaser.Easing.Linear.None, false, 0, 999, true);

Does calling "destroy" on the sprite also destroy it's tween? Or will the tween be silently running in the background until it runs 999 times?

// destroy sprite (will this also kill the tween and remove it from memory?)


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

  • Recently Browsing   0 members

    No registered users viewing this page.