How do I use the path finding behavior correctly?

Get help using Construct 2

Post » Fri Oct 30, 2015 12:17 am

Hello there, I am a student at Royalton High School in Minnesota, and my test on my game is next MONDAY! So I really have to figure this out. So, I am making a standard top down shooter zombie game, and I have a slight major problem. My zombies just can't pathfind the player correctly. It's making me really mad :evil: :evil: I've tried many numerous tutorials but they have all of these extra things, like line of sight, and alerted, etc. ALL I WANT IS SO THAT THE ZOMBIE KNOWS HOW TO WALK AROUND THE BARRIERS AND FOLLOW THE PLAYER INTO THE HOUSE. Here, I posted some pictures (EDIT: Pictures are in the google drive link along with the project.)

EDIT EDIT: Since Scirra Forums are silly and I can't post URLs due to such low rep I can't give you google drive link. So I hope you guys know what im talking about, Im sorry.

If someone can tell me what i need to add or fix, PLEASE let me know, i've gotta fix this. I have also uploaded the whole entire project. So if someone wants to just go ahead and do it and then tell me what I did wrong instead of having a hard time trying to tell me how to do it on the forums, As I have found that easier to do for other people who have had problems.

Thank You All In Advance! :mrgreen: :mrgreen:
B
4
Posts: 6
Reputation: 260

Post » Fri Oct 30, 2015 12:23 am

post your capx as text (without dots)
Image Image
B
23
S
13
G
135
Posts: 871
Reputation: 70,345

Post » Fri Oct 30, 2015 12:26 am

MadSpy wrote:post your capx as text (without dots)

Here, I have to do it like this, so it doesnt get blocked

/open?id=0BwLdV3_jq1_deUxwSzlVY0VXa1E

Add this before you paste the stuff above:

https :/ /drive. google. com

without the space obviously (lol) :D
B
4
Posts: 6
Reputation: 260

Post » Fri Oct 30, 2015 12:39 am

You've got permissions on the file.
ImageImageImage
B
71
S
21
G
232
Posts: 3,696
Reputation: 129,868

Post » Fri Oct 30, 2015 12:41 am

blackhornet wrote:You've got permissions on the file.


Im sorry im a noob :lol:

https ://drive .google .com

/folderview?id=0BwLdV3_jq1_deUxwSzlVY0VXa1E&usp=sharing

tell me if this works
B
4
Posts: 6
Reputation: 260

Post » Fri Oct 30, 2015 1:41 am

Pathfinding is an expensive operation, so "Find path" only starts the algorithm. You need to add an "On pathfinding path found" -> "Move along path".
And, since the target keeps moving, you also need to recall "Find path" every so often, so the zombies update their path.

The built-in Pathfinding demo shows most of this right at the top of the file.
ImageImageImage
B
71
S
21
G
232
Posts: 3,696
Reputation: 129,868

Post » Fri Oct 30, 2015 1:49 am

blackhornet wrote:Pathfinding is an expensive operation, so "Find path" only starts the algorithm. You need to add an "On pathfinding path found" -> "Move along path".
And, since the target keeps moving, you also need to recall "Find path" every so often, so the zombies update their path.

The built-in Pathfinding demo shows most of this right at the top of the file.


why, i suppose. I did look at that Pathfinding demo but it didn't have this one thing I was looking for. Also, how would I update or "recall" the find path. I tried to do "every tick" but it didnt work :cry:
B
4
Posts: 6
Reputation: 260

Post » Fri Oct 30, 2015 2:27 am

Try every 1 second, as a start.
ImageImageImage
B
71
S
21
G
232
Posts: 3,696
Reputation: 129,868


Return to How do I....?

Who is online

Users browsing this forum: Leef and 28 guests