[2D] Player falls through floor for a split second

So I’m testing some things out using Unity 2D. But something that’s odd is that in my test bed, my player falls through the floor for a split second before righting himself when he falls (e.g. landing after a jump or a drop). It’s just barely visible.

I checked, and this isn’t a graphical glitch. I’m not doing anything unique here, just making a typical sidescroller character.

Here’s a link to my PlayerController script.

And here’s a GIF of my issue.

Any help with this issue would be greatly appreciated.

If someone still need a solution here it is:
You just need set Collision Detection to Continious in your RigidBodyComponent[56561-снимок.jpg|56561]

Have you tried changing colliders? I had this same problem when I was designing a 2D game and when I changed colliders, it made it better.

are you having multiple colliders next to each other bc if you do the player will somtimes fall through a way to fix this is by making one collider for all the sprites on per group so lets say you have 7 blocks in a group if you remove 6 of the colliders and make the middle ones x = 3.5 then you will only have one colliders this is not best way to fix it but it works

I had a problem, that my sprite was hovering a few pixels above the ground. So i changed “Default Contact Offset” from 0.01 to 0.001 in Project Settings / Physics 2D. Then i saw that i have the same problem as you. That my player is stuck in t he ground for a split second. So i changed that number back to 0.01 and the problem was gone. I then just changed the box colider a little bit so my sprite wasnt hovering aboive the ground anymore.