How do I reset jump in "mid-air?" [Platformer Behavior]

Get help using Construct 2

Post » Wed Feb 11, 2015 11:51 am

So I'm using https://www.scirra.com/tutorials/591/a-simple-method-for-climbing-ladders-in-platformers as my basis for ladder use in my platforming game. However, I want a few things that the tutorial doesn't do. Most of them I've figured out myself.

1: Don't let being on a ladder phase through solid objects - fixed by setting platformer vector Y instead of set position
2: Snap to ladder when climbing
3: Allow jumping off the ladder
3a: When jumping and remaining on the ladder, there's a brief pause before beginning climbing again.
3b: Can climb ladder faster by jumping, regrabbing ladder, and jumping again.
4: Can drop off of ladder with Jump + Down

It's 3b I'm having trouble with. I can't figure out how to get the Platformer behavior to 'reset' jump ability if you're not technically landing on the ground.

Any thoughts? I've attached a .capx with everything but 3b demonstrated.
You do not have the required permissions to view the files attached to this post.
B
11
S
4
Posts: 152
Reputation: 1,236

Post » Wed Feb 11, 2015 2:43 pm

You can set the Player platform VectorY to -Player.Platform.JumpStrength to make the player jump. Then you'd probably need to add some extra conditions to prevent the player spamming it.
B
54
S
28
G
18
Posts: 1,520
Reputation: 25,170

Post » Wed Feb 11, 2015 7:00 pm

ramones wrote:You can set the Player platform VectorY to -Player.Platform.JumpStrength to make the player jump. Then you'd probably need to add some extra conditions to prevent the player spamming it.


Actually that fits pretty well with my existing code- [Keyboard -> on space pressed] & [Player -> is Climbing] | [Set Player platform VectorY to -Player.Platform.JumpStrength]- and Climbing doesn't get reset until the player regrabs onto the ladder.
You do not have the required permissions to view the files attached to this post.
B
11
S
4
Posts: 152
Reputation: 1,236


Return to How do I....?

Who is online

Users browsing this forum: lamar and 0 guests