Skip to content

Commit

Permalink
Merge pull request #3651 from acemod/addMapAltitudeToGPS
Browse files Browse the repository at this point in the history
Add map altitude to GPS
  • Loading branch information
nicolasbadano committed Apr 2, 2016
2 parents ec2c331 + caf06f5 commit 8eb7d28
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions addons/maptools/functions/fnc_openMapGpsUpdate.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
private ["_mapGpsDisplay", "_ctrl"];

if ((!("ItemGPS" in assigneditems ACE_player)) || {isNull (uiNamespace getVariable [QGVAR(ui_mapGpsDisplay), displayNull])}) exitWith {
("RscACE_MapGps" call BIS_fnc_rscLayer) cutText ["","PLAIN"]; //close GPS RSC
[(_this select 1)] call CBA_fnc_removePerFrameHandler; //remove frameHandler
("RscACE_MapGps" call BIS_fnc_rscLayer) cutText ["","PLAIN"]; // Close GPS RSC
[(_this select 1)] call CBA_fnc_removePerFrameHandler; // Remove frameHandler
};
disableSerialization;

_mapGpsDisplay = uiNamespace getVariable [QGVAR(ui_mapGpsDisplay), displayNull];
_ctrl = _mapGpsDisplay displayCtrl 913590;
_ctrl ctrlSetText str(round(getDir ACE_player)); //set Heading
_ctrl ctrlSetText str (round (getDir ACE_player)); // Set Heading
_ctrl = _mapGpsDisplay displayCtrl 913591;
_ctrl ctrlSetText str(round((getPosASL ACE_player) select 2)); //set Altitude
_ctrl ctrlSetText str (round ((getPosASL ACE_player) select 2) + EGVAR(common,mapAltitude)); // Set Altitude
_ctrl = _mapGpsDisplay displayCtrl 913592;
_ctrl ctrlSetText mapGridPosition ACE_player; //set grid cords
_ctrl ctrlSetText mapGridPosition ACE_player; // Set grid cords

0 comments on commit 8eb7d28

Please sign in to comment.