Help with Double Jump

Get help using Construct 2

Post » Wed Aug 20, 2014 4:21 pm

Ok, this is causing a lot more headache than it should so i guess i'll leave it then :)

The issue i had with this is that because the game is so fast (my one is, not necessarily this capx), you can easily run/fall off a platform without realising it and can only do one jump when you're trying to do a double jump, which can be frustrating. So what i now want to do is create an animation that plays when the player falls/runs of the platform, this way it can be seen as an indication that you can only do one jump when this animation plays.

I've created an animation for my character but the problem is that i can't seem to distinguish when the player as fallen off the platform from when the player is falling from a jump.

I've created the following event but it hasn't worked for me:

Player - Platform is falling - Set player animation to "falling"

The animation plays but it also plays when the player is falling from a jump (which i understand, but as i mention, i can't distinguish when the player as fallen off the platform from when the player is falling from a jump)

Is there i can make this animation play only when the player falls/runs off the platform and not when the player is fallling from a jump?

I've posted an edited capx where i've added a falling animation (player is just turned upside down) to the existing capx.
You do not have the required permissions to view the files attached to this post.
B
5
S
2
Posts: 116
Reputation: 867

Post » Wed Aug 20, 2014 4:48 pm

should be as simple as setting a variable on jump and resetting it on landed..

So player is falling and variable is not set would be falling of platform

and

player is falling and variable is set would mean falling after jumping..
I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Post » Thu Aug 21, 2014 3:50 pm

@LittleStain I'm trying it but i can't get it to work. My double jump disappears when i try this and the animation doesn't set.

I reckon it's because i'm doing it wrong :)

Could you perhaps show me how it's done with the capx i provided please?
B
5
S
2
Posts: 116
Reputation: 867

Post » Thu Aug 21, 2014 3:56 pm

just adjusted the jump values..

jump1 is now 1 doublejump is now 2

only play falling if jump = 0
You do not have the required permissions to view the files attached to this post.
I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Post » Thu Aug 21, 2014 4:16 pm

Thanks, that kind of works but now i can do unlimited jumping if i constantly click, which i don't want. Also, i'm not able to do a jump while the falling animation is playing unless its a double click...
B
5
S
2
Posts: 116
Reputation: 867

Post » Thu Aug 21, 2014 4:34 pm

All that is left for you to do is to change the animation, when jumping from fall..
You do not have the required permissions to view the files attached to this post.
I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Post » Thu Aug 21, 2014 6:05 pm

@LittleStain Thank you, not only have you fixed this issue, you've actually fixed the original issue i was having with the double jump :)

You're a legend mate, thanks again!
B
5
S
2
Posts: 116
Reputation: 867

Post » Thu Aug 21, 2014 7:55 pm

No problem, while I was busy I suddenly realized that the original issue was rightv around the corner to be fixed, so why not make that turn.. :)

They are actually planning to make a movie about me after I die:

"The legend of the famously unknown Little Stain.." :p
I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Previous

Return to How do I....?

Who is online

Users browsing this forum: R0J0hound, StillSarah and 31 guests