mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
f73b6b1aad
- Add the possibility of switching between headphones or speaker - Move detector actions to their own submenu
28 lines
592 B
Plaintext
28 lines
592 B
Plaintext
/*
|
|
* Author: esteldunedain
|
|
* Connect/disconnect headphones to the mine detector
|
|
*
|
|
* Arguments:
|
|
* 0: Unit <OBJECT>
|
|
* 1: Connect? <BOOLEAN>
|
|
*
|
|
* Return Value:
|
|
* None
|
|
*
|
|
* Example:
|
|
* [_unit, true] call ace_minedetector_fnc_connectHeadphones
|
|
*
|
|
* Public: No
|
|
*/
|
|
|
|
#include "script_component.hpp"
|
|
|
|
params ["_unit", "_state"];
|
|
_unit setVariable [QGVAR(isUsingHeadphones), _state];
|
|
|
|
if (_state) then {
|
|
[localize LSTRING(HeadphonesConnected)] call EFUNC(common,displayTextStructured);
|
|
} else {
|
|
[localize LSTRING(HeadphonesDisconnected)] call EFUNC(common,displayTextStructured);
|
|
};
|