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

@@ -85,11 +85,8 @@ _isPlayer = (isPlayer _source);
if (DZE_PVE_Mode && {_isPlayer} && {!_falling}) exitWith {};
if (_unit == player) then {
//Set player in combat
_unit setVariable["startcombattimer", 1];
if !(_unit getVariable["inCombat",false]) then {
_unit setVariable["inCombat",true,true];
};
//Set player in combat
[_unit,true] call fnc_setCombat;
if (r_player_timeout == 0 && {!_inVehicle}) then {
if (_ammo == "tranquiliser_bolt") then {