I’m looking for a wall running script that’s physics based so if i go in with a lot of momentum and wall run than i keep my momentum and i want to go up a-bit when i wall run before i start falling down like Dani’s Karlson wall running. I’m also using his movement script from his tutorial. Does anyone know how to do a wall running script?
You have to use a “rigidbody-based” player controller for this. Here the player’s movement is based on a physically correct behavior.
If you have such a controller then i would perform a jump (rigidbody AddForce) in direction to this wall (some kind of left-top or right-top jump), rotate the player’s body against the wall and if the player reached the wall i would apply a small force against the wall and remove the gravity for a short period of time…
If the player jumps again while on the wall he would do now a jump away from this wall and gravity would be enabled again.
Please don’t post walls of plain-text.
At the very top of this forum you’ll find a post that tells you to use code-tags .
here if you want to copy. your welcome.
this code looks decompiled and very similar to Dani’s RB controller plus the wall running. I looked in Karlson with ILspy, and it looks like you’ve straight up ripped the code from Karlson. shame you had to do that.