BIS fnc unitHeadgear: Difference between revisions
Jump to navigation
Jump to search
Lou Montana (talk | contribs) m (Text replacement - "\|seealso= ([^ ]+)(\]\]|\}\}), *(\[\[|\{\{)" to "|seealso= $1$2 $3") |
Lou Montana (talk | contribs) m (Text replacement - "\{\{ *cc*\| *([^}]+) *\}\}" to "// $1") |
||
Line 25: | Line 25: | ||
|r1= [[Boolean]] - [[true]] when done | |r1= [[Boolean]] - [[true]] when done | ||
|x1= <code>[<nowiki/>[[Magic Variables#this_2|this]]] [[call]] [[BIS_fnc_unitHeadgear]]; | |x1= <code>[<nowiki/>[[Magic Variables#this_2|this]]] [[call]] [[BIS_fnc_unitHeadgear]]; // headgear and face wear, same as [this, [], []]</code> | ||
|x2= <code>[<nowiki/>[[Magic Variables#this_2|this]], [], []] [[call]] [[BIS_fnc_unitHeadgear]]; | |x2= <code>[<nowiki/>[[Magic Variables#this_2|this]], [], []] [[call]] [[BIS_fnc_unitHeadgear]]; // headgear only</code> | ||
|x3= <code>[<nowiki/>[[Magic Variables#this_2|this]], [[nil]], []] [[call]] [[BIS_fnc_unitHeadgear]]; | |x3= <code>[<nowiki/>[[Magic Variables#this_2|this]], [[nil]], []] [[call]] [[BIS_fnc_unitHeadgear]]; // facewear only</code> | ||
|x4= <code>[<nowiki/>[[Magic Variables#this_2|this]], "myTemplate"] [[call]] [[BIS_fnc_unitHeadgear]]; | |x4= <code>[<nowiki/>[[Magic Variables#this_2|this]], "myTemplate"] [[call]] [[BIS_fnc_unitHeadgear]]; // class defined in {{HashLink|Description.ext#CfgUnitTemplates}}</code> | ||
|seealso= {{HashLink|Description.ext#CfgUnitTemplates}} [[addGoggles]] [[addHeadgear]] | |seealso= {{HashLink|Description.ext#CfgUnitTemplates}} [[addGoggles]] [[addHeadgear]] | ||
}} | }} |
Revision as of 11:02, 13 July 2022
Description
Syntax
- Syntax:
- [unit, headgear, facewear] call BIS_fnc_unitHeadgear
- Parameters:
- unit: Object
- headgear: Boolean, String or Array - (Optional, default false) can be one of:
- Boolean - if false, change nothing to the headgear
- String - valid Headgear class or a valid class from Description.ext CfgUnitTemplates
- Array - headgear list with individual probability
- facewear: Boolean, String or Array - (Optional, default false) can be one of:
- Boolean - if false, change nothing to the facewear
- String - valid facewear class or a valid class from Description.ext CfgUnitTemplates
- Array - facewear list with individual probability
- Return Value:
- Boolean - true when done
Examples
- Example 1:
[this] call BIS_fnc_unitHeadgear; // headgear and face wear, same as [this, [], []]
- Example 2:
[this, [], []] call BIS_fnc_unitHeadgear; // headgear only
- Example 3:
[this, nil, []] call BIS_fnc_unitHeadgear; // facewear only
- Example 4:
[this, "myTemplate"] call BIS_fnc_unitHeadgear; // class defined in Description.ext - CfgUnitTemplates
Additional Information
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