Tilemap doesn't collide with tilemap (SOLVED)

I have the following set up:

why go1 and go2, which contain tilemap and using tilemap as collision shape, didn’t collide each other?

I have tried to collide go1 to go4 and it worked.

Any idea?

Does the tilesources for the tilemap contain collision groups?

Yes. The tilesources contain collision groups.

And the tiles in the tilesource have been assigned to that group?

Yes. Here is the screenshot:

What is the mask of the collision objects?

The group is default, and the mask is default. It is all the same for every game object in the collection.

FYI, my aim is to get non-cube, non-sphere, and non-capsule collision shape. I need shape like triangle, and some irregular shape. I tried to work it around by utilize tilemap.

Ok, thanks. I will run some tests and see if I can repro your case

This seems to be a bug. Thanks for finding and reporting. I’m filing an issue.

1 Like

Update: After evaluating this it seems unlikely that we will support tilemap-to-tilemap collision. Instead we’re looking at improving collision definition on sprites, but that will take some time.
DEF-1518

I’m having the same problem with TileMap - Generic collision object collision!
The collision object added to the game object which contains the Tile Map collides with nothing.

Did you also check the collision groups as mentioned in this thread?

Yes.
I created one collision group called “default” inside the TileSource. I added all the Tiles of the TileSource to this collision group.
After creating the TileMap I created a game object equipped with the TileMap and a collision object which implements the Collision shape defined for the Tile Source of the Tile Map.
The collision shapes are not visible inside the Scene Editor of the collection inside which I’m putting the game object.
I scaled the game object of a factor of 0.5 for each dimension.

The other game object that I created it’s a simple box with an attached sprite with the “default” collision group set in the mask property.

I folllowed all the steps of the official guide about physics.

Did you enable physics > debug in game.project to see that everything looks correct? I did a weird simple test here:

1 Like

Actually, I didn’t.
Now everything works fine.

Thank you.

2 Likes