i have a server got custom buildings etc
Now i wanne ad ai bandits to 2 or 3 locations to guard it walking small patrol .
i want them to shoot at everybody .before players can loot the place how can i add something like this ?
Simple solution would be set a trigger (don't be a noob and use the editor for this). Have a trigger set to detect players within say 300 meters, if that player uid isn't you, then the AI that you've set around your camp (using a script) are set to the EAST faction, which makes them hostile to real players. Now, if you enter the zone their faction resets to WEST, making them friendly again.
The way I do this for my custom missions (I have a hostage mission in a hotel at Cherno for example that requires AI to be inside, which Arma is crap at doing) is add invisible helipads to key spots within the building or the area I'm looking at placing the AI, then I use a script to count the invisible helipads, put their coords into an array then spawn one unit per coordinate (I have 30 missions like this, all involving AI occupying buildings. I aslo never spawn a leader, so the AI stay put and act independently.. The only disadvantage to this is that they wont follow waypoints). Alternatively, you could find the central coords for your base and spawn AI randomly around it by a set distance, which you'd need to work out.
Now one last thing to consider, Battleye.. Changing the side of your AI might cause kicks, running scripts in general can to if you don't know what you're doing. What you're asking is no easy task, anyone who say it is should put their money where their mouth is and get you that script..
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.