Page tree
Skip to end of metadata
Go to start of metadata

Introduced in




Adds a magazine to a character. The number of magazines that can be added using this command is not limited to the magazine slots, allotted to a character (for example, it is possible to add hundreds of magazines).

When equipping a character with a new weapon, executing addMagazine before the addWeapon command causes the weapon to start out as already loaded.


Syntax:unit addMagazine magazineName
  • unit: Object - Character to add a magazine to.
  • magazineName: String - Magazine name.
Return Value:Nothing


player addMagazine "M16"

Additional Information

See also: removeMagazine, removeMagazines, addWeapon


Posted on August 2, 2006 - 06:59
If the unit has magazines already, you may need to use the commands removeMagazine or removeMagazines to make space for the mags you want to add.

Posted on February 21, 2010 - 20:13
In turreted vehicles the magazine is added to the first turret with >> primaryGunner = 1; << set in the Vehicles turret config part (and the magazine is ONLY added to the very first turret if more than one is configged with >> primaryGunner = 1; << ).

Posted on May 12, 2010 - 20:09
When wanting to add many magazines to an object's init-line it can be easier to use loops than to just repeat the addMagazine command.

If you want to add N magazines to an object either of the two below ways are handy, the first for fewer magazines, and the latter when you want to add many since it then is the easiest of the two to read.

{this addMagazine "magazineClassName"} forEach [1,2,3,...,N];

for "_i" from 0 to N-1 do {this addMagazine "magazineClassName"};