mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Reset isLimping var
This commit is contained in:
parent
0ff9a5bf64
commit
4c28c4de22
@ -22,20 +22,23 @@
|
||||
|
||||
private _unit = cursorTarget;
|
||||
if (!(_unit isKindOf "CAManBase")) then {_unit = cursorObject};
|
||||
if (!(_unit isKindOf "CAManBase")) then {_unit = player};
|
||||
if (!(_unit isKindOf "CAManBase")) then {_unit = ACE_player};
|
||||
if ((_unit != ACE_player) && {ACE_player getVariable ["ACE_isUnconscious", false]}) then {_unit = ACE_player};
|
||||
if (!(_unit isKindOf "CAManBase")) exitWith {"No Unit?"};
|
||||
|
||||
private _return = [];
|
||||
|
||||
// Header:
|
||||
_return pushBack format ["<t size='1.2'><t color='#%1'>%2</t> [%3]", (["00FF00", "0000FF"] select (_unit == player)), [_unit] call EFUNC(common,getName), typeOf _unit];
|
||||
_return pushBack format ["<t size='1.2'><t color='#%1'>%2</t> [%3]", (["00FF00", "0000FF"] select (_unit == ACE_player)), [_unit] call EFUNC(common,getName), typeOf _unit];
|
||||
_return pushBack "";
|
||||
|
||||
// State:
|
||||
private _hasStableVitals = [_unit] call EFUNC(medical,hasStableVitals);
|
||||
private _targetState = [_unit, GVAR(STATE_MACHINE)] call CBA_statemachine_fnc_getCurrentState;
|
||||
private _color = switch (_targetState) do {case "Default": {"33FF33"}; case "Injured": {"FF3333"}; case "Unconscious": {"FF8833"}; case "CardiacArrest": {"FF33AA"}; default {"333333"}};
|
||||
_return pushBack format ["<t color='#%1'>State: %2</t> [StableVitals: %3]", _color, _targetState, _hasStableVitals];
|
||||
if (!local _unit) then {_targetState = "NotLocal";};
|
||||
private _color = switch (_targetState) do {case "Default": {"33FF33"}; case "Injured": {"FF3333"}; case "Unconscious": {"FF8833"}; case "CardiacArrest": {"FF33AA"}; default {"555555"}};
|
||||
private _unconcFlag = if (_unit getVariable ["ACE_isUnconscious", false]) then {"[<t color='#FFFFFF'>U</t>]"} else {""};
|
||||
_return pushBack format ["<t color='#%1'>State: %2</t> [StableVitals: %3] %4", _color, _targetState, _hasStableVitals, _unconcFlag];
|
||||
|
||||
// Blood:
|
||||
private _bloodVolume = _unit getVariable [QEGVAR(medical,bloodVolume), DEFAULT_BLOOD_VOLUME];
|
||||
|
@ -34,6 +34,7 @@ _unit setVariable [QGVAR(occludedMedications), nil, true]; //Delayed Medications
|
||||
_unit setVariable [QGVAR(openWounds), [], true];
|
||||
_unit setVariable [QGVAR(bandagedWounds), [], true];
|
||||
_unit setVariable [QGVAR(stitchedWounds), [], true];
|
||||
_unit setVariable [QEGVAR(medical_engine,isLimping), false, true];
|
||||
|
||||
// vitals
|
||||
_unit setVariable [QGVAR(heartRate), DEFAULT_HEART_RATE, true];
|
||||
|
@ -28,6 +28,7 @@ _target setVariable [QGVAR(occludedMedications), nil, true];
|
||||
_target setVariable [QEGVAR(medical,openWounds), [], true];
|
||||
_target setVariable [QEGVAR(medical,bandagedWounds), [], true];
|
||||
_target setVariable [QEGVAR(medical,stitchedWounds), [], true];
|
||||
_target setVariable [QEGVAR(medical_engine,isLimping), false, true];
|
||||
|
||||
// vitals
|
||||
_target setVariable [QEGVAR(medical,heartRate), 80, true];
|
||||
|
Loading…
Reference in New Issue
Block a user