2023-09-12 18:58:10 +00:00
|
|
|
#include "..\script_component.hpp"
|
2016-01-08 04:43:37 +00:00
|
|
|
/*
|
|
|
|
* Author: commy2
|
|
|
|
* Sets the controls structured text if it isn't already set.
|
|
|
|
*
|
2016-06-18 09:50:41 +00:00
|
|
|
* Arguments:
|
2016-01-08 04:43:37 +00:00
|
|
|
* 0: Structured Text Ctrl <CONTROL>
|
|
|
|
* 1: Index <NUMBER>
|
|
|
|
* 2: Text <STRING>
|
|
|
|
*
|
2016-06-18 09:50:41 +00:00
|
|
|
* Return Value:
|
2016-01-08 04:43:37 +00:00
|
|
|
* None
|
|
|
|
*
|
2017-06-08 13:31:51 +00:00
|
|
|
* Example:
|
|
|
|
* [CONTROL, 5, "text"] call ACE_interact_menu_fnc_ctrlSetParsedTextCached
|
|
|
|
*
|
2016-01-08 04:43:37 +00:00
|
|
|
* Public: No
|
|
|
|
*/
|
2015-04-25 11:28:21 +00:00
|
|
|
|
2015-08-04 22:46:57 +00:00
|
|
|
params ["_ctrl", "_index", "_text"];
|
2015-04-25 11:28:21 +00:00
|
|
|
|
2015-04-26 17:33:08 +00:00
|
|
|
//systemChat str (_text != ARR_SELECT(GVAR(ParsedTextCached),_index,"-1"));
|
|
|
|
|
2016-01-08 04:43:37 +00:00
|
|
|
if (_text != (GVAR(ParsedTextCached) param [_index,"-1"])) then {
|
2015-12-21 16:05:48 +00:00
|
|
|
GVAR(ParsedTextCached) set [_index, _text];
|
|
|
|
_ctrl ctrlSetStructuredText parseText _text;
|
2015-04-25 11:28:21 +00:00
|
|
|
};
|