diff --git a/addons/map/CfgVehicles.hpp b/addons/map/CfgVehicles.hpp index b8d3a54d96..612cadb006 100644 --- a/addons/map/CfgVehicles.hpp +++ b/addons/map/CfgVehicles.hpp @@ -36,6 +36,15 @@ class CfgVehicles { class No { name = "No"; value = 0; default = 1;}; }; }; + class MapShowCursorCoordinates { + displayName = "Show cursor coordinates?"; + description = "Show the grid coordinates on the mouse pointer?"; + typeName = "BOOL"; + class values { + class Yes { name = "Yes"; value = 1; }; + class No { name = "No"; value = 0; default = 1;}; + }; + }; }; }; diff --git a/addons/map/XEH_postInitClient.sqf b/addons/map/XEH_postInitClient.sqf index f60fb696f6..c6a2c572ad 100644 --- a/addons/map/XEH_postInitClient.sqf +++ b/addons/map/XEH_postInitClient.sqf @@ -20,13 +20,13 @@ call FUNC(determineZoom); }; // Note: doesn't work on postInit in SP, therefore use default setting -(findDisplay 12 displayCtrl 1016) ctrlShow (GETGVAR(showPositionOnCursor,false)); +(findDisplay 12 displayCtrl 1016) ctrlShow GVAR(mapShowCursorCoordinates); ["mapDisplayLoaded", { //hint str _this; systemChat str _this; diag_log str _this; if (_this select 1 == "ingame") then { - ((_this select 0) displayCtrl 1016) ctrlShow (GETGVAR(showPositionOnCursor,false)); + ((_this select 0) displayCtrl 1016) ctrlShow GVAR(mapShowCursorCoordinates); }; }] call FUNC(addEventhandler); diff --git a/addons/map/config.cpp b/addons/map/config.cpp index e544a67c12..d9dae47bd3 100644 --- a/addons/map/config.cpp +++ b/addons/map/config.cpp @@ -48,6 +48,10 @@ class ACE_Settings { value = 0; typeName = "BOOL"; }; + class GVAR(mapShowCursorCoordinates) { + value = 0; + typeName = "BOOL"; + }; }; #include "CfgEventHandlers.hpp" diff --git a/addons/map/functions/fnc_moduleMap.sqf b/addons/map/functions/fnc_moduleMap.sqf index b6e556c92e..a22bbbb385 100644 --- a/addons/map/functions/fnc_moduleMap.sqf +++ b/addons/map/functions/fnc_moduleMap.sqf @@ -15,8 +15,9 @@ _activated = _this select 2; if !(_activated) exitWith {}; -[_logic, QGVAR(mapIllumination), "MapIllumination"] call EFUNC(common,readSettingFromModule); -[_logic, QGVAR(mapShake), "MapShake" ] call EFUNC(common,readSettingFromModule); -[_logic, QGVAR(mapLimitZoom), "MapLimitZoom" ] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(mapIllumination), "MapIllumination" ] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(mapShake), "MapShake" ] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(mapLimitZoom), "MapLimitZoom" ] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(mapShowCursorCoordinates), "MapShowCursorCoordinates"] call EFUNC(common,readSettingFromModule); diag_log text "[ACE]: Interaction Module Initialized.";