addMagazineAmmoCargo: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
m (Some wiki formatting)
No edit summary
Line 18: Line 18:
|p2= magazine: [[String]] - magazine class name
|p2= magazine: [[String]] - magazine class name


|p3= quantity: [[Number]] - number of magazines to add
|p3= quantity: [[Number]] - number of magazines to add. Since Arma 3 v2.14, negative count will remove magazines.


|p4= ammocount: [[Number]] - ammo count in each magazine
|p4= ammocount: [[Number]] - ammo count in each magazine

Revision as of 00:15, 1 February 2023

Hover & click on the images for description

Description

Description:
Adds magazines with specified ammo count to the cargo space of a vehicle or a container.
Groups:
Vehicle Inventory

Syntax

Syntax:
cargospace addMagazineAmmoCargo [magazine, quantity, ammocount]
Parameters:
cargospace: Object - vehicle or container or weaponholder
magazine: String - magazine class name
quantity: Number - number of magazines to add. Since Arma 3 v2.14, negative count will remove magazines.
ammocount: Number - ammo count in each magazine
Return Value:
Nothing

Examples

Example 1:
_ammobox addMagazineAmmoCargo ["30Rnd_65x39_caseless_mag", 2, 5];

Additional Information

See also:
magazinesAmmoCargo addMagazineCargo addMagazineGlobal addMagazine addMagazines addMagazinePool addMagazineTurret clearMagazineCargo addWeaponCargo clearWeaponCargo clearWeaponCargo addWeaponCargoGlobal addBackpackCargoGlobal addItemCargo addItemCargoGlobal

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