mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Changed MicroDAGR position and target display to 10-digit grids
This commit is contained in:
parent
2dd42f828d
commit
8d61b42e87
@ -15,7 +15,7 @@
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_display", "_waypoints", "_posString", "_eastingText", "_northingText", "_numASL", "_aboveSeaLevelText", "_compassAngleText", "_targetPosName", "_targetPosLocationASL", "_bearingText", "_rangeText", "_targetName", "_bearing", "_2dDistanceKm", "_SpeedText", "_playerPos2d", "_wpListBox", "_currentIndex", "_wpName", "_wpPos", "_settingListBox", "_yearString", "_monthSring", "_dayString"];
|
||||
private ["_display", "_waypoints", "_posString", "_eastingText", "_northingText", "_numASL", "_aboveSeaLevelText", "_compassAngleText", "_targetPos", "_targetPosName", "_targetPosLocationASL", "_bearingText", "_rangeText", "_targetName", "_bearing", "_2dDistanceKm", "_SpeedText", "_playerPos2d", "_wpListBox", "_currentIndex", "_wpName", "_wpPos", "_settingListBox", "_yearString", "_monthSring", "_dayString"];
|
||||
|
||||
disableSerialization;
|
||||
_display = displayNull;
|
||||
@ -33,13 +33,9 @@ _waypoints = [] call FUNC(deviceGetWaypoints);
|
||||
switch (GVAR(currentApplicationPage)) do {
|
||||
case (APP_MODE_INFODISPLAY): {
|
||||
//Easting/Northing:
|
||||
_posString = mapGridPosition ACE_player;
|
||||
_eastingText = "";
|
||||
_northingText = "";
|
||||
if (count _posString > 0) then {
|
||||
_eastingText = (_posString select [0, ((count _posString)/2)]) + "e";
|
||||
_northingText = (_posString select [(count _posString)/2, (count _posString - 1)]) + "n";
|
||||
};
|
||||
_posString = [getPos ACE_player] call EFUNC(map,getMapGridFromPos);
|
||||
_eastingText = (_posString select 0) + "e";
|
||||
_northingText = (_posString select 1) + "n";
|
||||
(_display displayCtrl IDC_MODEDISPLAY_EASTING) ctrlSetText _eastingText;
|
||||
(_display displayCtrl IDC_MODEDISPLAY_NORTHING) ctrlSetText _northingText;
|
||||
|
||||
@ -78,7 +74,8 @@ case (APP_MODE_INFODISPLAY): {
|
||||
|
||||
if (GVAR(currentWaypoint) == -2) then {
|
||||
if (!(GVAR(rangeFinderPositionASL) isEqualTo [])) then {
|
||||
_targetPosName = format ["[%1]", (mapGridPosition GVAR(rangeFinderPositionASL))];
|
||||
_targetPos = [GVAR(rangeFinderPositionASL)] call EFUNC(map,getMapGridFromPos);
|
||||
_targetPosName = format ["[%1 %2 %3]", EGVAR(map,MGRS_data) select 1, _targetPos select 0, _targetPos select 1];
|
||||
_targetPosLocationASL = GVAR(rangeFinderPositionASL);
|
||||
};
|
||||
} else {
|
||||
@ -132,7 +129,8 @@ case (APP_MODE_COMPASS): {
|
||||
|
||||
if (GVAR(currentWaypoint) == -2) then {
|
||||
if (!(GVAR(rangeFinderPositionASL) isEqualTo [])) then {
|
||||
_targetPosName = format ["[%1]", (mapGridPosition GVAR(rangeFinderPositionASL))];
|
||||
_targetPos = [GVAR(rangeFinderPositionASL)] call EFUNC(map,getMapGridFromPos);
|
||||
_targetPosName = format ["[%1 %2 %3]", EGVAR(map,MGRS_data) select 1, _targetPos select 0, _targetPos select 1];
|
||||
_targetPosLocationASL = GVAR(rangeFinderPositionASL);
|
||||
};
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user