Difference between revisions of "DCS func LLtoMGRS"
From DCS World Wiki - Hoggitworld.com
m (1 revision imported) |
|||
(2 intermediate revisions by the same user not shown) | |||
Line 9: | Line 9: | ||
|par2= | |par2= | ||
− | |desc= Returns an MGRS table from the latitude and longitude coordinates provided. | + | |desc= Returns an MGRS table from the latitude and longitude coordinates provided. Note that in order to get the MGRS coordinate from a vec3 you must first use [[DCS_func_LOtoLL|coord.LOtoLL]] on it. |
|rtnType= MGRS table | |rtnType= MGRS table | ||
Line 46: | Line 46: | ||
[[DCS_singleton_coord|'''Coord Functions:''']] {{listOfCoordFuncs}} | [[DCS_singleton_coord|'''Coord Functions:''']] {{listOfCoordFuncs}} | ||
− | |examples= | + | |examples= The following will output the full returned value as a string. |
+ | local grid = coord.LLtoMGRS(coord.LOtoLL(Unit.getByName('bobTheTarget'):getPoint())) | ||
+ | local s = grid.UTMZone .. ' ' .. grid.MGRSDigraph .. ' ' .. grid.Easting .. ' ' .. grid.Northing | ||
+ | trigger.action.outText(s, 20) | ||
|notes= | |notes= | ||
}} | }} | ||
[[Category:Singleton Functions|LLtoMGRS]] | [[Category:Singleton Functions|LLtoMGRS]] | ||
+ | [[Category:Game Patch 1.2.0|LLtoMGRS]] |