How do I Prevent "Falling" Unless after a Jump?

Get help using Construct 2

Post » Thu Sep 25, 2014 3:37 am

My problem is pretty straight forward. Because planets are round, player is always 'falling' for short millisecond bursts when i run really rapidly around the surface of the planet. basically whenever the player hits a 'peak' of the collision box since it's not a perfect smooth circle, he can technically 'fall' off the edge of the earth for just one split second.

The problem with this is that if i happen to push the jump button just as that platform 'falling' animation state is triggered, the guy wont jump.. so in the hear of battle, there's basically a 5% ish chance that your jump wont register...

Is there some way to 'disable' the falling state unless i specifically say to use it.. i realize that's a roundabout way to solve the problem, but short of programming my own platform controls entirely, which id much rather not do, i dont know how else to really work around it...

Does anyone have any thoughts or advice? Is what i mentioned making any sense even?
Made Cosmochoria - www.cosmochoria.com
Currently working on Slayaway Camp - www.slayawaycamp.com
B
27
S
8
G
3
Posts: 384
Reputation: 5,020

Post » Thu Sep 25, 2014 4:25 am

maybe you could set the platform gravity really high EXCEPT for when you're jumping, so he falls so fast this can't happen?

lowering the collisions peaks a possibility?

it's not so much you want to disable falling, it's not directly the falling stopping you from jumping, it's just that your feet aren't on the ground. I don't know if that helps. I'll think on it some more...
B
86
S
43
G
71
Posts: 601
Reputation: 43,619

Post » Thu Sep 25, 2014 4:45 am

Yeah i tried setting gravity to 5000 when on the ground, it seemed to help a lil bit and then triggered gravity to flip to 1000 on jump. Ive also been trying to reduce the collision peaks, but we're talking circles and im already dealing with 32 collision points just to keep it relatively smooth.

Thank you tho great ideas, still getting little blips tho.. Gonna try jacking the gravity up to like 10k now hahah
Made Cosmochoria - www.cosmochoria.com
Currently working on Slayaway Camp - www.slayawaycamp.com
B
27
S
8
G
3
Posts: 384
Reputation: 5,020

Post » Thu Sep 25, 2014 4:53 am

Yeah 30k gravity all but eliminates it on the small planets where the resolution of the collision shape is more 'round'... On the bigger planets when the points are more spaced out and actual 'peaks' happen, i still get the odd 'fall' every once in a while. It's way better than it was now, and only the big planets are an issue now... What i would give for round collision shapes like unity, tho. damn.
Made Cosmochoria - www.cosmochoria.com
Currently working on Slayaway Camp - www.slayawaycamp.com
B
27
S
8
G
3
Posts: 384
Reputation: 5,020

Post » Fri Sep 26, 2014 12:39 am

30k, huh? sheesh! If it were me, I'd probably just go ahead and make my own platform jump function..
Good luck!
B
86
S
43
G
71
Posts: 601
Reputation: 43,619

Post » Fri Sep 26, 2014 1:13 am

Dont do a collision check, do an overlap check.
B
28
S
8
G
1
Posts: 226
Reputation: 2,865

Post » Fri Sep 26, 2014 5:12 am

Tylermon wrote:Dont do a collision check, do an overlap check.


Can you explain @Tylermon? It's the collision checks built into the platform behaviour. it's more along the lines of the animation types than the collision types... ie "Falling" "Moving" "Jumping" and "Standing" if you know what i mean..?

Thanks guys. Will probably just write my own jump. :)
Made Cosmochoria - www.cosmochoria.com
Currently working on Slayaway Camp - www.slayawaycamp.com
B
27
S
8
G
3
Posts: 384
Reputation: 5,020

Post » Fri Sep 26, 2014 6:23 am

80bit wrote:
Tylermon wrote:Dont do a collision check, do an overlap check.


Can you explain @Tylermon? It's the collision checks built into the platform behaviour. it's more along the lines of the animation types than the collision types... ie "Falling" "Moving" "Jumping" and "Standing" if you know what i mean..?

Thanks guys. Will probably just write my own jump. :)


You would have to apply a speed/force of your own. Don't use the default jump behavior. But using an overlap check, should be better than a collision check for a circle, because it will more accurately represent the shape.

not checking of course, if the player can walk on it. Use a collision for that. But check if they can jump using the overlap.

hopefully that makes sense? I can try saying it differently maybe, my brain is a bit tired haha. Been delving into the realms of multiplayer and wrapping my head around that sort of has my focus haha.
B
28
S
8
G
1
Posts: 226
Reputation: 2,865

Post » Fri Sep 26, 2014 6:26 am

Awesome, yeah I think i know what you mean: if overlapping circle shape, and jump button pressed: do jump function.
Made Cosmochoria - www.cosmochoria.com
Currently working on Slayaway Camp - www.slayawaycamp.com
B
27
S
8
G
3
Posts: 384
Reputation: 5,020

Post » Tue Sep 30, 2014 7:45 am

Yeah still having issues with this because now i want to have a different falling animation vs. standing / walking so its triggering the falling animation whenever he's hitting those spots, even just for a sec. So even if i re-write the jump it's going to be an issue with the falling animation... i wish i could think of some other way to basically 'not trigger' falling, unless a jump has been detected...

@Ashley - is there any way to force a platform animation?

thx guys
Made Cosmochoria - www.cosmochoria.com
Currently working on Slayaway Camp - www.slayawaycamp.com
B
27
S
8
G
3
Posts: 384
Reputation: 5,020

Next

Return to How do I....?

Who is online

Users browsing this forum: Lancifer and 14 guests