mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
22 lines
686 B
Plaintext
22 lines
686 B
Plaintext
#include "script_component.hpp"
|
|
|
|
#include "XEH_PREP.hpp"
|
|
|
|
// Ammo/Magazines look-up hash for correctness of initSpeed
|
|
private _cfgMagazines = configFile >> "CfgMagazines";
|
|
private _cfgAmmo = configFile >> "CfgAmmo";
|
|
private _cfgThrow = configFile >> "CfgWeapons" >> "Throw";
|
|
|
|
private _ammoMagLookup = createHashMap;
|
|
|
|
{
|
|
{
|
|
private _ammo = getText (_cfgMagazines >> _x >> "ammo");
|
|
if (_ammo != "") then {
|
|
_ammoMagLookup set [configName (_cfgAmmo >> _ammo), _x];
|
|
};
|
|
} forEach (getArray (_cfgThrow >> _x >> "magazines"));
|
|
} forEach (getArray (_cfgThrow >> "muzzles"));
|
|
|
|
uiNamespace setVariable [QGVAR(ammoMagLookup), compileFinal _ammoMagLookup];
|