mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
getOrDefaultCall
This commit is contained in:
parent
76b6fc92a7
commit
bd5e0489a9
@ -18,13 +18,8 @@
|
|||||||
|
|
||||||
params ["_weapon", "_muzzle"];
|
params ["_weapon", "_muzzle"];
|
||||||
|
|
||||||
private _return = GVAR(reloadActionsCache) get [_weapon, _muzzle];
|
GVAR(reloadActionsCache) getOrDefaultCall [[_weapon, _muzzle], {
|
||||||
|
|
||||||
if (isNil "_return") then {
|
|
||||||
private _wpnMuzzleCfg = configFile >> "CfgWeapons" >> _weapon;
|
private _wpnMuzzleCfg = configFile >> "CfgWeapons" >> _weapon;
|
||||||
if (_muzzle isNotEqualTo _weapon) then { _wpnMuzzleCfg = _wpnMuzzleCfg >> _muzzle};
|
if (_muzzle isNotEqualTo _weapon) then { _wpnMuzzleCfg = _wpnMuzzleCfg >> _muzzle};
|
||||||
_return = toLower getText (_wpnMuzzleCfg >> "reloadAction");
|
toLowerANSI getText (_wpnMuzzleCfg >> "reloadAction") // return
|
||||||
GVAR(reloadMutex_reloadActionsCache) set [[_weapon, _muzzle], _return];
|
}, true];
|
||||||
};
|
|
||||||
|
|
||||||
_return
|
|
||||||
|
Loading…
Reference in New Issue
Block a user