ACE3/addons/microdagr/functions/fnc_modeMapButtons.sqf

32 lines
686 B
Plaintext
Raw Normal View History

#include "script_component.hpp"
2015-03-09 15:46:59 +00:00
/*
* Author: PabstMirror
* Takes some arguments and returns something or other.
*
* Arguments:
2015-03-11 07:06:07 +00:00
* 0: String of the map button pressed <STRING>
2015-03-09 15:46:59 +00:00
*
* Return Value:
2015-08-26 03:31:33 +00:00
* None
2015-03-09 15:46:59 +00:00
*
* Example:
2015-03-11 07:06:07 +00:00
* ["autotrack"] call ace_microdagr_fnc_modeMapButtons
2015-03-09 15:46:59 +00:00
*
2015-03-11 07:06:07 +00:00
* Public: No
2015-03-09 15:46:59 +00:00
*/
2015-08-26 03:31:33 +00:00
params ["_mode"];
2015-03-09 15:46:59 +00:00
[-1] call FUNC(saveCurrentAndSetNewMode); //backup current draw pos/zoom
if (_mode == "autotrack") then {
GVAR(mapAutoTrackPosition) = !GVAR(mapAutoTrackPosition);
} else {
if (_mode == "zoomin") then {
GVAR(mapZoom) = GVAR(mapZoom) * (10/11);
} else {
GVAR(mapZoom) = GVAR(mapZoom) * (11/10);
};
};
[] call FUNC(showApplicationPage);