private array updates + fixes

This commit is contained in:
vbawol
2013-05-26 12:23:31 -05:00
parent 04393b3383
commit 59905c1d18
123 changed files with 268 additions and 260 deletions

View File

@@ -1,18 +1,19 @@
private["_unit","_targets","_move","_damage","_wound","_index","_cnt","_sound","_local","_dir","_hpList","_hp","_strH","_dam","_total","_vehicle","_tPos","_zPos","_cantSee","_inAngle"];
private ["_unit","_targets","_move","_damage","_wound","_index","_cnt","_dir","_hpList","_hp","_strH","_dam","_total","_vehicle","_tPos","_zPos","_cantSee","_inAngle","_rnd","_openVehicles","_chance","_attackanimations","_type"];
_unit = _this select 0;
_type = _this select 1;
_vehicle = (vehicle player);
_targets = _unit getVariable ["targets",[]];
//if (!(_vehicle in _targets)) exitWith {};
if (dayz_zedsAttackVehicles and !(_vehicle in _targets)) exitWith {};
//Do the attack
if (r_player_unconscious && _vehicle == player && _type == "zombie") then {
_rnd = round(random 4) + 1;
_rnd = (round(random 4)) + 1;
_move = "ZombieFeed" + str(_rnd);
} else {
if (_type == "zombie") then {
_rnd = round(random 9) + 1;
_rnd = (round(random 9)) + 1;
_move = "ZombieStandingAttack" + str(_rnd);
} else {
_move = "Dog_Attack";