The Custom Properties documentation states, under Typed Tiles (emphasis mine):
If you’re using tile objects, you can set the type on the tile to avoid having to set it on each object instance. Setting the type on the tile makes the predefined properties visible when having the tile selected, allowing to override the values. It also makes those possibly overriden values visible when having a tile object instance selected, again allowing you to override them.
I figured out how to create a map, tileset, and define custom properties on one particular tile in my tileset. What I can’t figure out is how to actually override those properties.
Maybe I’m understanding this wrong – let’s say I have a tileset representing monsters, and I edit the tileset to add
Health as a custom property to one of the monster tiles. I would then like to place that tile in three different spots on the map, and give each of those instances a different health value.
Is that how this feature works? If not, how can Tiled to make this work the way I want?
The section in the documentation is about the following scenario:
Define an object type called “Monster” with a property called “Health” in the Object Types Editor. Let’s say the value is kept at 0.
Select all the tiles representing monsters and fill in “Monster” as their type. Now, whenever you select one of these tiles, you should see they have a “Health” property with default value 0.
Change the “Health” property of any of your monster tiles, to override the 0 value.
Place some tile objects using those monster tiles. You will see the overridden value as the default in their custom properties, but you can still override it again for each object instance if you want to vary the health for instances of the same kind of monster.
I hope this clears it up.
Thanks for clarifying and for a quick turn-around on this. My specific question is how to do the following:
How do I do that? I can place the tiles, but it shows me the default values are greyed out / can’t be overridden when I edit the tile. I tried right-clicking, etc. to no avail.
Are you using a tile layer or an object layer? On a tile layer, each tile can’t have individual properties since this type of layer is optimized for storing large areas filled with tiles. This is why the documentation says “tile object”, which are tiles placed on an object layer. Those objects can have individual custom properties.
This is the part that I couldn’t figure out. Thanks, I can get this to work as expected now.