2023-09-12 18:58:10 +00:00
|
|
|
#include "..\script_component.hpp"
|
2015-04-07 15:58:54 +00:00
|
|
|
/*
|
|
|
|
* Author: Ruthberg
|
|
|
|
* Opens the Kestrel 4500 dialog
|
|
|
|
*
|
|
|
|
* Arguments:
|
2015-08-13 23:55:54 +00:00
|
|
|
* None
|
2015-04-07 15:58:54 +00:00
|
|
|
*
|
|
|
|
* Return Value:
|
2015-08-14 00:22:15 +00:00
|
|
|
* None
|
2015-04-07 15:58:54 +00:00
|
|
|
*
|
|
|
|
* Example:
|
2015-08-14 00:22:15 +00:00
|
|
|
* call ace_kestrel4500_fnc_createKestrelDialog
|
2015-04-07 15:58:54 +00:00
|
|
|
*
|
|
|
|
* Public: No
|
|
|
|
*/
|
2015-04-07 15:43:54 +00:00
|
|
|
|
2020-02-23 01:11:20 +00:00
|
|
|
if (GVAR(Kestrel4500) || {underwater ACE_player} || {!(call FUNC(canShow))}) exitWith {false};
|
2015-04-07 15:43:54 +00:00
|
|
|
|
2015-04-08 09:25:15 +00:00
|
|
|
GVAR(Overlay) = false;
|
2019-11-22 20:47:51 +00:00
|
|
|
QGVAR(Layer) cutText ["", "PLAIN"];
|
2015-04-07 15:43:54 +00:00
|
|
|
|
|
|
|
GVAR(Kestrel4500) = true;
|
|
|
|
createDialog 'Kestrel4500_Display';
|
|
|
|
|
|
|
|
[{
|
|
|
|
if (!dialog || !GVAR(Kestrel4500)) exitWith {
|
2015-04-07 17:57:42 +00:00
|
|
|
GVAR(Kestrel4500) = false;
|
2015-04-07 15:43:54 +00:00
|
|
|
[_this select 1] call CBA_fnc_removePerFrameHandler;
|
|
|
|
};
|
2015-08-13 23:55:54 +00:00
|
|
|
|
2015-04-07 15:43:54 +00:00
|
|
|
[] call FUNC(updateDisplay);
|
|
|
|
}, 1, _this select 0] call CBA_fnc_addPerFrameHandler;
|
|
|
|
|
|
|
|
true
|