weaponsItemsCargo
- Arma 3 v1.22
Command · also in Vehicle Inventory · Markdown · JSON · original wiki page
Description
Returns an array with subarrays contains class names and also names of connected items of all the vehicle's cargo weapons in weaponsItems format. If weapon has no magazine, an empty array [] is returned instead of magazine info. If the argument is a vehicle with weapons, vehicles cargo is searched, unlike with weaponsItems command, which will return vehicle's weapons instead.
Note
Since Arma 3 v1.96 the returned array always contains secondary muzzle magazine info and is consistent with getUnitLoadout format for weapon items.
Syntax
Syntax 1
weaponsItemsCargo vehicle
Parameters:
vehicle: Object ammobox or vehicle
Returns: Array - see weaponsItems
Syntax 2
since arma3 2.14
weaponsItemsCargo [vehicle, extended]
Parameters:
Returns: Array - see weaponsItems
Examples
Example 1
weaponsItemsCargo vehicle player;
Example 2
weaponsItemsCargo _weaponholder;
See also
weaponsItems · primaryWeaponItems · secondaryWeaponItems · handgunItems · addPrimaryWeaponItem · addSecondaryWeaponItem · addHandgunItem · primaryWeapon · secondaryWeapon · handgunWeapon · weaponAccessories · weaponAccessoriesCargo · addWeaponWithAttachmentsCargoGlobal