Skip to content

Commit

Permalink
Update fnc_replaceMagazineCargo.sqf
Browse files Browse the repository at this point in the history
  • Loading branch information
johnb432 committed May 8, 2024
1 parent da9c0c4 commit 7e418de
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions addons/disposable/fnc_replaceMagazineCargo.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,8 @@ private _isBackpack = getNumber (configOf _box >> "isBackpack") == 1;

if (_magazine in GVAR(magazines)) then {
private _loadedLauncher = GVAR(MagazineLaunchers) getVariable _magazine;

// As addWeaponCargoGlobal ignores allowedSlots, check here if launcher is allowed to be placed in a backpack
if (!_isBackpack || {_loadedLauncher in GVAR(BackpackLaunchers)}) then {
_box addWeaponCargoGlobal [_loadedLauncher, 1];
};
Expand Down

0 comments on commit 7e418de

Please sign in to comment.