canAdd: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
(Added see also)
(descriotion made more clear)
Line 7: Line 7:
____________________________________________________________________________________________
____________________________________________________________________________________________


| Check if given object can be stored in inventory of given unit.  |= Description
| Check if given object can be stored in inventory container ([[uniform]], [[vest]], [[backpack]]) of given unit.  |= Description
____________________________________________________________________________________________
____________________________________________________________________________________________



Revision as of 10:36, 8 June 2015

Hover & click on the images for description

Description

Description:
Check if given object can be stored in inventory container (uniform, vest, backpack) of given unit.
Groups:
Uncategorised

Syntax

Syntax:
unit canAdd item
Parameters:
unit: Object
item: String - Config class
Return Value:
Boolean

Examples

Example 1:
if (player canAdd "FirstAidKit") then { player addItem "FirstAidKit"; } else { hint "Not enough space"; };

Additional Information

See also:
canAddItemToBackpackcanAddItemToUniformcanAddItemToVest

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

Notes

Bottom Section