Platformer Enhancements - Wall Jumping

6
  • 154 favourites

Index

Stats

20,335 visits, 69,973 views

Tools

License

This tutorial is licensed under CC BY 4.0. Please refer to the license text if you wish to reuse, share or remix the content contained within this tutorial.

Improve and Refine our Wall Jump

16. At this point we now have our basic wall jump behavior. However, there are a few items that need some tweaking. The infinite jump issue can be tweaked in two ways. We can limit the number of times they can wall jump using variables. We can also keep the player from jumping straight up the same wall by tweaking the angle they bounce off the wall. Currently, they bounce straight up which isn't what I want, my goal is more of a triangle jump so that if they want to continue to wall jump, they have to jump from one wall to the next. I am also going to change the wall jump button from the Up Arrow, to the left or right arrows. This will give us more of a classic wall jump behavior, if I want to jump off of a wall, I should have to push in the opposite direction while I do it, instead of hitting up.

17. The first thing I am going to tweak is the behavior of the wall jump. When the player jumps off the wall, I want it to push them out away from the wall as well instead of just straight up. This makes the wall jump feel much better, for lack of a better description it just feels right. So lets go into our event and instead of just setting vector Y -500 I am also going to set the Vector X (horizontal position) of the player to + or - 400 depending on which side the wall is on. You can tweak and test this to see what feels right for your game of course. So on our event sheets, lets add a new action setting the players platform Vector X based on the side the wall is on. Here is what we need in our events:

For wall on left - Player Set Platform Vector X to 400

For wall on right - Player Set Platform Vector X to -400

Your event sheet should look like this:

18. Go ahead and test your project and make sure you refresh the browser if the changes don't seem to be working.

  • 0 Comments

  • Order by
Want to leave a comment? Login or Register an account!