mirror of
https://github.com/EpochModTeam/DayZ-Epoch.git
synced 2025-12-21 10:56:29 +03:00
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:
@@ -38,7 +38,7 @@ else { _weapon = Player_GetSidearm(); if (isNil "_weapon") then { "" } else { _w
|
||||
if (_weapon == "") exitWith
|
||||
{
|
||||
closedialog 0;
|
||||
|
||||
|
||||
localize
|
||||
(
|
||||
if ((_this select 1) == 1)
|
||||
@@ -54,7 +54,7 @@ _config = configFile >> "CfgWeapons" >> _weapon >> "Attachments";
|
||||
if (!isClass(_config) || {!isText(_config >> _attachment)}) exitWith
|
||||
{
|
||||
closeDialog 0;
|
||||
|
||||
|
||||
localize
|
||||
(
|
||||
if ((_this select 1) == 1)
|
||||
@@ -66,7 +66,7 @@ if (!isClass(_config) || {!isText(_config >> _attachment)}) exitWith
|
||||
_newWeapon = getText (_config >> _attachment);
|
||||
_weaponInUse = (currentWeapon player == _weapon);
|
||||
|
||||
[player,"attach_weap",0,false] call dayz_zombieSpeak;
|
||||
[player,(getPosATL player),10,"attach_weap"] spawn fnc_alertZombies;
|
||||
call gear_ui_init;
|
||||
player playActionNow "Medic";
|
||||
|
||||
@@ -82,7 +82,7 @@ player addWeapon _newWeapon;
|
||||
if (_weaponInUse) then
|
||||
{
|
||||
_muzzle = (getArray (configFile >> "CfgWeapons" >> _newWeapon >> "muzzles")) select 0;
|
||||
|
||||
|
||||
if (_muzzle == "this") then
|
||||
{
|
||||
player selectWeapon _newWeapon;
|
||||
@@ -91,4 +91,4 @@ if (_weaponInUse) then
|
||||
{
|
||||
player selectWeapon _muzzle;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user