Sorry for the amount of questions… I don’t think LibGDX supports the hidden objects in tile collision editor. However, if I could somehow get all the objects from the collisions in my tileset and put them in a seperate object layer, that would work. Is this possible in Tiled?

Sorry for the amount of questions… I don’t think LibGDX supports the hidden objects in tile collision editor. However, if I could somehow get all the objects from the collisions in my tileset and put them in a seperate object layer, that would work. Is this possible in Tiled?

This is not currently possible, and in fact it’s not possible to make this work 100%, due to limits on the kind of transformations you can apply to objects (a rotated tile collision object can end up getting “sheared” if its tile object is stretched, and there is no way to represent that except by converting the collision object to a polygon).

That said, it could be supported as an export option, which could even go as far as Tiled2Unity in generating a more optimized collision geometry (see this example). What works best here depends a little on your needs.

I assume you need this layer since it would be your collision layer in libgdx? What would be the best representation of it?

Correct. There’s currently no way in LibGDX to do this. Perhaps I could implement it myself, but I’m not very experienced in Java. Currently I just manually make objects to set collision in a “collision” layer. But my maps are getting bigger and this takes up a lot of time. In LibGDX I just pull all the objects from the collision layer, turn them into rectangles and then check for overlap with character or NPC hitboxes.

I haven’t, but I noticed that other people had already done that. It had been addressed, but it was never implemented. And that was already over 2 years ago, so I doubt it’ll be implemented any time soon. I guess I’ll just have to do it the slow way. Or maybe try implementing it myself if I’m brave enough.

Sorry, wrong wording. I meant the developer of LibGDX recognized that people wanted this feature implemented and he replied to the issue, but he never actually did implement it. I will look up the link later.