Enemy AI

Get help using Construct 2

Post » Tue Nov 27, 2012 12:25 am

Hey guys,

I would upload my updated capx but I'm not near my PC. Just on the one at work. Here is my old capx with the same problem: https://www.dropbox.com/s/ryom0vrmfg6ry9f/Jungle%20Tutorial%20%28Hulk%29.capx


My problem is the "BeeEnemy". I'm glad I got it to follow me, but all 3 three of them copy the original Bee's movement. Example: if the original Bee moves to the right then the other 2 will do that movement, until that Bee is destroyed. How do I make it to where they all have their own individual movements without copying the originals movements without the original having to be destroyed first?

The only idea I have is to make 3 Bee's instead of cloning them after the first one made.

Thanks in advance.
B
23
S
6
G
3
Posts: 122
Reputation: 2,922

Post » Tue Nov 27, 2012 12:55 am

Event 42 uses the distance function and references the position of the bee. You have 3 bees, use a "for each" and event 42 will run for each bee.rfisher2012-11-27 00:56:34
B
17
S
9
G
7
Posts: 249
Reputation: 6,922

Post » Tue Nov 27, 2012 9:14 am

Hey rfisher,

Thanks for the response. I was looking around in event 42 and I'm not sure where exactly "for each" is. Does it come before "sysytem"? I am still very new to this. I hope I'm not asking too much of you.

Thanks for your help.
B
23
S
6
G
3
Posts: 122
Reputation: 2,922

Post » Wed Nov 28, 2012 4:00 am

Hey rFisher,

I figured out how to implement the "For each" and it is better than what I had, but not quite what I want. What you had me do made all the "Bee enemies" attack me if just one "Bee enemy" attacked me.
B
23
S
6
G
3
Posts: 122
Reputation: 2,922


Return to How do I....?

Who is online

Users browsing this forum: GSquadron and 27 guests