Sticking out from the edge

↑ Even with this setting, the player still goes a little off the edge.

Why is that? What should I do?

I’m guessing it’s written for bipeds and not quadrupeds. It’s measuring from the center of the collision capsule. In your case it’s basically the animals center of mass (in it’s middle).

The ledge detection will start to work once the middle of the animal starts crossing the set boundary point.

You would have to write some custom logic doing for instance a sphere trace in front of the animal probably around where the feet are to check if you have an floor in front of it, same for the back if the animal can walk backwards.

The “Can Walk Off Ledges” would disallow you from falling to the lower level whether controlled by a player or AI. It still lets the capsule component get as far as it can before it falls.

For testing purposes, If you select the Capsule component and untick “Hidden In Game” you’d see the capsule whilst playing and see where it’s stopping.

You could do as 3dRaven says with custom collation logic or reduce the size of the collision area on the floor so that as far as collision is concerned the fox would be hanging off the edge of the ledge, but to the eyes, it’s simply at the edge.

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