ACE3/addons/cookoff/functions/fnc_isMagazineFlare.sqf
2024-01-27 09:14:10 +01:00

25 lines
600 B
Plaintext

#include "..\script_component.hpp"
/*
* Author: Cyruz
* Checks if the magazine's ammo are flares.
*
* Arguments:
* 0: Magazine <STRING>
*
* Return Value:
* 0: If magazine is type of flare <BOOL>
*
* Example:
* "3Rnd_UGL_FlareWhite_F" call ace_cookoff_fnc_isMagazineFlare
*
* Public: No
*/
params ["_magazine"];
private _configAmmo = configFile >> "CfgAmmo" >> getText (configFile >> "CfgMagazines" >> _magazine >> "ammo");
private _intensity = getNumber (_configAmmo >> "intensity");
private _flare = getNumber (_configAmmo >> QEGVAR(grenades,flare));
_intensity != 0 || _flare == 1