Tilengine - The 2D retro graphics engine forum
Palette attribute per tile - Printable Version

+- Tilengine - The 2D retro graphics engine forum (http://tilengine.org/forum)
+-- Forum: English forums (http://tilengine.org/forum/forumdisplay.php?fid=3)
+--- Forum: Support (http://tilengine.org/forum/forumdisplay.php?fid=7)
+--- Thread: Palette attribute per tile (/showthread.php?tid=2249)

Pages: 1 2


RE: Palette attribute per tile - megamarc - 08-11-2022

You should modify the loader in LoadTilemap.c to load a custom property from Tiled called "palette" for example. Use this property to set an integer value with the palette index, and store this value In the corresponding bits in Tile structure. No need to create additional layers.


RE: Palette attribute per tile - System64 - 08-11-2022

(08-11-2022, 04:11 PM)megamarc Wrote: You should modify the loader in LoadTilemap.c to load a custom property from Tiled called "palette" for example. Use this property to set an integer value with the palette index, and store this value In the corresponding bits in Tile structure. No need to create additional layers.

The thing is I looked for how to add that custom property to each cell of the tilemap in Tiled, I didn't found anything. I can add this property in a tile in the tileset, but normally, palette slot index is tied to the tilemap, not the tileset.