Tilevania - character clipping through the floor

I’m on lecture 93 of the Unity 2D course where you implement a box collider for the feet of the player character to use for collision detection when determining if the player can jump or not. For some reason, doing this has caused my character to clip into the platforms layer (colliders and clipping shown in images). I’ve gone through a few times and tried to see if I did anything different to Rick, but I don’t see where I went wrong. Anyone have any ideas?

image image

Hi,

First of all, try to move the bottom of the capsule collider a bit up, so it does not align with the bottom edge of the feet collider.

Secondly, check the ground collider. There are often problems with the shape of the tilemap collider, for example, gaps. If you see a gap or something that does not seem to be right, disable the tilemap collider and reenable it.

Did this help?


See also:

Thank you for the suggestions. Ultimately what I found worked was to extend the box collider up through the body more (essentially just making it taller). No idea why that would work but it did.

I’m glad you found a solution. :slight_smile:

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.

Privacy & Terms