Jump to content
This forum will be closing down. Please move to the respective dedicated project forums.

What is the correct way of calling an anim's onComplete?


Ninjadoodle
 Share

Recommended Posts

Hi @enpu

Just wondering how to call an animations onComplete function. This is what I have but it doesn't seem to do anything ...

this.sprite.addAnim('hideO', [7, 8, 9, 10, 11, 12]);
this.sprite.anims.hideO.speed = 60;
this.sprite.anims.hideO.loop = false;
        
this.sprite.anims.hideO.onComplete = function() {
    console.log('done');
}

Thanks!

Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...