Ladder Example (old)

Ladders get asked about occasionally, so I made a quick example, it doesn’t remove x movement. Some people want to jump past ladders, but it feels slippery. If you hold up, you’ll always grab on, though. You can change that if it bothers you, this is just a better version of a simple ladder, because I added climbing up and down with no gravity pull, and walk the gap. I also used raycast jumping, which I normally would say is better than collision jumping, but that’s also up to you, if you are already using the run and jump bundle. I used raycast instead of proximity for ladder to guarantee that you are parallel to the ladder, instead of next to it, less buggy. I used up for jump and toggled it to climb, but you can use different buttons for each instead of toggling off jump. Hopefully this helps out anyone in the future that needs a ladder. Flowlab Game Creator - Ladder example

I packaged it into a bundle that you can paste and adjust in your game.

Click to see code

{"data":{"behavior":{"nodes":[{"outputCount":0,"x":180,"group":"","y":160,"name":"Ladder logic","id":"5c34242f03af204b","inputCount":0,"isMenuItem":false,"behaviorType":"logic.NodeGroup"},{"outputCount":2,"x":180,"group":"5c34242f03af204b","delay":0,"y":160,"name":"Keyboard","id":"5c02bda4d130ac43","inputCount":0,"repeats":true,"keyCode":37,"behaviorType":"logic.triggers.Keyboard"},{"outputCount":1,"x":810,"group":"5c34242f03af204b","y":832,"name":"Switch","id":"5c0d5a8c7eb9fb4d","inputCount":3,"_startVal":0,"behaviorType":"logic.logic.Switch"},{"outputCount":3,"x":720,"group":"5c34242f03af204b","y":224,"name":"Velocity","id":"5c039b81bd78eb4b","inputCount":3,"behaviorType":"logic.properties.Physics"},{"outputCount":2,"x":360,"group":"5c34242f03af204b","direction":270,"y":448,"name":"RayCast","id":"5c11aac47c13be4d","length":20,"inputCount":3,"targetClassId":4735561,"behaviorType":"logic.components.RayCast"},{"outputCount":1,"x":810,"group":"5c34242f03af204b","y":640,"name":"Switch","id":"5c0a52a22b4a5b4b","inputCount":3,"_startVal":0,"behaviorType":"logic.logic.Switch"},{"outputCount":1,"x":180,"group":"5c34242f03af204b","y":448,"name":"Always","id":"5c09daebb479fa42","inputCount":0,"behaviorType":"logic.triggers.Always"},{"outputCount":1,"x":990,"group":"5c34242f03af204b","startVal":-5,"y":736,"name":"Number","id":"5c103c1304436a4f","inputCount":3,"tag":"","behaviorType":"logic.logic.Value"},{"outputCount":2,"x":360,"group":"5c34242f03af204b","delay":0,"y":832,"name":"Keyboard","id":"5c02ba99f6ac424b","inputCount":0,"repeats":true,"keyCode":40,"behaviorType":"logic.triggers.Keyboard"},{"outputCount":1,"x":360,"group":"5c34242f03af204b","startVal":5,"y":256,"name":"Number","id":"5c034e1dc8bd0748","inputCount":3,"tag":"","behaviorType":"logic.logic.Value"},{"outputCount":1,"x":990,"group":"5c34242f03af204b","startVal":5,"y":832,"name":"Number","id":"5c1039806c241743","inputCount":3,"tag":"","behaviorType":"logic.logic.Value"},{"outputCount":1,"x":360,"group":"5c34242f03af204b","startVal":-5,"y":160,"name":"Number","id":"5c034edcb2c7f44a","inputCount":3,"tag":"","behaviorType":"logic.logic.Value"},{"outputCount":1,"x":810,"group":"5c34242f03af204b","y":736,"name":"Switch","id":"5c0c86045b101c47","inputCount":3,"_startVal":0,"behaviorType":"logic.logic.Switch"},{"outputCount":2,"x":1170,"group":"5c34242f03af204b","resetVelocity":true,"y":768,"name":"Position","id":"5c1cc1660cdcf844","pixelUnits":true,"inputCount":4,"behaviorType":"logic.properties.Position"},{"outputCount":1,"x":540,"group":"5c34242f03af204b","gateType":"AND","y":352,"name":"Logic Gate","id":"5c1909a9d1d56b44","inputCount":2,"behaviorType":"logic.logic.Gate"},{"outputCount":3,"x":1170,"group":"5c34242f03af204b","y":640,"name":"Impulse","id":"5c0aac8960e8104a","inputCount":3,"behaviorType":"logic.components.Impulse"},{"outputCount":2,"x":360,"group":"5c34242f03af204b","direction":90,"y":352,"name":"RayCast","id":"5c117dad45565142","length":20,"inputCount":3,"targetClassId":4735561,"behaviorType":"logic.components.RayCast"},{"outputCount":1,"x":720,"group":"5c34242f03af204b","startVal":-25,"y":352,"name":"Number","id":"5c04683d4effd14b","inputCount":3,"tag":"","behaviorType":"logic.logic.Value"},{"outputCount":1,"x":540,"group":"5c34242f03af204b","gateType":"OR","y":448,"name":"Logic Gate","id":"5c193ad285fa7a46","inputCount":2,"behaviorType":"logic.logic.Gate"},{"outputCount":2,"x":360,"group":"5c34242f03af204b","direction":90,"y":544,"name":"RayCast","id":"5c09632170569341","length":22,"inputCount":3,"targetClassId":4735557,"behaviorType":"logic.components.RayCast"},{"outputCount":2,"x":180,"group":"5c34242f03af204b","delay":0,"y":256,"name":"Keyboard","id":"5c02bcd948986c4a","inputCount":0,"repeats":true,"keyCode":39,"behaviorType":"logic.triggers.Keyboard"},{"outputCount":1,"x":990,"group":"5c34242f03af204b","startVal":8,"y":640,"name":"Number","id":"5c0abf6bf8102c4a","inputCount":3,"tag":"","behaviorType":"logic.logic.Value"},{"outputCount":3,"x":900,"group":"5c34242f03af204b","y":352,"name":"Motor","id":"5c04773ff8dd9845","inputCount":3,"behaviorType":"logic.components.Motor"},{"outputCount":3,"x":720,"group":"5c34242f03af204b","y":128,"vertical":false,"name":"Flip","id":"5c06d13dba0fee41","inputCount":3,"behaviorType":"logic.properties.Flip"},{"outputCount":2,"x":360,"group":"5c34242f03af204b","delay":0,"y":640,"name":"Keyboard","id":"5c02bbce354bdf46","inputCount":0,"repeats":false,"keyCode":38,"behaviorType":"logic.triggers.Keyboard"},{"outputCount":2,"x":360,"group":"5c34242f03af204b","delay":0,"y":736,"name":"Keyboard","id":"5c0cfcac6da20b4f","inputCount":0,"repeats":true,"keyCode":38,"behaviorType":"logic.triggers.Keyboard"}],"links":[{"output_id":"5c02bda4d130ac43o0","input_id":"5c034edcb2c7f44ai1"},{"output_id":"5c0d5a8c7eb9fb4do0","input_id":"5c1039806c241743i1"},{"output_id":"5c11aac47c13be4do0","input_id":"5c193ad285fa7a46i1"},{"output_id":"5c11aac47c13be4do1","input_id":"5c1909a9d1d56b44i1"},{"output_id":"5c0a52a22b4a5b4bo0","input_id":"5c0abf6bf8102c4ai1"},{"output_id":"5c09daebb479fa42o0","input_id":"5c117dad45565142i2"},{"output_id":"5c09daebb479fa42o0","input_id":"5c11aac47c13be4di2"},{"output_id":"5c09daebb479fa42o0","input_id":"5c09632170569341i2"},{"output_id":"5c103c1304436a4fo0","input_id":"5c1cc1660cdcf844i3"},{"output_id":"5c02ba99f6ac424bo0","input_id":"5c0d5a8c7eb9fb4di2"},{"output_id":"5c034e1dc8bd0748o0","input_id":"5c06d13dba0fee41i1"},{"output_id":"5c034e1dc8bd0748o0","input_id":"5c039b81bd78eb4bi0"},{"output_id":"5c1039806c241743o0","input_id":"5c1cc1660cdcf844i3"},{"output_id":"5c034edcb2c7f44ao0","input_id":"5c06d13dba0fee41i0"},{"output_id":"5c034edcb2c7f44ao0","input_id":"5c039b81bd78eb4bi0"},{"output_id":"5c0c86045b101c47o0","input_id":"5c103c1304436a4fi1"},{"output_id":"5c1909a9d1d56b44o0","input_id":"5c04683d4effd14bi1"},{"output_id":"5c1909a9d1d56b44o0","input_id":"5c0c86045b101c47i0"},{"output_id":"5c1909a9d1d56b44o0","input_id":"5c0d5a8c7eb9fb4di0"},{"output_id":"5c117dad45565142o0","input_id":"5c193ad285fa7a46i0"},{"output_id":"5c117dad45565142o1","input_id":"5c1909a9d1d56b44i0"},{"output_id":"5c04683d4effd14bo0","input_id":"5c04773ff8dd9845i1"},{"output_id":"5c193ad285fa7a46o0","input_id":"5c0c86045b101c47i1"},{"output_id":"5c193ad285fa7a46o0","input_id":"5c0d5a8c7eb9fb4di1"},{"output_id":"5c09632170569341o0","input_id":"5c0a52a22b4a5b4bi1"},{"output_id":"5c09632170569341o1","input_id":"5c0a52a22b4a5b4bi0"},{"output_id":"5c02bcd948986c4ao0","input_id":"5c034e1dc8bd0748i1"},{"output_id":"5c0abf6bf8102c4ao0","input_id":"5c0aac8960e8104ai1"},{"output_id":"5c02bbce354bdf46o0","input_id":"5c0a52a22b4a5b4bi2"},{"output_id":"5c0cfcac6da20b4fo0","input_id":"5c0c86045b101c47i2"}],"v":"2"}}}

2 Likes

If you guys like this or find it useful, there are other versions of the ladder. Like I said, this is just a better version of a simple ladder. There’s also the precission ladder commonly found in NES games, the Donkey Kong vine, and the wall ladder that was featured in Metroid Fusion. Those are all very Advanced ladders, so I will never make a tutorial for them, but I may build and showcase them if I use them in my own game. You would basically have to build your whole game around that ladder for it to work. It won’t just copy and paste into any game.

1 Like

Thank you! It works great! I will show my students how to import this bundle.

Also, I wanted to ask how the Player can be enabled to jump on any other sprite that is not labeled Ground since this bundle only allows the Player to jump only on one specific tile named Ground.

Thank you for all your support. I’d really appreciate it.

In the basic Run & Jump bundle, you can just add a new collision to any ground block you may have. like for example if you have an object named grass (not ground) and the play doesn’t seem to jump on it, along with another block, you can just add another collision and it should work.

Just a tip to always have the collisions on the bottom so you can’t jump up walls.

Thank you for your reply! I really appreciate it.
This is the link to a copy of the ladder example made by Mhx_Air, and inside the Logic Lader bundle that I imported I added a Collision box for the other ground block, but the player still doesn’t jump on it.

Thank you again!

Would you please show me how?