2015-01-17 17:26:51 +00:00
|
|
|
#include "script_component.hpp"
|
|
|
|
|
2015-01-29 07:38:46 +00:00
|
|
|
ADDON = false;
|
|
|
|
|
2016-11-23 19:35:25 +00:00
|
|
|
PREP_RECOMPILE_START;
|
2016-02-22 14:20:36 +00:00
|
|
|
#include "XEH_PREP.hpp"
|
2016-11-23 19:35:25 +00:00
|
|
|
PREP_RECOMPILE_END;
|
2015-01-17 17:26:51 +00:00
|
|
|
|
2015-09-27 15:15:59 +00:00
|
|
|
// collect frag and other grenades separately
|
2016-05-03 00:32:44 +00:00
|
|
|
GVAR(GrenadesAll) = [];
|
|
|
|
GVAR(GrenadesFrag) = [];
|
2015-09-27 15:15:59 +00:00
|
|
|
GVAR(GrenadesNonFrag) = [];
|
2015-01-17 17:26:51 +00:00
|
|
|
|
2024-06-20 05:04:34 +00:00
|
|
|
private _cfgMagazines = configFile >> "CfgMagazines";
|
|
|
|
private _cfgAmmo = configFile >> "CfgAmmo";
|
|
|
|
private _cfgThrow = configFile >> "CfgWeapons" >> "Throw";
|
|
|
|
|
2015-09-27 15:15:59 +00:00
|
|
|
{
|
2024-06-20 05:04:34 +00:00
|
|
|
private _magazines = getArray (_cfgThrow >> _x >> "magazines");
|
2015-01-17 17:26:51 +00:00
|
|
|
|
2015-09-27 15:15:59 +00:00
|
|
|
GVAR(GrenadesAll) append _magazines;
|
2015-09-27 14:47:02 +00:00
|
|
|
|
2015-09-27 15:15:59 +00:00
|
|
|
{
|
2024-06-20 05:04:34 +00:00
|
|
|
private _ammo = getText (_cfgMagazines >> _x >> "ammo");
|
|
|
|
private _explosive = getNumber (_cfgAmmo >> _ammo >> "explosive");
|
2015-01-17 17:26:51 +00:00
|
|
|
|
2015-09-27 15:15:59 +00:00
|
|
|
([GVAR(GrenadesFrag), GVAR(GrenadesNonFrag)] select (_explosive == 0)) pushBack _x;
|
2024-04-04 11:15:26 +00:00
|
|
|
} forEach _magazines;
|
2024-06-20 05:04:34 +00:00
|
|
|
} forEach getArray (_cfgThrow >> "muzzles");
|
2015-01-29 07:38:46 +00:00
|
|
|
|
2023-12-07 03:20:47 +00:00
|
|
|
#include "initSettings.inc.sqf"
|
2018-02-09 20:28:34 +00:00
|
|
|
|
2015-01-29 07:38:46 +00:00
|
|
|
ADDON = true;
|