Can I make static AI at a specific location hostile to anyone above/below X humanity? X is custom #

DangerRuss

OpenDayZ Rockstar!
Is it possible to set a humanity level in which static AI, at a specific location, will become hostile? For example, if I were to set static AI at a fortress, could I make it soldier AI that will attack anyone above/below X amount of humanity?
 
Should be possible. Just need to locate the file that they target players from and add something like
Code:
PlayerHumanity = (player getVariable"humanity");
if (PlayerHumanity > 0) then {
at the top
 
but wouldn't that encompass ALL of the AI on the server? Or would there be a specific place in the file somewhere that deals solely with the static AI Im adding to a certain location?
 
but wouldn't that encompass ALL of the AI on the server? Or would there be a specific place in the file somewhere that deals solely with the static AI Im adding to a certain location?

Depends on the system you are using. If you are using one that is entirely static AI then it probably would, yes. But if you are using something like DZAI ( that has random spawns as well as static) I'm sure you could do it this way. If for some reason they use the same file to target players, just copy the file name it something else, and use that in the static spawn system with a humanity check.
 
but wouldn't that encompass ALL of the AI on the server? Or would there be a specific place in the file somewhere that deals solely with the static AI Im adding to a certain location?

Of course, it might be simpler to write your own AI framework with this already enabled, rather than try to tear apart one that you possibly have no knowledge of.
 
Im using sarge's AI. I guess its not a huge deal, was just curious if I could make a zone protected by AI against anyone with X amount of humanity. Thanks for the info
 
Im using sarge's AI. I guess its not a huge deal, was just curious if I could make a zone protected by AI against anyone with X amount of humanity. Thanks for the info

I think it'd be easier (and funnier!) if you just placed a humanity activated barrier around that zone, then if your lower, higher, whatever, than the amount you define, you can have it teleport them to a specific area ^.^ say bandits get teleported to an AI infested maze(built by you) heroes get teleported to a loot safe haven, med supplies out the arse, survivors get teleported to a loot city that has been "broken" into by a few AI etc etc :p
 
well first I need to design the fortress, then I need to put static AI there, then I need to put a few ammo crates there, and after that who knows! Im just getting started
 
well first I need to design the fortress, then I need to put static AI there, then I need to put a few ammo crates there, and after that who knows! Im just getting started

Well now that's not too hard at all :p Probably the hardest part of that is the ammo crates! :D Have fun making your bases man, let me know how it turns out!
 
Back
Top