Integrate NS Bloodsuckers

Add and update files for bloodsucker spawning option.
This commit is contained in:
worldwidesorrow
2021-08-18 09:47:25 -05:00
parent c10a436c71
commit 05118343fc
20 changed files with 3335 additions and 225 deletions

View File

@@ -1,23 +1,16 @@
private ["_unit","_distance","_doRun","_pos","_listTalk","_zombie","_50","_localtargets","_remotetargets","_targets","_dis"];
_unit = _this select 0;
_distance = _this select 1;
_doRun = _this select 2;
_pos = _this select 3;
_listTalk = _pos nearEntities ["zZombie_Base",_distance];
local _unit = _this select 0;
local _distance = _this select 1;
local _doRun = _this select 2;
local _pos = _this select 3;
{
_distance = _distance max floor(_distance*.9);
_dis = _x distance _unit;
_zombie = _x;
local _dis = _x distance _unit;
call {
if (_dis < 51) exitwith {
if (_doRun) then {
_localtargets = _x getVariable ["localtargets",[]];
_remotetargets = _x getVariable ["remotetargets",[]];
_targets = _localtargets + _remotetargets;
local _localtargets = _x getVariable ["localtargets",[]];
local _remotetargets = _x getVariable ["remotetargets",[]];
local _targets = _localtargets + _remotetargets;
if (!(_unit in _targets)) then {
if !(local _x) then {
_remotetargets set [count _remotetargets,_unit];
@@ -28,16 +21,15 @@ _listTalk = _pos nearEntities ["zZombie_Base",_distance];
};
};
} else {
_zombie setVariable ["myDest",_pos,true];
_x setVariable ["myDest",_pos,true];
};
};
if ((_dis > 50) && {_dis <= 71}) exitwith {
_50 = round(random 100);
if (_50 < 50) then {
if (random 100 < 50) then {
if (_doRun) then {
_localtargets = _x getVariable ["localtargets",[]];
_remotetargets = _x getVariable ["remotetargets",[]];
_targets = _localtargets + _remotetargets;
local _localtargets = _x getVariable ["localtargets",[]];
local _remotetargets = _x getVariable ["remotetargets",[]];
local _targets = _localtargets + _remotetargets;
if (!(_unit in _targets)) then {
if !(local _x) then {
_remotetargets set [count _remotetargets,_unit];
@@ -48,14 +40,14 @@ _listTalk = _pos nearEntities ["zZombie_Base",_distance];
};
};
} else {
_zombie setVariable ["myDest",_pos,true];
_x setVariable ["myDest",_pos,true];
};
} else {
_zombie setVariable ["myDest",_pos,true];
_x setVariable ["myDest",_pos,true];
};
};
if (_dis > 70) exitwith {
_zombie setVariable ["myDest",_pos,true];
_x setVariable ["myDest",_pos,true];
};
};
} count _listTalk;
} count (_pos nearEntities ["Zed_Base",_distance]);