mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
ffaa195fe5
* Fixed headers to work with silentspike python script * Fixed rest of the files * Fixed ace-team
29 lines
761 B
Plaintext
29 lines
761 B
Plaintext
/*
|
|
* Author: esteldunedain
|
|
* Opens or closes the gps on the map screen, showing coordinates
|
|
*
|
|
* Arguments:
|
|
* 0: Open GPS? <BOOL>
|
|
*
|
|
* Return Value:
|
|
* None
|
|
*
|
|
* Example:
|
|
* [true] call ACE_maptools_fnc_openMapGps
|
|
*
|
|
* Public: No
|
|
*/
|
|
#include "script_component.hpp"
|
|
|
|
params ["_shouldOpenGps"];
|
|
|
|
private _isOpen = !(isNull (uiNamespace getVariable [QGVAR(ui_mapGpsDisplay), displayNull]));
|
|
|
|
if (_shouldOpenGps && {"ItemGPS" in assignedItems ACE_player} && {!_isOpen}) then {
|
|
("RscACE_MapGps" call BIS_fnc_rscLayer) cutRsc ["RscACE_MapGps","PLAIN"];
|
|
|
|
[FUNC(openMapGpsUpdate), 0.5, []] call CBA_fnc_addPerFrameHandler; //update bearing/altitude every 0.5 sec (ticktime)
|
|
} else {
|
|
("RscACE_MapGps" call BIS_fnc_rscLayer) cutText ["","PLAIN"];
|
|
};
|