Remove some redundant checks

Vanilla commits:

da7061429a

da55eaa53e
This commit is contained in:
ebaydayz
2017-01-29 19:36:48 -05:00
parent 3224a21363
commit 8c1caa9c1c
19 changed files with 33 additions and 25 deletions

View File

@@ -1,5 +1,5 @@
scriptName "Functions\misc\fn_damageActions.sqf";
if (dayz_actionInProgress) exitWith {};
#include "\z\addons\dayz_code\util\array.hpp";
/***********************************************************

View File

@@ -4,7 +4,6 @@ scriptName "Functions\misc\fn_selfActions.sqf";
- Function
- [] call fnc_usec_selfActions;
************************************************************/
if (dayz_actionInProgress) exitWith {};
private ["_canPickLight","_text","_unlock","_lock","_totalKeys","_temp_keys","_temp_keys_names",
"_hasKey","_oldOwner","_hasAttached","_isZombie","_isHarvested","_isMan","_isFuel","_hasRawMeat","_hastinitem","_player_deleteBuild",
"_player_lockUnlock_crtl","_displayName","_hasIgnitors","_menu","_menu1","_allowTow","_liftHeli","_found","_posL","_posC","_height","_attached",

View File

@@ -43,7 +43,7 @@ _difference = 0;
_isinbuilding = false;
_isinvehicle = false;
_raining = if(rain > 0) then {true} else {false};
_raining = (rain > 0);
_sunrise = call world_sunRise;
//POSITIV EFFECTS

View File

@@ -23,9 +23,9 @@ if (time - dayz_lastCheckSave > 10) then {
while {(!isNull _display) && !r_player_dead} do {
_timeout = 30;
_timeout = player getVariable["combattimeout", 0];
_inCombat = if (_timeout >= diag_tickTime) then {true} else {false};
_playerCheck = if ({isPlayer _x} count (player nearEntities ["AllVehicles",5]) > 1) then {true} else {false};
_zedCheck = if ((count (player nearEntities ["zZombie_Base",10]) > 0) && !_isPZombie) then {true} else {false};
_inCombat = (_timeout >= diag_tickTime);
_playerCheck = ({isPlayer _x} count (player nearEntities ["AllVehicles",5]) > 1);
_zedCheck = ((count (player nearEntities ["zZombie_Base",10]) > 0) && !_isPZombie);
_gearDisplay = findDisplay 106;
if (!isNull _gearDisplay) then {
_gearDisplay closeDisplay 0;