Reusable objects? With fill/drag features? Object Stamps/Object inheritence

Would be nice if you could use the drag/Rectangular Select/fill tool when it comes to dealing with objects.

Also is there a way to make reusable objects that share the same custom properties? I know objects can be duplicated but I’m not sure how to mass draw them since you cant drag/fill an area with objects as easy as you can with a tileset.

An example would be that I have a group of monsters based on a tile. Lets call G1. This group has the custom properties of “hp:10”. Is there a way to stamp multiple monsters named G1? Thus creating like a unique object instance/stamp sharing the same custom properties?

Well you are able to select multiple objects and edit them, what was broken was that Tiled kept the “Object Properties” context menu item disabled. I fixed that here:

However you are still able to edit them if you had the properties dock already open.

This is not possible at the moment unfortunately. A related issue is:


What you could usually do here, is create a tileset with a tile for each of your monsters, and specify their properties as tile properties. Then you would just place those tiles on the map.

Late reply, sorry to request this feature since its pretty specific to only select games.
What you stated works around the issue fine(exactly what I was thinking) but games that require a lot of player contribution to maps would make it difficult because you don’t know if players are gonna create maps with 10 sets of monsters with different values. Do you think this will be difficult to implement? I’ll probably sponsor this in the future for sure.[quote=“Ablu, post:2, topic:1677”]
Well you are able to select multiple objects and edit them, what was broken was that Tiled kept the “Object Properties” context menu item disabled. I fixed that here:

Yeah lol, but its kind of a pain if you have over 20 or so objects that need a specific property .

If you’re talking about an object library, then this is certainly something I’d like to add. But there’s two ways of implementing this:

  • When placing objects from the library, it could be like copy/pasting them from another map. All data associated with the object is duplicated. When the object is later changed in the library, already placed objects are unaffected by the change.

  • The library could be referenced by the map and placed objects would point back to the object from the library that they were based upon. No data except customized parts would need to be stored, and changes made to the library would affect any non-customized parts of already placed objects.

The first way is of course much easier to implement than the second. But when working on games, I think the second is generally much more useful. I’m wondering whether it makes sense to provide the first way first, and then later add the second option.

What behavior would you expect?

yeah, I agree, the second option does seem more useful.

And eh, the behavior is pretty much what you said for the 2nd option, except I would not apply the effect to non-customized part. Not sure if I’m interpreting it wrong,

Pretty much what I’m expecting is that you can create multiple custom property libraries and have an object point at it by reference.

Similar to the way custom properties work with tile sets.

Lets imagine this tile is water and the custom properties block collision

<tile id="0">
    <property name="density" value="1"/>

Lets say you have an area where water isn’t deep so density gets turned off to value of 0 and the players can walk on it.
Only problem is that if you change the value, it will affect every other ones placed.
As you mentioned, the work around would be to add another tile in the tile sheet and set its custom properties to the different value.
Objects solve this problem pretty well since you can have distinct properties on the same tile but if you want an area to have no density, you would have to edit all of the property of tiles manually.

Sorry for the pointless example if you got what I mean already.

I’ll elaborate more in the future when this becomes a big problem in a project I’m working on. ope to be working with you soon. Keep up the great work!

If the change does not apply to non-customized parts, then you’re basically talking about the first behavior where the object is copied rather than referenced. The only point of the reference would be that if you change the referenced object, that change would affect the object referencing it, right? The object referencing the object in the library would not duplicate the information already stored in the library.

For example, consider you’d want to change the density of all water in the game to 0.8 for whatever reason, except for those areas where you had explicitly changed it to a different value. In that case you’d change the value on the tile in the tileset, effectively affecting any water tile objects which do not have a custom density value.

If you would not have changes to the objects in the library apply to already placed objects, then you’d need to search & replace all these objects in your maps to apply changes to all of them.