Small ZombieSpawner fixes

This commit is contained in:
He-Man 2020-08-03 17:53:30 +02:00
parent 496bb8aae1
commit be579db029
3 changed files with 2 additions and 1 deletions

View File

@ -65,6 +65,7 @@ _ZedSpawnCheck = {
if ({vehicle _target iskindof _x} count BlackListedVehicles > 0) exitwith {};
if (speed (vehicle _target) > 25) exitwith {};
if ({_x distance2d _target < 150} count (missionnamespace getvariable ["Epoch_Plotpoles",[]]) > 0) exitwith {};
if ({_x distance2d _target < 300} count NoZedAreas > 0) exitwith {};
_OverallZeds = (entities [["EPOCH_RyanZombie_1","RyanZombieCivilian_F"],[],true,false]);
_AliveZeds = _OverallZeds select {alive _x};
if ((count _AliveZeds) <= MaxOverallZeds) then {

View File

@ -25,8 +25,8 @@ if !(isclass (configFile >> "CfgPatches" >> "Ryanzombies")) exitwith {};
_dir = direction _zombie;
_strength = _zombie call RZ_fnc_zombie_getHumanVelocityStrength;
[_target, [(_vel select 0) + (sin _dir * _strength), (_vel select 1) + (cos _dir * _strength), (_vel select 2) + random 1]] remoteExecCall ["fnc_RyanZombies_Velocity"];
[] remoteexec ['Epoch_ZedAttack',_target];
};
[] remoteexec ['Epoch_ZedAttack',_target];
sleep _attackSpeed;
};
RZ_fnc_zombie_checkForNewTarget =