-
This isn't really a criticism since it's not a big issue, but more of a burning curiosity: why is the position of objects based on the bottom left of the object when the coordinate system of Tiled has 0,0 at top left? Wouldn't it make sense for the "origin" of an object to also be the minimum corner? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
Actually the origin of rectangle and ellipse objects is the top-left, but not for tile objects. This inconsistency is historical, because when the support for tile objects was introduced they were meant for the placement of objects like trees in a top-down perspective. In such games it is common to sort the sprites by their bottom so a bottom origin makes sense. However, since it was also inconsistent and not best for every game, eventually an "Object Alignment" setting was introduced on the Tileset: You can use this property to set the alignment of your tile objects (at least, those referring to that tileset) to Top Left. If you've already made a couple of maps though, changing the alignment now would likely mess up the placement of those objects. |
Beta Was this translation helpful? Give feedback.
-
I had no idea about the object alignment. Thank you very much for the explanation! |
Beta Was this translation helpful? Give feedback.
Actually the origin of rectangle and ellipse objects is the top-left, but not for tile objects. This inconsistency is historical, because when the support for tile objects was introduced they were meant for the placement of objects like trees in a top-down perspective. In such games it is common to sort the sprites by their bottom so a bottom origin makes sense.
However, since it was also inconsistent and not best for every game, eventually an "Object Alignment" setting was introduced on the Tileset:
You can use this property to set the alignment of your tile objects (at least, those referring to that tileset) to Top Left. If you've already made a couple of maps though, changing the alig…