Can you use multiple Colliders/Layers in one tiled level?

Hi guys, I want to create my level with three different colliders/layers. Ground, Wall & Ceiling.

At the moment, when i export the level I’ve created in Tiled, it puts a massive polygon collider around the whole level I’ve created, which is great, but I want the walls to be under the layer ‘Wall’ and the same for Ceiling. How can I achieve this?

Many thanks,

Mojoz

I assume you’re using Tiled2Unity to export your Tiled map to Unity?

If so, yes, you can have multiple “collision layers”. It does require you to put your Ground, Wall, and Ceiling tiles in separate “tile layers” in Tiled though.

However, if you prefer to use only one layer in Tiled (like me) then you can use the automapping feature in Tiled to break your one layer into multiple layers – each with its own “collision layer” assigned to it. It is a bit involved but once you have the automapping rules set up it is much easier to work with one tile layer.

(Sorry about putting “layer” in quotes. Unity and Tiled have different meanings on what a “layer” is.)

Thank you so much, that worked. I feel a bit stupid now, because it was very simple but I just couldn’t figure it out! I really appreciate the help.

1 Like