From f603146472a458800291d92e693a56a2603831a6 Mon Sep 17 00:00:00 2001 From: jusola Date: Thu, 28 Mar 2019 10:22:31 +0200 Subject: [PATCH] Added option to use DMS instead of DM in location messages --- CTLD.lua | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/CTLD.lua b/CTLD.lua index 5edd1d6..d0d7afe 100644 --- a/CTLD.lua +++ b/CTLD.lua @@ -127,6 +127,7 @@ ctld.JTAC_smokeColour_BLUE = 1 -- BLUE side smoke colour -- Green = 0 , Red = 1, ctld.JTAC_jtacStatusF10 = true -- enables F10 JTAC Status menu ctld.JTAC_location = true -- shows location of target in JTAC message +ctld.location_DMS = false -- shows coordinates as Degrees Minutes Seconds instead of Degrees Decimal minutes ctld.JTAC_lock = "all" -- "vehicle" OR "troop" OR "all" forces JTAC to only lock vehicles or troops or all ground units @@ -2702,7 +2703,7 @@ function ctld.getFOBPositionString(_fob) local _lat, _lon = coord.LOtoLL(_fob:getPosition().p) - local _latLngStr = mist.tostringLL(_lat, _lon, 3, false) + local _latLngStr = mist.tostringLL(_lat, _lon, 3, ctld.location_DMS) -- local _mgrsString = mist.tostringMGRS(coord.LLtoMGRS(coord.LOtoLL(_fob:getPosition().p)), 5) @@ -3181,7 +3182,7 @@ function ctld.createRadioBeacon(_point, _coalition, _country, _name, _batteryTim local _lat, _lon = coord.LOtoLL(_point) - local _latLngStr = mist.tostringLL(_lat, _lon, 3, false) + local _latLngStr = mist.tostringLL(_lat, _lon, 3, ctld.location_DMS) --local _mgrsString = mist.tostringMGRS(coord.LLtoMGRS(coord.LOtoLL(_point)), 5) @@ -5754,7 +5755,7 @@ function ctld.getPositionString(_unit) local _lat, _lon = coord.LOtoLL(_unit:getPosition().p) - local _latLngStr = mist.tostringLL(_lat, _lon, 3, false) + local _latLngStr = mist.tostringLL(_lat, _lon, 3, ctld.location_DMS) local _mgrsString = mist.tostringMGRS(coord.LLtoMGRS(coord.LOtoLL(_unit:getPosition().p)), 5)