ulteq 2015-04-29 12:24:56 +02:00
parent e56838be36
commit 87d1f7c281

View File

@ -19,19 +19,13 @@
* Public: Yes
*/
#include "script_component.hpp"
private ["_result", "_ignoreRange", "_helper", "_pos"];
private ["_result", "_ignoreRange", "_pos"];
EXPLODE_3_PVT(_this,_unit,_range,_item);
_ignoreRange = (_range == -1);
_result = true;
if (!_ignoreRange && {(_unit distance (_item select 0)) > _range}) exitWith {false};
_helper = (attachedTo (_item select 0));
if (!isNull(_helper)) then {
detach (_item select 0);
deleteVehicle _helper;
};
if (getNumber (ConfigFile >> "CfgAmmo" >> typeof (_item select 0) >> "TriggerWhenDestroyed") == 0) then {
private ["_exp", "_previousExp"];
_previousExp = _item select 0;