mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
31e1ad0cff
* add tools tab and setting * move to preinit * fix icon, add restart warning * derp Co-authored-by: Dystopian <sddex@ya.ru> * Update addons/arsenal/stringtable.xml Co-authored-by: PabstMirror <pabstmirror@gmail.com> * remove setting * add keepIfOverriden parameter * docs again * documentation whitespace * docs grammar, change parameter name * fix docs * more docs fixes * magazine support * deprecate spare barrel item * more docs, improve condition --------- Co-authored-by: Dystopian <sddex@ya.ru> Co-authored-by: PabstMirror <pabstmirror@gmail.com>
35 lines
931 B
Plaintext
35 lines
931 B
Plaintext
#include "script_component.hpp"
|
|
/*
|
|
* Author: LinkIsGrim
|
|
* Caches all item classnames used as field rations
|
|
*
|
|
* Arguments:
|
|
* None
|
|
*
|
|
* Return Value:
|
|
* None
|
|
*
|
|
* Example:
|
|
* call acex_field_rations_fnc_scanFieldRations
|
|
*
|
|
* Public: No
|
|
*/
|
|
|
|
private _list = createHashMap;
|
|
private _cfgWeapons = configFile >> "CfgWeapons";
|
|
private _cfgMagazines = configFile >> "CfgMagazines";
|
|
|
|
private _fnc_isFieldRationItem = toString {
|
|
(getNumber (_x >> "ACE_isFieldRationItem") isEqualTo 1) || {(getNumber (_x >> QXGVAR(thirstQuenched))) > 0} || {(getNumber (_x >> QXGVAR(hungerSatiated))) > 0} || {(getText (_x >> QXGVAR(refillItem))) isNotEqualTo ""}
|
|
};
|
|
|
|
{
|
|
_list set [configName _x, ""];
|
|
} forEach (_fnc_isFieldRationItem configClasses _cfgWeapons);
|
|
|
|
{
|
|
_list set [configName _x, ""];
|
|
} forEach (_fnc_isFieldRationItem configClasses _cfgMagazines);
|
|
|
|
uiNamespace setVariable [QXGVAR(fieldRationItems), compileFinal str _list];
|