Is there some way to get more precise collision between a RigidBody2D and TilemapLayer

Godot Version

4.3.stable.official[77dcf97d8]

Question

In this project I have a tilemaplayer and code to spawn coins wherever I click. I want these coins to have physics and drop to the ground. The physics work for the most part, but every so often a coin will either fall into or fall completely through the tilemap. There’s no consistency from what I can tell. Is there some way to prevent this or to get a more accurate collision between the two?

Video of the situation if it lets me put it here:

Other things to note:
The coins are a Rigidbody2D with a sphere-shaped collider with rotation disabled. There’s currently no script attached to it, so it’s just relying on the project settings gravity setting. I know this isn’t the best option, but I honestly have no idea what I would need to add to the script.

I think this has to do with the speed of your coins. Try enabling continuous_cd on your RigidBody2D and see if that improves things.

1 Like

Are you using Godot’s built-in physics???

If you are, you would consider move to a 3rd party physics library…

1 Like

I am just using the default physics. I’ll definitely check this out, thanks. I’m still very new to the program so learning about this stuff is very helpful.

Physics is the major drawback for Godot, for now…

So if you check it out on youtube, you will see that some plugins were created to bypass it.

Godot is great for it’s currently state, but physics is something that will need to be improved down the road…