Jump to content

BUG:animationFrame is undefined


Recommended Posts

  • 2 months later...

I know this question is from February, but I just encountered the same issue when trying to type out the tutorial on my own, and the solution is pretty straight forward, so I wanted to share since this post pops up first on a Google search.

If you encounter this error. Ensure that you tell load to create a spritesheet and not an image: 

       this.load.spritesheet('dude', 'assets/dude.png', {frameWidth: 32, frameHeight: 48});

And NOT:

      this.load.image('dude', 'assets/dude.png', {frameWidth: 32, frameHeight: 48});

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...