UnitUseItemPoint
- Parameters
-
whichUnit unit
Target unit.
whichItem item
Handle to item instance.
x real
Point at X map coordinate to use the item.
y real
Point at Y map coordinate to use the item.
- comment
Issues an immediate order for the unit to use item pointed at position (x,y).
This is the same as left-clicking and using an item in inventory. Units that cannot use items will not do anything.
Examples:
-
Potion of Healing
'phea'
: Restores HP -
Dagger of Escape
'desc'
: Casts immediately towards (x,y), even if too far, item on cooldown. Does not cast if position is already reached (no cooldown). -
Inferno Stone
'infs'
: runs towards (x,y) and once in range, casts to spawn an Infernal. If already in range, casts immediately.
-
- bug
Seems to always return false (tested v1.32.10).
- note
See:
UnitUseItem
,UnitUseItemTarget
.- patch
1.00
- Source
- common.j
- return type
boolean
- Source code
native UnitUseItemPoint takes unit whichUnit, item whichItem, real x, real y returns boolean