ACE3/addons/rearm/functions/fnc_getVehicleMagazines.sqf

24 lines
539 B
Plaintext
Raw Normal View History

2016-02-27 19:31:07 +00:00
/*
* Author: GitHawk, Jonpas
2016-02-27 20:14:23 +00:00
* Returns all magazines a turret of a vehicle object can hold according to config.
2016-02-27 19:31:07 +00:00
*
* Arguments:
2016-02-27 20:05:19 +00:00
* 0: Vehicle <OBJECT>
2016-02-27 19:31:07 +00:00
* 1: Turret Path <ARRAY>
*
* Return Value:
* Magazine classes in TurretPath <ARRAY>
*
* Example:
* [vehicle, [0]] call ace_rearm_fnc_getVehicleMagazines
*
* Public: No
*/
#include "script_component.hpp"
2016-02-27 20:05:19 +00:00
params [["_vehicle", objNull, [objNull]], ["_turretPath", [], [[]]]];
2016-02-27 19:31:07 +00:00
2016-02-27 20:05:19 +00:00
if (isNull _vehicle) exitWith {[]};
2016-02-27 19:31:07 +00:00
2016-02-27 20:05:19 +00:00
([typeOf _vehicle, _turretPath] call FUNC(getConfigMagazines))