Preventing AI from shooting traders

BetterDeadThanZed

Valued Member!
What stops the bandits from shooting the traders? I'm setting up some custom missions with DZMS and they are shooting the traders. I understand that with the last version of DZAI, this problem was solved, so I'm curious how it was achieved so I can try to work it into DZMS.
 
In the script that created the traders. Not an epoch user, so a bit foggy on the location. Where the create unit line is, just below that.

I can detail it for you in a few hours when I get home.
 
what file is this located in?
That would be in your dayz_server/mission/mission.sqf file I think. Its in the same folder as your dynamic vehicles, and it has the createagent line for each trader. if you do _this setcaptive true; for each trader they wont be shot at by any enemies.
 
_unit_62 = objNull;
if (true) then
{
_this = _group_1 createUnit ["Dr_Hladik_EP1", [6329.4502, 7781.6753, 0.74679714], [], 0, "CAN_COLLIDE"];
_unit_62 = _this;
_this setDir 486.5495;
_this setVehicleInit "this allowDammage false; this disableAI 'FSM'; this disableAI 'MOVE'; this disableAI 'AUTOTARGET'; this disableAI 'TARGET'; this setBehaviour 'CARELESS'; this forceSpeed 0;";
_this setUnitAbility 0.60000002;
if (false) then {_group_1 selectLeader _this;};
};


_this setcaptive true; goes?
 
where in the script should i put it?
_this = _group_1 createUnit ["Dr_Hladik_EP1", [6329.4502, 7781.6753, 0.74679714], [], 0, "CAN_COLLIDE"];
_this setcaptive true;
_unit_62 = _this;
_this setDir 486.5495;
_this setVehicleInit "this allowDammage false; this disableAI 'FSM'; this disableAI 'MOVE'; this disableAI 'AUTOTARGET'; this disableAI 'TARGET'; this setBehaviour 'CARELESS'; this forceSpeed 0;";
_this setUnitAbility 0.60000002;
if (false) then {_group_1 selectLeader _this;};
};

like this?
 
Back
Top