From 27728172edefba2017bcdf8e55988c7cc570624a Mon Sep 17 00:00:00 2001 From: SilentSpike Date: Sun, 13 Nov 2016 21:27:40 +0000 Subject: [PATCH] Clarify the `allowDeathMode` setting --- addons/medical/ACE_Medical_StateMachine.hpp | 2 +- addons/medical/XEH_preInit.sqf | 6 +++--- addons/medical/functions/fnc_conditionExecutionDeath.sqf | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/addons/medical/ACE_Medical_StateMachine.hpp b/addons/medical/ACE_Medical_StateMachine.hpp index 82ef3b6c29..dc932e909f 100644 --- a/addons/medical/ACE_Medical_StateMachine.hpp +++ b/addons/medical/ACE_Medical_StateMachine.hpp @@ -67,7 +67,7 @@ class ACE_Medical_StateMachine { class SecondChance { events[] = {QGVAR(FatalInjuryInstantTransition)}; targetState = "CardiacArrest"; - condition = QUOTE(GVAR(allowDeathMode) > 0); + condition = QUOTE(GVAR(fatalInjuryCondition) > 0); onTransition = QUOTE(DFUNC(transitionSecondChance)); }; class Death { diff --git a/addons/medical/XEH_preInit.sqf b/addons/medical/XEH_preInit.sqf index f300d1cd70..62f8c91e84 100644 --- a/addons/medical/XEH_preInit.sqf +++ b/addons/medical/XEH_preInit.sqf @@ -38,13 +38,13 @@ GVAR(STATE_MACHINE) = (configFile >> "ACE_Medical_StateMachine") call CBA_statem ] call CBA_Settings_fnc_init; [ - QGVAR(allowDeathMode), + QGVAR(fatalInjuryCondition), "LIST", - ["Kill unit after", ""], //@todo + ["Allow Fatal Injury", "Governs when a fatal injury can occur."], //@todo "ACE Medical", // @todo [ [0, 1, 2], - ["Fatal wound", "Second chance after fatal wound", "Only cardiac arrest time expiration"], + ["Always", "In Cardiac Arrest", "Never"], 0 ], true diff --git a/addons/medical/functions/fnc_conditionExecutionDeath.sqf b/addons/medical/functions/fnc_conditionExecutionDeath.sqf index 9577365ae3..60934c551f 100644 --- a/addons/medical/functions/fnc_conditionExecutionDeath.sqf +++ b/addons/medical/functions/fnc_conditionExecutionDeath.sqf @@ -13,4 +13,4 @@ #include "script_component.hpp" params ["_unit"]; -(GVAR(allowDeathMode) < 2) && {!(_unit getVariable [QGVAR(deathBlocked), false])} +(GVAR(fatalInjuryCondition) < 2) && {!(_unit getVariable [QGVAR(deathBlocked), false])}