Character Collision Knockback? Platformer.

Get help using Construct 2

Post » Thu May 30, 2013 8:10 pm

I can get my character to jump and bounce off the enemy no problem. Everything works perfect as far as falling and the Y vector. The issue lies in if I am running at the character from left or right. Currently the Character will bump away from the enemy If approached from the left of enemy but walk right through if approached from the right side of enemy. So not both.

Here is a screen cap of what I have down for the collision. (the AI movement was done with the same method as Ashleys "https://www.scirra.com/tutorials/253/how-to-make-a-platform-game")




https://www.dropbox.com/s/x5gyaderon3vf5u/Screencap.png

Thanks for any input!
TodOrcim
B
3
Posts: 4
Reputation: 208

Post » Thu May 30, 2013 8:25 pm

hi !
i did like that, it works !


https://www.dropbox.com/s/6qfnpv91c63ghkv/test.capx



player / X < monster.x / player / set platform vector x to -400

else                    / player / set platform vector x to 400


good luck !

B
18
S
3
Posts: 99
Reputation: 1,376

Post » Thu May 30, 2013 8:54 pm

Sweet so that fixed one Issue. Now I am running into another. Although I can now bump into the enemy from either left or right, it only works if I am comming at him head on with him looking at the character. If you try and come up from behind you still run through. So close!
B
3
Posts: 4
Reputation: 208

Post » Thu May 30, 2013 8:59 pm

look into the capx , this problem is solved to with the same logix and set mirrored.
B
18
S
3
Posts: 99
Reputation: 1,376

Post » Thu May 30, 2013 9:05 pm

Ha yeah I jumped the gun I played around with it. Works perfectly. Thanks A lot!
B
3
Posts: 4
Reputation: 208


Return to How do I....?

Who is online

Users browsing this forum: bigezy80, Laurent, Yahoo [Bot] and 9 guests