Preventing Rigidbody3D from traversing steep hill

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By CreatureUnknown

Hello! I’ve been working on a 3rd person character controller (where the player can control themselves mid-air) and have had issues with my rigidbody climbing over any slope with angle less than 90 degrees, as the velocity gets redirected upwards due to the collision with the slope.

As it is, I’m using _integrate_physics(state), and using state.apply_impulse in the direction of my input

I’ve tried a variety of techniques to counteract it, to no avail. These include looping over the contacts, and using get_contact_impulse(), but these always seem to return as 0;
I’ve tried increasing the damping and setting the friction to zero, but the player still slowed way down when pushing against the wall, and makes the player feel like they’re wading through soup.

As it is, I’m currently just placing an invisible wall in front of the player if a forward raycast intersects geometry and its normal is close to horizontal, but since the wall slides backwards as the ray moves up the slope, there’s some stuttering.

tl;dr What advice do people have on preventing this from happening?