Group sounds and zombie calls

dayz_zombieSpeak and player_alertZombies are called often together or should be. fnc_alertZombies groups them together and uses the given parameters. This streamlines and corrects the missing or incorrect calls from dayz_zombieSpeak or player_alertZombies.
This commit is contained in:
AirwavesMan
2020-09-12 01:30:45 +02:00
parent a456c948f5
commit 9ad86a84a3
35 changed files with 193 additions and 205 deletions

View File

@@ -208,6 +208,18 @@ if (!isDedicated) then {
// Advanced trading default inits for maintaining, Advanced Trading and custom scripts to utilize gem based currency.
call compile preprocessFileLineNumbers "\z\addons\dayz_code\actions\AdvancedTrading\defaultInit.sqf";
fnc_alertZombies = {
private ["_unit","_pos","_dis","_sfx"];
_unit = _this select 0;
_pos = _this select 1;
_dis = _this select 2;
_sfx = _this select 3;
[_unit,_sfx,0,false,_dis] spawn dayz_zombieSpeak;
[_unit,_dis,true,_pos] spawn player_alertZombies;
};
dayz_losChance = {
private["_agent","_maxDis","_dis","_val","_maxExp","_myExp"];
_agent = _this select 0;