From 90dbb850a76c641a26e59255734d98306f671d42 Mon Sep 17 00:00:00 2001 From: Grim <69561145+LinkIsGrim@users.noreply.github.com> Date: Sat, 19 Oct 2024 02:10:49 -0300 Subject: [PATCH] code cleanup --- .../medical_treatment/functions/fnc_medicationLocal.sqf | 2 +- .../medical_treatment/functions/fnc_onMedicationUsage.sqf | 2 +- addons/medical_treatment/functions/fnc_overDose.sqf | 8 ++++---- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/addons/medical_treatment/functions/fnc_medicationLocal.sqf b/addons/medical_treatment/functions/fnc_medicationLocal.sqf index b5a44051f07..5add34104b9 100644 --- a/addons/medical_treatment/functions/fnc_medicationLocal.sqf +++ b/addons/medical_treatment/functions/fnc_medicationLocal.sqf @@ -70,7 +70,7 @@ private _hrIncreaseLow = GET_ARRAY(_medicationConfig >> "hrIncreaseLow" private _hrIncreaseNormal = GET_ARRAY(_medicationConfig >> "hrIncreaseNormal",getArray (_defaultConfig >> "hrIncreaseNormal")); private _hrIncreaseHigh = GET_ARRAY(_medicationConfig >> "hrIncreaseHigh",getArray (_defaultConfig >> "hrIncreaseHigh")); private _incompatibleMedication = GET_ARRAY(_medicationConfig >> "incompatibleMedication",getArray (_defaultConfig >> "incompatibleMedication")); -private _dose = GET_NUMBER(_medicationConfig >> "dose",getNumber (_defaultConfig >> "dose")); +private _dose = GET_NUMBER(_medicationConfig >> "dose",getNumber (_defaultConfig >> "dose")); private _heartRate = GET_HEART_RATE(_patient); private _hrIncrease = [_hrIncreaseLow, _hrIncreaseNormal, _hrIncreaseHigh] select (floor ((0 max _heartRate min 110) / 55)); diff --git a/addons/medical_treatment/functions/fnc_onMedicationUsage.sqf b/addons/medical_treatment/functions/fnc_onMedicationUsage.sqf index a13a263d498..c79680ace1d 100644 --- a/addons/medical_treatment/functions/fnc_onMedicationUsage.sqf +++ b/addons/medical_treatment/functions/fnc_onMedicationUsage.sqf @@ -45,4 +45,4 @@ if (_maxDose > 0) then { if (_inSystem> _xLimit) then { [_target, _classname] call FUNC(overDose); }; -} forEach _incompatibleMedication; \ No newline at end of file +} forEach _incompatibleMedication; diff --git a/addons/medical_treatment/functions/fnc_overDose.sqf b/addons/medical_treatment/functions/fnc_overDose.sqf index 53966e4120e..6535e4110cc 100644 --- a/addons/medical_treatment/functions/fnc_overDose.sqf +++ b/addons/medical_treatment/functions/fnc_overDose.sqf @@ -17,11 +17,11 @@ */ params ["_unit", "_classname"]; -private _medicationConfig = (configFile >> "ace_medical_treatment" >> _classname); +private _medicationConfig = configFile >> "ace_medical_treatment" >> _classname; private _onOverDose = getText (_medicationConfig >> "onOverDose"); -if (isClass (_medicationConfig)) then { - _medicationConfig = (_medicationConfig >> _classname); +if (isClass _medicationConfig) then { + _medicationConfig = _medicationConfig >> _classname; if (isText (_medicationConfig >> "onOverDose")) then { _onOverDose = getText (_medicationConfig >> "onOverDose"); }; @@ -36,4 +36,4 @@ if (!isNil "_onOverDose" && {isText _onOverDose}) then { } else { _onOverDose = missionNamespace getVariable _onOverDose; }; -[_target, _className] call _onOverDose; +[_target, _className] call _onOverDose