How do I force platform Down Through Jump-Thru action?

Get help using Construct 2

Post » Fri Dec 11, 2015 2:31 pm

Started a new topic as I'm working on a new method that would harness the power of the Jump-Through for stairs without having to enable it or disable the jump-through behavior, which is a benefit to multiple platform movement-based characters based layouts. Here's what I have so far: https://www.dropbox.com/s/5ja6iexdx8i1y ... .capx?dl=0

It *works* if you very carefully walk slowly by nudging the player over the staircase, somehow this misses the tick that calculates the jump-through and allows the character to walk past the stairs. If I could get that condition to always work faster than the jump-through, therefore being able to have the jump-through behavior enabled if the character falls onto the stairs/walks from a platform onto the stairs OR has the up-arrow pressed, it would replace the method of enabling and disabling the solid behavior (of which you can see has been disabled in the events, which is the old way of doing it)

So what I'm asking is, how can I get the check that enables falling-through the jump-thru to work faster than the jump-through behavior is?
B
39
S
12
G
14
Posts: 1,110
Reputation: 11,184

Post » Sat Dec 12, 2015 4:39 pm

I've updated the title in an attempt to make it easier to understand my issue.
B
39
S
12
G
14
Posts: 1,110
Reputation: 11,184

Post » Sun Dec 13, 2015 2:58 pm

Funny thing is, I'm not aware that using the jump-through at an angle in the way I have in this example is causing any glitches, I just literally want to be able to force the "fall through jump-through" faster than the platform engine can try and put the character on the jump-through.
B
39
S
12
G
14
Posts: 1,110
Reputation: 11,184

Post » Tue Dec 15, 2015 4:46 pm

Is there a way of extending the platform movement to ignore all jump-thru per player? Thus allowing stairs to exist per player. Or even for solids.
B
39
S
12
G
14
Posts: 1,110
Reputation: 11,184

Post » Tue Dec 15, 2015 8:50 pm

I'm not 100% sure what you're asking, but taking a look at things I think what you want is the player to go up the stairs if they're pressing the up key, and not to go up the stairs if they're NOT pressing the up key, to this question the answer would be:

Image
B
11
S
3
G
1
Posts: 98
Reputation: 1,062

Post » Tue Dec 15, 2015 10:12 pm

The problem is when solids are enabled or disabled, it affects the enemies that have platform behavior that walk on or under the stairs. I need a way of turning on/off solids/jump-thrus per platform movement.

Which is why my idea of forcing the "fall thru jump thru" event might work, since it's the only character independent way I can think of ignoring a solid without changing the solid's state for everyone.
B
39
S
12
G
14
Posts: 1,110
Reputation: 11,184

Post » Tue Dec 15, 2015 10:56 pm

Well if you take the events you have from your example and increase the offset it appears to work better.

PlayerObject -> Is overlapping SolidTile at offset (0, PlayerObject.Height/2)

is what I used, and it looked ok.
B
11
S
3
G
1
Posts: 98
Reputation: 1,062

Post » Wed Dec 16, 2015 11:50 am

Wow, that actually works! There's a slight lift when the character goes over, but that's not a big deal, is there a way I could counter that by repositioning the player slightly?
B
39
S
12
G
14
Posts: 1,110
Reputation: 11,184

Post » Wed Dec 16, 2015 8:29 pm

One note with my previous solution (a bug I found) -> if you happen to be just at the top of the stair case, so that you're overlapping the platform at the top, but you're still on the staircase, there's a small window (a couple pixels) that can cause you to fall through the stairs if you're going slowly.

As for your other question: You could set the player's position to prevent the re positioning, but doing this could interfere with jumping. (If say, you added a re position to that same event, it would see that the player is near the ground and not pressing up, so therefore it would set the player to be standing on the ground unless they jump higher in 1 frame then your offset (= half the player's height right now).
B
11
S
3
G
1
Posts: 98
Reputation: 1,062

Post » Sat Dec 19, 2015 5:30 pm

Robsta wrote:One note with my previous solution (a bug I found) -> if you happen to be just at the top of the stair case, so that you're overlapping the platform at the top, but you're still on the staircase, there's a small window (a couple pixels) that can cause you to fall through the stairs if you're going slowly.

As for your other question: You could set the player's position to prevent the re positioning, but doing this could interfere with jumping. (If say, you added a re position to that same event, it would see that the player is near the ground and not pressing up, so therefore it would set the player to be standing on the ground unless they jump higher in 1 frame then your offset (= half the player's height right now).


Thanks for that, I've noticed my character falling through the stairs when I implemented it into my game, I'm not sure if it's using jump-thrus for angled stairs that's causing the problem or not. Like you say, it's hard to counter the repositioning without messing up the jumping. I think at this stage this would be the only way of having multiplayer stair posibilities though?
B
39
S
12
G
14
Posts: 1,110
Reputation: 11,184


Return to How do I....?

Who is online

Users browsing this forum: Lanhoj and 8 guests