Changed BFT_Enabled to module option for proper ACE_Settings handling

This commit is contained in:
jonpas 2015-06-21 04:46:55 +02:00
parent 10602f10c6
commit 4f35e10afa
4 changed files with 14 additions and 3 deletions

View File

@ -49,6 +49,12 @@ class CfgVehicles {
isGlobal = 1; isGlobal = 1;
icon = PATHTOF(UI\Icon_Module_BFTracking_ca.paa); icon = PATHTOF(UI\Icon_Module_BFTracking_ca.paa);
class Arguments { class Arguments {
class Enabled {
displayName = CSTRING(BFT_Enabled_DisplayName);
description = CSTRING(BFT_Enabled_Description);
typeName = "BOOL";
defaultValue = 0;
};
class Interval { class Interval {
displayName = CSTRING(BFT_Interval_DisplayName); displayName = CSTRING(BFT_Interval_DisplayName);
description = CSTRING(BFT_Interval_Description); description = CSTRING(BFT_Interval_Description);

View File

@ -18,7 +18,6 @@ call FUNC(determineZoom);
((findDisplay 12) displayCtrl 51) ctrlAddEventHandler ["Draw", {[] call FUNC(updateMapEffects);}]; ((findDisplay 12) displayCtrl 51) ctrlAddEventHandler ["Draw", {[] call FUNC(updateMapEffects);}];
}; };
[
["SettingsInitialized", { ["SettingsInitialized", {
// Start Blue Force Tracking if Enabled // Start Blue Force Tracking if Enabled
if (GVAR(BFT_Enabled)) then { if (GVAR(BFT_Enabled)) then {

View File

@ -18,7 +18,7 @@ PARAMS_3(_logic,_units,_activated);
if !(_activated) exitWith {}; if !(_activated) exitWith {};
GVAR(BFT_Enabled) = true; [_logic, QGVAR(BFT_Enabled), "Enabled"] call EFUNC(common,readSettingFromModule);
[_logic, QGVAR(BFT_Interval), "Interval"] call EFUNC(common,readSettingFromModule); [_logic, QGVAR(BFT_Interval), "Interval"] call EFUNC(common,readSettingFromModule);
[_logic, QGVAR(BFT_HideAiGroups), "HideAiGroups"] call EFUNC(common,readSettingFromModule); [_logic, QGVAR(BFT_HideAiGroups), "HideAiGroups"] call EFUNC(common,readSettingFromModule);

View File

@ -77,6 +77,12 @@
<German>Blue Force Tracking</German> <German>Blue Force Tracking</German>
<Czech>Blue Force Tracking</Czech> <Czech>Blue Force Tracking</Czech>
</Key> </Key>
<Key ID="STR_ACE_Map_BFT_Enabled_DisplayName">
<English>Enable</English>
</Key>
<Key ID="STR_ACE_Map_BFT_Enabled_Description">
<English>Enable Blue Force Tracking. Default: No</English>
</Key>
<Key ID="STR_ACE_Map_BFT_Interval_DisplayName"> <Key ID="STR_ACE_Map_BFT_Interval_DisplayName">
<English>Interval</English> <English>Interval</English>
<Polish>Interwał</Polish> <Polish>Interwał</Polish>