mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Add pain & painkiller reduction over time
This commit is contained in:
parent
fabecdd0d3
commit
809f6754cc
@ -346,6 +346,7 @@ class CfgVehicles {
|
||||
};
|
||||
|
||||
class ACE_Actions {
|
||||
// @todo morphine, epi, bloodbag actions for basic
|
||||
class ACE_Head {
|
||||
runOnHover = 1;
|
||||
statement = QUOTE([ARR_3(_target, true, 0)] call DFUNC(displayPatientInformation));
|
||||
|
@ -73,6 +73,18 @@ if ([_unit] call EFUNC(common,isAwake)) then {
|
||||
};
|
||||
};
|
||||
|
||||
if (GVAR(level) == 1) then {
|
||||
// reduce pain
|
||||
if (_unit getVariable [QGVAR(pain), 0] > 0) then {
|
||||
_unit setVariable [QGVAR(pain), ((_unit getVariable QGVAR(pain)) - 0.001) max 0, true];
|
||||
};
|
||||
|
||||
// reduce painkillers
|
||||
if (_unit getVariable [QGVAR(morphine), 0] > 0) then {
|
||||
_unit setVariable [QGVAR(morphine), ((_unit getVariable QGVAR(morphine)) - 0.0015) max 0, true];
|
||||
};
|
||||
};
|
||||
|
||||
// handle advanced medical, with vitals
|
||||
if (GVAR(level) >= 2) then {
|
||||
|
||||
|
@ -29,5 +29,3 @@ _pain = ((_target getVariable [QGVAR(pain), 0]) - MORPHINEHEAL) max 0;
|
||||
_target setVariable [QGVAR(pain), _pain, true];
|
||||
|
||||
// @todo overdose
|
||||
|
||||
// @todo pain, painkiller reduction
|
||||
|
Loading…
Reference in New Issue
Block a user