Slide action while keeping platform behavior.

Get help using Construct 2

Post » Thu Feb 21, 2013 2:07 pm

While trying to just remake a basic MegaMan NES clone to get even more comfortable with C2 I have come to a halt as I am running into a constant problem, And I do not understand it at all. Whenever I collide with anything while sliding to the left (only happens when sliding to the left and not the right) the player will "climb" whatever he is colliding with, be it a wall or the enemy. when colliding with the same object on the right it functions normally and he just stops moving forward.

Any idea as to why this is happening? I have gone over the events many times I cannot find anything that would do that.

How the slide portion of the event sheet looks right now.


I have been bothered by this for a while now and I am at complete lost as to why it only happens when sliding left and not right.

I have both an online playable version and the .capx uploaded, just look at the group "Slide" for all the events related to that action but everything is as clean as i could make it, lots of comments explaining what i was trying to do for each step.

Link to play online

Link to download .capx


EDIT: I forgot the controls are simple "Z" jumps "X" shoots, hold "X" for a charged shot (currently does not hurt any enemies when charged) BACLog2013-02-21 14:32:31
B
23
S
6
G
1
Posts: 82
Reputation: 2,398

Post » Fri Feb 22, 2013 4:44 pm

Did you tried changing that ELSE statement to an Inverted "Is mirrored"?

Don't know if that helps. Maybe it has to do with image points. I can't check your capx right now and I'm not that experienced in Construct also.

I'll try giving it a look when I get home.
B
20
S
5
G
3
Posts: 53
Reputation: 3,310

Post » Fri Feb 22, 2013 5:02 pm

Yep , you should try scary pumpkin suggestion ...
I'll give it a look as soon as I get to my PCWhiteclaws2013-02-22 17:04:34
B
35
S
16
G
16
Posts: 2,222
Reputation: 16,589

Post » Fri Feb 22, 2013 5:24 pm

Doesn't completely remove it but makes it unnoticeable ...

MegaFixed

Cheers ...Whiteclaws2013-02-22 17:24:53
B
35
S
16
G
16
Posts: 2,222
Reputation: 16,589

Post » Fri Feb 22, 2013 5:39 pm

@BAClog - your slide left condition is setting the x of the player, which if they are moving they will just phase up and over stuff (this is how the endless runner illusion is achieved, they never get stuck on anything by constantly setting the X of the player)
B
14
S
6
G
2
Posts: 136
Reputation: 3,210

Post » Fri Feb 22, 2013 10:58 pm

[QUOTE=Whiteclaws] Doesn't completely remove it but makes it unnoticeable ...

MegaFixed

Cheers ...[/QUOTE]

Thank you Whiteclaws, I appreciate it.
I would never even have thought to go that route as I was so focused on how the right direction worked fine but the left did not what so ever.

On another note, i added to the instance where you set the global on down press to player.y+8 and it is even less noticable
B
23
S
6
G
1
Posts: 82
Reputation: 2,398

Post » Mon Feb 25, 2013 6:27 am

i am totally new to construct, but was messing with your slide a bit when making my own, and i completely got rid of the wall sliding by doing this below. seems like a hack, but works.
B
3
Posts: 3
Reputation: 656

Post » Mon Feb 25, 2013 4:50 pm

Hey,
Instead of using player.x you should use the platform's Vector X to move the player.
Do not ignore the platform input; instead set the necessary parameters to disable jumping, etc.


And finally, don't forget to restore those parameters :)


Here's the LINK TO DOWNLOAD to the sample of my solution.
B
6
S
1
Posts: 11
Reputation: 934

Post » Mon Feb 25, 2013 8:31 pm

Xavy has a very good solution since it works with the platform plugin, not against like manual +/- of x

If you want to ignore user movement, I suggest making it trigger an event (disablecontrols false/true) and on the control actions, have it check to make sure it's false.

-On Right down
-disabled controls is false
--Simulate Platform Right
B
15
S
4
G
4
Posts: 294
Reputation: 3,225

Post » Tue Feb 26, 2013 8:05 am

[QUOTE=xavy027] Hey,
Instead of using player.x you should use the platform's Vector X to move the player.
Do not ignore the platform input; instead set the necessary parameters to disable jumping, etc.


And finally, don't forget to restore those parameters :)


Here's the LINK TO DOWNLOAD to the sample of my solution.[/QUOTE]

this has solved so many things i cant even explain to you, haha i have been having trouble using the X vector for various purpose as it seemed to only move the player a short distance if any, i guess its the deceleration set to 0 stops the action from stopping after the short burst of movement. thank you very much for all the input.
B
23
S
6
G
1
Posts: 82
Reputation: 2,398

Next

Return to How do I....?

Who is online

Users browsing this forum: No registered users and 23 guests