2015-01-11 19:32:51 +00:00
|
|
|
/*
|
|
|
|
Author: Garth de Wet (LH)
|
|
|
|
|
|
|
|
Description:
|
|
|
|
Adds an item to the select menu
|
|
|
|
|
|
|
|
Parameters:
|
|
|
|
0: ARRAY/NUMBER - List container
|
|
|
|
1: String - Display Name
|
|
|
|
2: String - Picture
|
|
|
|
3: String/code - data
|
|
|
|
|
|
|
|
Returns:
|
|
|
|
ARRAY/Number
|
|
|
|
|
|
|
|
Example:
|
|
|
|
*/
|
2015-01-11 23:13:47 +00:00
|
|
|
|
|
|
|
#include "script_component.hpp"
|
|
|
|
|
2015-01-11 19:32:51 +00:00
|
|
|
private ["_container", "_displayName", "_picture", "_data", "_index"];
|
|
|
|
|
|
|
|
_container = _this select 0;
|
|
|
|
_displayName = _this select 1;
|
|
|
|
_picture = _this select 2;
|
|
|
|
_data = _this select 3;
|
|
|
|
|
|
|
|
if (_picture == "" || _picture == "PictureThing") then {
|
2015-01-13 05:14:27 +00:00
|
|
|
_picture = QUOTE(PATHTOF(UI\dot_ca.paa));
|
2015-01-11 19:32:51 +00:00
|
|
|
};
|
|
|
|
|
2015-03-01 02:00:24 +00:00
|
|
|
_index = lbAdd [_container, _displayName];
|
|
|
|
lbSetData [_container, _index, str _data];
|
|
|
|
lbSetPicture [_container, _index, _picture];
|
2015-01-11 19:32:51 +00:00
|
|
|
|
|
|
|
_container
|