Capsule shape and RayCast bug

If you change the player’s collider shape to capsule in my game it will be able to jump in mid-air. I used RayCast to check if the player is on the ground so I think it’s something with RayCast and capsule because with circle everything is OK.

Capsule clips through the ground I believe, so it might negative raycast. Same thing happened when my camera was a circle and partially clipped into walls, raycast clipped the wall and no longer detected it because it was past the detection area.

@grazer Could you take a look at this? I don’t want my player to be a circle :dissapointed:

Yeah, I’ll take a look. the Raycast is probably hitting the bottom collider.