2024-02-07 12:16:18 +00:00
|
|
|
#include "..\script_component.hpp"
|
|
|
|
/*
|
|
|
|
* Author: Glowbal, Smith
|
|
|
|
* Get selected item from cargo menu.
|
|
|
|
*
|
|
|
|
* Arguments:
|
|
|
|
* None
|
|
|
|
*
|
|
|
|
* Return Value:
|
|
|
|
* Classname of selected item or selected object <STRING> or <OBJECT> (default: nil)
|
|
|
|
*
|
|
|
|
* Example:
|
|
|
|
* call ace_cargo_fnc_getSelectedItem
|
|
|
|
*
|
|
|
|
* Public: No
|
|
|
|
*/
|
|
|
|
|
2024-04-20 23:01:55 +00:00
|
|
|
params [["_index", -1, [0]]];
|
2024-02-07 12:16:18 +00:00
|
|
|
|
|
|
|
private _loaded = GVAR(interactionVehicle) getVariable [QGVAR(loaded), []];
|
|
|
|
|
|
|
|
if (_loaded isEqualTo []) exitWith {};
|
|
|
|
|
|
|
|
// This can be an object or a classname string
|
2024-04-20 23:01:55 +00:00
|
|
|
_loaded param [_index, nil]
|