How do I create a dash/dodge move?

Get help using Construct 2

Post » Sun Jul 10, 2016 6:47 am

Fairly simple question that might end up having a complex answer, I dunno for sure. I'm looking to create a dash effect for my game a la Mega Man X, but with the player unable to change their direction of movement while dashing. Ideally, what I would like is for the player to speed up when the dash button is tapped while moving in a direction; the player moves at an accelerated pace in that direction for a split second (unable to turn around), and then goes back to their default movement speed. The trouble is, I don't know how to do any part of that. Help would be appreciated!

edit:

Image

I managed to bumble into creating a dash move successfully, my code is... more than a bit messy, but this works as a starting point. Now that I've done that, how do I make it so the player cannot turn left while dashing right, etc? I've tried ignoring player input and simulating the control when the player is in the "dashing" state, but that just stops them in their tracks.
B
18
S
9
Posts: 103
Reputation: 1,817

Post » Sun Jul 10, 2016 8:14 am

Just an update on the situation, I have figured it out, I think.

Image

This works just as I'd like it to! However, if there is a better or more efficient way to do it, feel free to share it here. I'd like to cut down on the clutter if at all possible.
B
18
S
9
Posts: 103
Reputation: 1,817


Return to How do I....?

Who is online

Users browsing this forum: Google [Bot] and 24 guests