Indentation

This commit is contained in:
Glowbal 2015-03-09 22:27:01 +01:00
parent 6b91cefb90
commit 4b171f9507
3 changed files with 33 additions and 33 deletions

View File

@ -40,19 +40,19 @@ _locations = getArray (_config >> "treatmentLocations");
_return = true;
if (isText (_config >> "Condition")) then {
_condition = getText(_config >> "condition");
if (_condition != "") then {
if (isnil _condition) then {
_condition = compile _condition;
} else {
_condition = missionNamespace getvariable _condition;
};
if (typeName _condition == "BOOL") then {
_return = _condition;
} else {
_return = [_caller, _target, _selectionName, _className] call _condition;
};
};
_condition = getText(_config >> "condition");
if (_condition != "") then {
if (isnil _condition) then {
_condition = compile _condition;
} else {
_condition = missionNamespace getvariable _condition;
};
if (typeName _condition == "BOOL") then {
_return = _condition;
} else {
_return = [_caller, _target, _selectionName, _className] call _condition;
};
};
};
if (!_return) exitwith {false};

View File

@ -19,7 +19,7 @@ if (!local _unit) exitwith {};
_unit setvariable [QGVAR(pain), 0];
if (GVAR(level) >= 2) then {
_unit setvariable [QGVAR(heartRate), 0];
_unit setvariable [QGVAR(bloodPressure), [0, 0]];
_unit setvariable [QGVAR(airwayStatus), 0];
_unit setvariable [QGVAR(heartRate), 0];
_unit setvariable [QGVAR(bloodPressure), [0, 0]];
_unit setvariable [QGVAR(airwayStatus), 0];
};

View File

@ -26,26 +26,26 @@ if (!local _unit) exitwith {
};
if (GVAR(preventInstaDeath) && !_force) exitwith {
if (_unit getvariable [QGVAR(inReviveState), false]) exitwith {}; // already in revive state
_unit setvariable [QGVAR(inReviveState), true, true];
[_unit] call FUNC(setUnconscious);
if (_unit getvariable [QGVAR(inReviveState), false]) exitwith {}; // already in revive state
_unit setvariable [QGVAR(inReviveState), true, true];
[_unit] call FUNC(setUnconscious);
[{
private ["_args","_unit","_startTime"];
_args = _this select 0;
_unit = _args select 0;
_startTime = _args select 1;
[{
private ["_args","_unit","_startTime"];
_args = _this select 0;
_unit = _args select 0;
_startTime = _args select 1;
if (time - _startTime > GVAR(maxReviveTime)) exitwith {
[(_this select 1)] call cba_fnc_removePerFrameHandler;
[_unit, true] call FUNC(setDead);
_unit setvariable [QGVAR(inReviveState), nil, true];
};
if (time - _startTime > GVAR(maxReviveTime)) exitwith {
[(_this select 1)] call cba_fnc_removePerFrameHandler;
[_unit, true] call FUNC(setDead);
_unit setvariable [QGVAR(inReviveState), nil, true];
};
if !(_unit getvariable [QGVAR(inReviveState), false]) exitwith {
[(_this select 1)] call cba_fnc_removePerFrameHandler;
};
}, 1, [_unit, time] ] call CBA_fnc_addPerFrameHandler;
if !(_unit getvariable [QGVAR(inReviveState), false]) exitwith {
[(_this select 1)] call cba_fnc_removePerFrameHandler;
};
}, 1, [_unit, time] ] call CBA_fnc_addPerFrameHandler;
};
_unit setvariable ["ACE_isDead", true, true];