Jump to content

Multiple atlases in one sprite


dzabb
 Share

Recommended Posts

You can only define animations on a sprite from a single atlas/sprite sheet currently. I believe this isn't just an arbitrary issue, but a matter of performance - specifically in the case of WebGL where texture atlases are very fast because you're not changing the texture, just the position. As soon as you start replacing textures you incur large performance penalties.

 

You can try the following: reduce the amount of frames or the size of the character, make sure your atlas is packed efficiently (you may want to try reducing the padding for instance) and if you can get away with it (and if it's applicable) only have the character facing in one direction, and change the sprite's scale.x to -1 to 'flip' it when facing in the other direction.

Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

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