Jump to content

Recommended Posts

Ive been through so many forums and posts about this topic of enemy AI following players.

I still cant get it right,

All I want is code in the int of the AI who is to hunt the player.

Some of the code i have found works but i cant figure out how to get the AI to constantly update my position so truly follow me.

The only scripts i have found give my original position when the game starts and the enemies move to that point then stay there.

 

Share this post


Link to post
Share on other sites

Thanks for sending me down the right rabbit hole.. 

I am no coder so still had to look around for some ideas, eventually ended up with this

 

1)  In my players init I wrote "team1 = group this" 
2) In OPFOR squadleaders init I wrote "team2 = group this"
3) On a player activated trigger i put on activation   "_stalking = [team2,team1] spawn BIS_fnc_stalk;" 

I have multiple enemy squads dotted around each activated with a different trigger..

This worked perfectly!

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×