Fandom

WoWWiki

API IsItemInRange

104,670pages on
this wiki
Add New Page
Talk0 Share
WoW API < IsItemInRange

Returns if you are in range of the specified unit to use the specified item.

result = IsItemInRange("itemName" or "itemLink", "unit")

Parameters Edit

Arguments Edit

(itemId or "itemName" or "itemLink", "unit")
itemId 
Integer - The numeric ID of the item. ie. 12345
itemName 
String - The Name of the Item, e.g. "Heavy Silk Bandage"
itemLink 
String - The itemLink, when Shift-Clicking items.
unit 
String - The unitId for which the check is done.

Returns Edit

result 
Integer - If in range to perform the action 1. Otherwise 0. nil if the action is invalid.

Example Edit

if ( IsItemInRange("Heavy Silk Bandage","target") ) then
  -- light up a part of the interface
else
  -- darken
end

Common Ranges Edit

Bandages: 18 yards

Ad blocker interference detected!


Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.

Also on Fandom

Random Wiki