Fix allowSwapBarrel condition (#6170)

This commit is contained in:
ulteq 2018-02-28 00:35:03 +01:00 committed by PabstMirror
parent 3feafc449f
commit 21ae61e551

View File

@ -18,7 +18,7 @@
params ["_unit","_weapon"];
//Check if weapon can have its barrel swapped. If not exit out of function
if( !GVAR(enabled) && (getNumber (configFile >> 'CfgWeapons' >> _weapon >> QGVAR(allowSwapBarrel))) != 1) exitWith{false};
if( !GVAR(enabled) || {getNumber (configFile >> 'CfgWeapons' >> _weapon >> QGVAR(allowSwapBarrel)) != 1}) exitWith{false};
//Get the classname of the spare barrel for the weapon
private _weaponBarrelClass = getText (configFile >> 'CfgWeapons' >> _weapon >> QGVAR(barrelClassname));