Update combat handling

- Remove startcombattimer variable
- Add combatNoTimeout variable to handle a combat without a time limit
This commit is contained in:
A Man
2022-06-26 15:57:15 +02:00
parent 36f5c8707a
commit b6c7364c56
11 changed files with 122 additions and 137 deletions

View File

@@ -15,7 +15,7 @@ local _foodVal = 1 - (dayz_hunger / SleepFood);
local _thirstVal = 1 - (dayz_thirst / SleepWater);
local _tempVal = 1 - ((dayz_temperatur - dayz_temperaturmin)/(dayz_temperaturmax - dayz_temperaturmin)); // Normalise to [0,1]
local _bloodVal = r_player_blood / r_player_bloodTotal;
local _combatVal = if (player getVariable["combattimeout",0] >= diag_tickTime) then {0} else {1};
local _combatVal = if ((player getVariable["combatTimeout",0] >= diag_tickTime) || (player getVariable["combatNoTimeout", 0] == 1)) then {0} else {1};
local _ctrlBloodOuter = 0;
local _ctrlFoodBorder = 0;
local _ctrlThirstBorder = 0;