2023-09-12 18:58:10 +00:00
|
|
|
#include "..\script_component.hpp"
|
2015-08-08 00:26:09 +00:00
|
|
|
/*
|
|
|
|
* Author: commy2
|
2024-08-02 11:59:18 +00:00
|
|
|
* Shows firemode indicator, representing safety lock.
|
2015-08-08 00:26:09 +00:00
|
|
|
*
|
|
|
|
* Arguments:
|
|
|
|
* 0: Show firemode <BOOL>
|
|
|
|
*
|
|
|
|
* Return Value:
|
2015-08-11 15:56:46 +00:00
|
|
|
* None
|
2015-08-08 00:26:09 +00:00
|
|
|
*
|
|
|
|
* Example:
|
2024-08-02 11:59:18 +00:00
|
|
|
* true call ace_safemode_fnc_setSafeModeVisual
|
2015-08-08 00:26:09 +00:00
|
|
|
*
|
|
|
|
* Public: No
|
|
|
|
*/
|
2015-01-11 16:42:31 +00:00
|
|
|
|
2015-08-08 00:26:09 +00:00
|
|
|
params ["_show"];
|
2015-01-11 16:42:31 +00:00
|
|
|
|
|
|
|
disableSerialization;
|
2015-01-17 20:32:34 +00:00
|
|
|
|
2016-09-04 14:44:22 +00:00
|
|
|
private _control = (uiNamespace getVariable ["ACE_dlgSoldier", displayNull]) displayCtrl 187;
|
2015-01-11 16:42:31 +00:00
|
|
|
|
|
|
|
if (isNull _control) exitWith {};
|
|
|
|
|
|
|
|
if (_show) then {
|
2016-09-04 14:44:22 +00:00
|
|
|
private _config = configFile >> "RscInGameUI" >> "RscUnitInfoSoldier" >> "WeaponInfoControlsGroupLeft" >> "controls" >> "CA_ModeTexture";
|
2015-01-11 16:42:31 +00:00
|
|
|
|
2015-05-15 13:41:41 +00:00
|
|
|
_control ctrlSetPosition [getNumber (_config >> "x"), getNumber (_config >> "y"), getNumber (_config >> "w"), getNumber (_config >> "h")];
|
2015-01-11 16:42:31 +00:00
|
|
|
} else {
|
2015-05-15 13:41:41 +00:00
|
|
|
_control ctrlSetPosition [0, 0, 0, 0];
|
2015-01-11 16:42:31 +00:00
|
|
|
};
|
2024-08-02 11:59:18 +00:00
|
|
|
|
|
|
|
_control ctrlCommit 0;
|