Sprite sheets already exist since the first days of computer games. The idea is to create one big image that contains all animations of a character instead of dealing with many single files.
An animation strip is the simplest form of a sprite sheet: It's just placing each animation frame next to each other. All frames have the same size, and the animation is aligned in each frame.
![]()
A tile set is not different from a sprite sheet: It contains building blocks for game levels. This is an example for a tile map:
Working With Sprite Sheet Animations In Android
It's easy for a game to retrieve the sprites since they all have the same width and height. The disadvantage is that the sprites waste a lot of memory because of all the additional transparency.
The developers of game engines are aware of the wasted memory in the simple sprite sheets and started to optimize the space. The easiest way is to remove the transparency surrounding the sprite and shrink it to the bounding box.
The game engine now needs additional information to draw the sprite: It needs to know where the sprite is located and how much transparency was removed.

Sprite Sheet Generator
This information can be stored in a data file that is shipped with the sprite sheet. It does not only contain the coordinates but can also contain names for the sprites and other meta information.
With this data file it's much easier to tell the game engine that you want to draw a Banana sprite — instead of paint the sprite at position (299, 192).
The easiest way to create optimized sprite sheets is using TexturePacker. TexturePacker is a tool that specializes in creating sprite sheets. The free version allows you to create sprite strips and tile maps.
An Introduction To Spritesheet Animation
TexturePacker takes all image files in the folder and packs the sheet for you. It supports a big range of image formats including PhotoShop's psd files and even Flash movies (.swf).
![]()
When you are using the free version, you'll have to change 3 options from the default values. This is no restriction because you need them set to create a sprite strip:
Sprite strips are a good start — but also a waste of memory in many cases. If you plan to create a game, you should optimize the sprite sheet.
![]()
Game Ready Animations
The first thing is to select the game engine you plan to use. TexturePacker supports 30+ engines and can be extended to support any new one.
TexturePacker automatically applies optimized default settings for the game engine. It also writes a data file with the required sprite information when you press Publish.

TexturePacker takes all image files in the folder and packs the sheet for you. It supports a big range of image formats including PhotoShop's psd files and even Flash movies (.swf).
![]()
When you are using the free version, you'll have to change 3 options from the default values. This is no restriction because you need them set to create a sprite strip:
Sprite strips are a good start — but also a waste of memory in many cases. If you plan to create a game, you should optimize the sprite sheet.
![]()
Game Ready Animations
The first thing is to select the game engine you plan to use. TexturePacker supports 30+ engines and can be extended to support any new one.
TexturePacker automatically applies optimized default settings for the game engine. It also writes a data file with the required sprite information when you press Publish.

0 Comments
Posting Komentar