From ede072cd5c176c37005a0649de7ee2795fcf03f5 Mon Sep 17 00:00:00 2001 From: commy2 Date: Sun, 15 Apr 2018 12:59:14 +0200 Subject: [PATCH] getMissionConfigValue instead of missionConfigFile --- addons/common/functions/fnc_assignedItemFix.sqf | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/addons/common/functions/fnc_assignedItemFix.sqf b/addons/common/functions/fnc_assignedItemFix.sqf index f7fe02f30c..8e0c518c90 100644 --- a/addons/common/functions/fnc_assignedItemFix.sqf +++ b/addons/common/functions/fnc_assignedItemFix.sqf @@ -15,11 +15,11 @@ */ #include "script_component.hpp" -ACE_isMapEnabled = call {private _config = missionConfigFile >> "showMap"; !isNumber _config || {getNumber _config == 1}}; // default value is 1, so do isNumber check first -ACE_isCompassEnabled = call {private _config = missionConfigFile >> "showCompass"; !isNumber _config || {getNumber _config == 1}}; -ACE_isWatchEnabled = call {private _config = missionConfigFile >> "showWatch"; !isNumber _config || {getNumber _config == 1}}; -ACE_isRadioEnabled = call {private _config = missionConfigFile >> "showRadio"; !isNumber _config || {getNumber _config == 1}}; -ACE_isGPSEnabled = call {private _config = missionConfigFile >> "showGPS"; !isNumber _config || {getNumber _config == 1}}; +ACE_isMapEnabled = getMissionConfigValue ["showMap", 1] in [true, 1]; +ACE_isCompassEnabled = getMissionConfigValue ["showCompass", 1] in [true, 1]; +ACE_isWatchEnabled = getMissionConfigValue ["showWatch", 1] in [true, 1]; +ACE_isRadioEnabled = getMissionConfigValue ["showRadio", 1] in [true, 1]; +ACE_isGPSEnabled = getMissionConfigValue ["showGPS", 1] in [true, 1]; GVAR(AssignedItems) = []; GVAR(AssignedItemsInfo) = [];