Jump to content

Creating an sprite animation from multiple images discussion


seejay92
 Share

Recommended Posts

Hey all,

 

I'm working on a small prototype project where players can upload their own images to feature in my game as a sprite. I would really love for these images to be used as an animation of the sprite, but looking over the docs it looks like the animation manager and frame data only take to do with frames that are part of a singular image. Normally I would use a texture atlas or spritesheet to easily create animation, however to save players from the tedious job of having to create their own, I am looking for a solution for individual images I have a few ideas in mind in how to do this:-

 

1) Preload each image singularly, then make a new bitmapdata object during init, where the images would be lined up and used to adda new standard spritesheet to cache

2) Call the sprite.setTexture function every x milliseconds to update the texture

3) Merge the images into a spritesheet/atlas before they are loaded into phaser.

 

Just wondering if you thought any of these may work best or had any better ideas/solutions?

 

Thanks as always!

 

Cameron

 

Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

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