/* * Author: joko // Jonas * * Handle fire of local launchers * * Argument: * 0: Magazine (String) * 1: * * Return value: * Array: * 0: * 1: * 2: * */ #include "script_component.hpp" EXPLODE_2_PVT(_this,_weapon,_magazine); if !(isNil (QGVAR(Damage) + _magazine)) exitWith {}; private ["_damage","_angle","_range"]; _damage = getNumber (configFile >> "CfgMagazines" >> _magazine >> QGVAR(damage)); if (_damage == 0) then { _angle = getNumber (configFile >> "CfgWeapons" >> _weapon >> QGVAR(angle)) / 2; _range = getNumber (configFile >> "CfgWeapons" >> _weapon >> QGVAR(range)); _damage = getNumber (configFile >> "CfgWeapons" >> _weapon >> QGVAR(damage)); } else { _angle = getNumber (configFile >> "CfgMagazines" >> _magazine >> QGVAR(angle)) / 2; _range = getNumber (configFile >> "CfgMagazines" >> _magazine >> QGVAR(range)); }; missionNameSpace setVariable [(QGVAR(values) + _magazine),[_angle, _range,_damage]]; [_angle,_range,_damage]