I found out, that when I uncheck “Visible” property of a layer of a tilemap it is not considered for collision shape anymore made from this tilemap.
I didn’t find any information about it, so I think this is a bug, because no “visibility” shouldn’t mean that I don’t want collision objects of those shapes.
Simple use-case - I made a level collisions layer, and a decorative level layer and I want only to display decorative layer, but use collisions from level collisions layer. I don’t want it to be in two different tilemaps, because it would complicate editing them. Separating it is useful, because I can create a regular shape (for ex. a 45 degree slope), but in decorative layer use some complicated grass, stairs or something like that, which shape is not good for a platformer character to move on smoothly.
I do not want collisions to be disabled like that, so another property “Collisions enabled for a layer” or something like that is needed.
In the following project you can check the Visible property of layer “collisions” marked and unmarked in tilemap.tilemap.
This is the approach I’m currently using (one image used only for collision shape with color information, but another one used only for decorative layer with erased tiles that were used for collision) and while I agree that this workaround works, I can’t say that this is a convenient approach, because I need to have two images (and unfortunately they must be of the same size).
Yet I don’t want to make more images for all the tilesources to prevent this as I described above. I know it’s not a priority issue, but maybe a quick solution is possible?
Maybe another property flag for tilemap layers:
Collisions:
or something like that could solve this? As a way easier and faster way than two images to differentiate collisions and visuals in tilemaps?
Arh, I again come into this issue, was looking for the solution/issue and it was me who raised it
Some time ago tilemaps collisions were worked on (when introducing rotated and flipped tilemap) - maybe you can now explain what data is taken into account when rendering and what into creating shapes?