MissleGuidance - fix Inheritance check

This commit is contained in:
PabstMirror 2015-05-04 22:46:58 -05:00
parent f81e53bb33
commit 3fa218848d

View File

@ -15,8 +15,10 @@ PARAMS_7(_shooter,_weapon,_muzzle,_mode,_ammo,_magazine,_projectile);
// Bail on not missile
if(! (_ammo isKindOf "MissileBase") ) exitWith { false };
_configs = configProperties [configFile >> "CfgAmmo" >> _ammo >> QUOTE(ADDON), "true", false];
//Verify ammo has explicity added guidance config (ignore inheritances)
_configs = configProperties [(configFile >> "CfgAmmo" >> _ammo), QUOTE(configName _x == QUOTE(QGVAR(enabled))), false];
if( (count _configs) < 1) exitWith {};
_config = (configFile >> "CfgAmmo" >> _ammo >> QUOTE(ADDON));
_enabled = getNumber ( _config >> "enabled");