Skip to content
This repository has been archived by the owner on Nov 12, 2024. It is now read-only.

transitionEnd or animationEnd on sprite component #218

Closed Answered by slmjkdbtl
ryanmunger asked this question in Q&A
Discussion options

You must be logged in to vote

There's an "animEnd" event fired when an animation ends, I'm also adding an onEnd() callback to play()

player.on("animEnd", (anim) => {
    if (anim === "jump") {
        // ...
    }
});

Replies: 1 comment 4 replies

Comment options

You must be logged in to vote
4 replies
@ryanmunger
Comment options

@ryanmunger
Comment options

@slmjkdbtl
Comment options

@ryanmunger
Comment options

Answer selected by ryanmunger
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants