TexturePacker is a tool that creates sprite sheet for game engines, user interfaces or web. It is possible to create simple sprite strips or grid based layouts. Assuming that all sprites have the same size it's easy to get a sprite's position using it's index in the sprite list. This sprite sheet format is ok for tile maps but im most cases it's a waste of memory.
TexturePacker also allows you to create an optimized sprite sheet with irregular sprites. TexturePacker can remove transparency, rotate sprites and create a much tighter layout. In this case you have to know where a sprite is located, how it's oriented and if transparent pixels were removed.
This requires a data format that can be loaded from your gaming framework. You surely don't want to maintain lists of coordinates in your game source code.
TexturePacker knows a big number of game engines and writes the specific format for that engine.
TexturePacker also comes with several generic data formats — that support all feature of TexturePacker and can be used with your own game engine.
Even if a game engine is not listed in TexturePacker's list it might already be compatible if it's using one of the generic formats:
You can also create your own data format — e.g. by directly exporting source code — if you are not happy with what's already available.
First of all: Congratulations for creating your own game engine! You now have to choose: Do you want to use a generic data format or a format customized for your game engine?Using a generic format
I would usually propose to use one of the generic formats already available with TexturePacker. They should already contain all information required to use the sprite sheet. The other advantage is that there should also be ready-to-use parsers for the data. TexturePacker currently supports the following generic formats:
TexturePacker's exporter system is template based. You can easily create your own format, including additional customization.
A good starting point is to use one of the existing exporters and adjusting it to your needs. They can be found inside the exporters directory of the TexturePacker installation.
The TexturePacker Documentation should give you a good starting point.Adding your data format to TexturePacker
We are happy to add your exporter to TexturePacker if you have a public available game framework with a reasonable user base. Simply contact us at supportXXXX@codeandweb.com and send us a link to your homepage and the exporter.Get a free TexturePacker license!
We support developers creating game engines with free TexturePacker licenses. Our requirement is that the engine is publicly available. It does not need to be open source and it does not need to be free. But people should be able to download and use it.
You are trying to use TexturePacker but your game framework is not (yet) listed.
It is quite likely that the framework uses one of the generic data formats such as
Many other frameworks work out of the box using the sprite strips or grid based layouts
... but you should consult the framework's documentation for the details.
Please tell us which framework you are trying to use so that we can add support for it:
TexturePacker comes with 2 types of exporters:Internal Exporters
These exporters are compiled into TexturePacker and can't be modified.Template based exporters
These exporters are based on a simple template language allowing you to change the output format
A good starting point for you is to use one of the existing exporters (they are inside TexturePacker's application folder in a subfolder called exporters. Pick the one that suits your needs and copy it into a new myexporters folder somewhere outside TexturePacker's path. Point the exporter path in preferences to that location.
Check out the TexturePacker Documentation for more information about how to modify the data format.