How do i make the enemy always follow the player?

Get help using Construct 2

Post » Wed Oct 11, 2017 5:01 pm

So i'm making a 2d, 2 directional game, how can i make the enemies in the game always follow the player while still maintaining their platform behaviour? I have tried countless methods from simulating control to path finding but none of them seem to work the way i want them to... :|

Is there a way to make them always follow the player, even if he's above them or below them? :?:
Another thing is how can i make them jump?? I tried triggers that stimulate jump but they don't work if they are put against a solid, don't ask me how i have no idea :lol:

Here is a video:https://youtu.be/bKfQ7-fHFac
In the video i'm using the "Move front" action to move the player, pathfinding works better but is VERY glitchy.

Thanks :)
B
2
Posts: 2
Reputation: 154

Post » Wed Oct 11, 2017 7:39 pm

Hey there! I think these might be able to help in general!

https://www.dropbox.com/s/gi069efukrc0o ... .capx?dl=0
https://www.dropbox.com/s/motun4pvo9whd ... .capx?dl=0
https://www.dropbox.com/s/9pscwbjmhy9fy ... .capx?dl=0

You'll find lots of useful files searching through the forums and tutorial page! These should answer your questions except maybe getting an enemy to both follow and jump if the player is on a higher ledge. I imagine you need to run some sort of check to figure out if the player is above a certain Y value in relation to the enemy then jump. I'm actually pretty sure I've seen a capx like that floating on the forums too :lol: Anyway, hope these help!
B
30
S
15
G
22
Posts: 183
Reputation: 14,221

Post » Thu Oct 12, 2017 10:59 am

Thx!
B
2
Posts: 2
Reputation: 154


Return to How do I....?

Who is online

Users browsing this forum: 25games, Ashley and 20 guests