A few quick Q's

  1. Does Tiled support partial Alpha levels? I’m currently using LDtk which when you export a PNG that has partial alpha levels it darkens the resulting texture.

  2. Can you link layers to tilesets? I keep putting tiles on the wrong layer by mistake.

  3. Can you export all layers to it’s own PNG file?


  1. Tiled has full support for alpha channels and exports images with them correctly, if that’s what you mean.

  2. Not as a built-in feature (it is suggested in #153), but there are some ways to make it easier. For example, you can make a script that automatically selects the correct layer when you switch tilesets, or you can use Automapping to move tiles into the correct layers after they’ve been drawn. None of the workarounds are perfect, though, and you may still want to have a verification script. I previously wrote one that makes sure each tile layer uses only one tileset, I can share that if you want it.

  3. Not easily, the only existing export option is for the entire map, so you’d have to to hide all the other layers and export the map, for each layer. This can be automated with scripting, and I believe someone already wrote such a script, but I don’t know if they shared it.

1 Like

If a command-line solution would do the trick, you can use the tmxrasterizer that ships with Tiled and write a small shell script that looks like this:

tmxrasterizer --show-layer "Layer 1" <map-file> <image-file-1>
tmxrasterizer --show-layer "Layer 2" <map-file> <image-file-2>
tmxrasterizer --show-layer "Layer 3" <map-file> <image-file-3>

There is currently no automated way to do all layers with one command, though it could be easily added if there’s demand for such a feature. The above is more flexible though, since it enables you to export groups of layers to a reduced set of images, for example (you can repeat --show-layer arguments to show multiple layers).

Thanks both, very helpful information. I’ll see how I go with the knowledge update.