Playmaker Forum

PlayMaker Help & Tips => PlayMaker Help => Topic started by: nFighter on August 19, 2018, 11:46:50 AM

Title: Raycast ground detection goes wrong
Post by: nFighter on August 19, 2018, 11:46:50 AM
(https://snag.gy/fyn3G4.jpg)

Hello there! I have a very basic setup with a capsule collider and raycasting from it to the -Y. But when the collider is standing on the ground - raycast didn't see a ground. It start to works when I lift up the collider a very little bit, but stop when it fall back to the ground. Is it suppose to work this way or am I doing something wrong? What is the correct way to check if I am on the ground? Should I start the raycast not from the collider origin but from some offset point or maybe setup some thresholds in the physics settings?
Title: Re: Raycast ground detection goes wrong
Post by: terri on August 19, 2018, 01:06:02 PM
Maybe raycast from a bit higher?
I'd guess the start of the raycast is either right on or a bit lower than the floor collider's shell. Note that if the raycast is cast from inside a collider it will not hit