BIS fnc configViewer: Difference between revisions
Jump to navigation
Jump to search
mNo edit summary |
Lou Montana (talk | contribs) (Page filling) |
||
Line 1: | Line 1: | ||
{{Function|= Comments | {{Function|= Comments | ||
____________________________________________________________________________________________ | ____________________________________________________________________________________________ | ||
Line 8: | Line 7: | ||
____________________________________________________________________________________________ | ____________________________________________________________________________________________ | ||
| | | Splendid config viewer |= Description | ||
____________________________________________________________________________________________ | |||
| [parent, cfg, showOk, onSelect, onAdd, header] call [[BIS_fnc_configviewer]] |= Syntax | |||
|p1= parent: [[Display]] - (Optional, default mission display) parent display |= Parameter 1 | |||
|p2= cfg: [[Config]] - (Optional, default all configs) root config |= Parameter 2 | |||
|p3= showOk: [[Boolean]] - (Optional, default [[false]]) true to display OK button. Script will then wait until viewer is closed and return selected class and param |= Parameter 3 | |||
|p4= onSelect: [[Code]] - (Optional, default {}) executed upon selecting a class. '''Has to return STRING''', which will be shown as structured text instead of params.|= Parameter 4 | |||
| | |p5= onAdd: [[Code]] - (Optional, default {}) executed upon adding a class to list. Returned value (STRING) is item text. Empty string will skip the item. |= Parameter 5 | ||
| | |p6= header: [[String]] - (Optional, default "%1") custom header. Use %1 to refer to original name ("Splendid Config Viewer") |= Parameter 6 | ||
| |= Return value | | [[Array]] | ||
* when OK button is not displayed, empty array is returned | |||
* else, an array of currently selected entries in format [class ([[Config]]), param ([[String]])] is returned. |= Return value | |||
____________________________________________________________________________________________ | ____________________________________________________________________________________________ | ||
|x1= <code></code> |= | |x1= <code>[[call]] [[BIS_fnc_configviewer]];</code> |= Example 1 | ||
____________________________________________________________________________________________ | ____________________________________________________________________________________________ | ||
| |= See also | | [[BIS_fnc_animViewer]] |= See also | ||
}} | }} | ||
Revision as of 21:54, 29 April 2018
Description
- Description:
- Splendid config viewer
- Execution:
- call
- Groups:
- Uncategorised
Syntax
- Syntax:
- [parent, cfg, showOk, onSelect, onAdd, header] call BIS_fnc_configviewer
- Parameters:
- parent: Display - (Optional, default mission display) parent display
- cfg: Config - (Optional, default all configs) root config
- showOk: Boolean - (Optional, default false) true to display OK button. Script will then wait until viewer is closed and return selected class and param
- onSelect: Code - (Optional, default {}) executed upon selecting a class. Has to return STRING, which will be shown as structured text instead of params.
- onAdd: Code - (Optional, default {}) executed upon adding a class to list. Returned value (STRING) is item text. Empty string will skip the item.
- header: String - (Optional, default "%1") custom header. Use %1 to refer to original name ("Splendid Config Viewer")
- Return Value:
- Array
Examples
- Example 1:
call BIS_fnc_configviewer;
Additional Information
- See also:
- BIS_fnc_animViewer
Notes
-
Report bugs on the Feedback Tracker and/or discuss them on the Arma Discord or on the Forums.
Only post proven facts here! Add Note