Fandom

武装突袭 Wiki

AddMagazine

简体 | 繁體

4,827个页面创建
于此维基上
添加新页面
评论0 分享

您使用了广告屏蔽软件!


Wikia通过广告运营为用户提供免费的服务。我们对用户通过嵌入广告屏蔽软件访问网站进行了使用调整。

如果您使用了广告屏蔽软件,将无法使用我们的服务。请您移除广告屏蔽软件,以确保页面正常加载。

Introduced with Operation Flashpoint version 1.00
  Arguments of this scripting command have to be local to the client the command is executed onEffects of this scripting command are broadcasted over the network and happen on every computer in the network

点击图片可看到更多讯息

开始使用于

游戏:
Operation Flashpoint
版本:
1.00

描述

描述:
Add a magazine to a person. Infantry units can only carry a specific number of magazines, once the magazine slots are filled, any further addMagazine commands are ignored.

Note: When you add a new weapon via scripting commands as well as the magazines for it, the addMagazine command has to be given before the addWeapon command, otherwise the weapon won't be loaded.

Arma 3 logo black.png In Arma 3, the alternative variant of this command (addMagazine ARRAY) accepts global arguments Arguments of this scripting command don't have to be local to the client the command is executed on, i.e. you can use it on the server to give remote unit a magazine with limited ammo.

基本句法

句法:
unitName addMagazine magazineName
参数:
unitName: Object - person to add the magazines to

magazineName: String - magazine name. See the topic Category:Weapons for reference about possible values.
返回值:
Nothing

替代句法

句法:
unitName addMagazine [magazineName, ammoCount] (Since Arma 2 OA 1.62)
参数:
unitName: Object - person to add the magazines to

[magazineName, ammoCount]: Array

magazineName: String - magazine name. See the topic Category:Weapons for reference about possible values.

ammoCount: Number - Ammo quantity to be added to magazine.
返回值:
Nothing

范例

范例1:
player addMagazine "30Rnd_556x45_STANAG";

范例2:
player addMagazine ["30Rnd_556x45_STANAG", 15];

额外资讯

多人游戏:
-
也可以看看:

addMagazineGlobaladdMagazine_arrayaddMagazinesaddMagazineCargoaddMagazineCargoGlobaladdMagazinePooladdMagazineTurretremoveMagazineremoveMagazinesaddWeaponloadMagazine

注意事项

此处撰写句法皆为可行用法. 可到官网[1]专页回报错误. 你可以使用讨论页面或是论坛来进行讨论.
新增注意事项 | 如何新增?

Notes

Posted on August 2, 2006 - 06:59
Hoz
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
Vigilante
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
Inkompetent
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"};

Bottom Section

更多维基

随机维基