Page MenuHomeFeedback Tracker

Impossible to add magazines to corresponding weapon magazine slots
Assigned, WishlistPublic

Description

If you have no container, "addMagazine" doesn't add magazine to corresponding weapon magazine slot.

Details

Legacy ID
506486741
Severity
None
Resolution
Open
Reproducibility
Always
Category
Scripting
Steps To Reproduce

removeAllWeapons player;
removeAllAssignedItems player;
removeHeadgear player;
removeVest player;
removeUniform player;
removeBackpack player;

player addWeapon "arifle_MX_F";
player addMagazine "30Rnd_65x39_caseless_mag";

player addWeapon "launch_NLAW_F";
player addMagazine "NLAW_F";

player addWeapon "hgun_P07_F";
player addMagazine "16Rnd_9x21_Mag";

Additional Information

In all cases (repro. steps) player ends up with no magazines, although magazine slots are free and you can manually put magazines there for example from ammo box.

I expect addMagazines to work in such cases... or some other special command should be added.

Event Timeline

MessiahUA edited Additional Information. (Show Details)
MessiahUA set Category to Scripting.
MessiahUA set Reproducibility to Always.
MessiahUA set Severity to None.
MessiahUA set Resolution to Open.
MessiahUA set Legacy ID to 506486741.May 7 2016, 4:49 PM
W4RH4WK added a subscriber: W4RH4WK.May 7 2016, 4:49 PM

does adding the magazine before adding the weapon help?

or does "In all cases" meant you tried changing the order already?

"In all cases" - i meant only repro.steps in ticket description, but anyways it doesn't matter i've just tried and it makes no difference (which is common logic).

It auto-loads magazine only if magazine exists in inventory (any free container) at the time of adding weapon, for example:

player addUniform "U_B_CombatUniform_mcam_tshirt";
player addMagazine "30Rnd_65x39_caseless_mag";
player addWeapon "arifle_MX_F";