2023-09-12 18:58:10 +00:00
|
|
|
#include "..\script_component.hpp"
|
2015-09-19 20:27:23 +00:00
|
|
|
/*
|
|
|
|
* Author: Glowbal
|
2024-07-03 15:39:04 +00:00
|
|
|
* Check if given unit has an item of given classname. Note: Case sensitive.
|
2015-01-16 23:21:47 +00:00
|
|
|
*
|
2015-09-19 20:27:23 +00:00
|
|
|
* Arguments:
|
|
|
|
* 0: Unit <OBJECT>
|
2024-07-03 15:39:04 +00:00
|
|
|
* 1: Item classname <STRING>
|
2015-09-19 20:27:23 +00:00
|
|
|
*
|
|
|
|
* Return Value:
|
2024-07-03 15:39:04 +00:00
|
|
|
* Unit has item <BOOL>
|
2015-09-19 20:27:23 +00:00
|
|
|
*
|
2017-06-08 13:31:51 +00:00
|
|
|
* Example:
|
2024-07-03 15:39:04 +00:00
|
|
|
* [player, "ACE_Banana"] call ace_common_fnc_hasItem
|
2017-06-08 13:31:51 +00:00
|
|
|
*
|
2017-10-11 19:05:54 +00:00
|
|
|
* Public: Yes
|
2015-01-16 23:21:47 +00:00
|
|
|
*/
|
2015-09-19 20:27:23 +00:00
|
|
|
|
2015-12-12 15:48:54 +00:00
|
|
|
params [["_unit", objNull, [objNull]], ["_item", "", [""]]];
|
2015-01-16 23:21:47 +00:00
|
|
|
|
2024-07-03 15:39:04 +00:00
|
|
|
_item in (_unit call FUNC(uniqueItems)) // return
|