ITEM¶
item¶
item || equipped
- Checks whether a specific item is currently equipped by the player.
Parameters¶
NameOrID: The item name or ID to check for.
Returns BOOL¶
trueif the specified item is currently equipped,falseotherwise.
Example:¶
item.cooldown¶
- Checks the cooldown remaining for the player specific item.
Parameters¶
NameOrID: The item name or ID to check the cooldown for.
Returns NUMBER¶
- The remaining cooldown time in
secondsfor the specified item, or 0 if not on cooldown.
Example:¶
item.usable¶
- Checks if a specific item is usable by the player. This method accepts item name, item ID, slot name, or slot number.
Parameters¶
NameOrID: The item name, item ID, slot name (e.g.,"trinket1","mainhand"), or slot number to check for usability.
Returns BOOL¶
trueif the item is usable,falseotherwise.
!>Note: You can use slot names like "trinket1", "trinket2", "mainhand", etc., or slot numbers (see SlotAlias table).
Example:¶
item.IdBySlot¶
- Returns the item ID equipped in a given inventory slot.
Parameters¶
SLOT: The inventory slot to check, by number or name (e.g.,"head","mainhand","trinket1").
Returns NUMBER¶
- The item ID of the equipped item in that slot, or
-1if none is found.
!>Note: See SlotAlias table for slot names and numbers.
Example:¶
- Using slot name
- Using slot number (13 = Trinket0Slot)
item.count¶
- Checks the count of a specific item in the player's bags.
Parameters¶
NameOrID: The item name or ID to check the count of.
Returns NUMBER¶
- The count of the specified item in the player's bags.
Example:¶
item.range¶
- Checks if the player's target is within range of using a specific item.
Parameters¶
NameOrID: The item name or ID to check the range for.
Returns BOOL¶
trueif the player's target is within range of using the item,falseotherwise.
Example:¶
ilevel¶
- Returns the average item level of the player.
Returns NUMBER¶
- The average item level of the player.
Example:¶
twohand¶
- Checks if the player has a two-handed weapon equipped.
Returns BOOL¶
trueif the player has a two-handed weapon equipped,falseotherwise.
Example:¶
onehand¶
- Checks if the player has a one-handed weapon equipped.
Returns BOOL¶
trueif the player has a one-handed weapon equipped,falseotherwise.
Example:¶
item.enchant¶
- Retrieves the enchant ID applied to an equipped item.
Parameters¶
slotname_or_slotid(string|number): The inventory slot to check. Accepts either:- The numeric slot ID
- The slot name
Returns STRING¶
- Returns the enchant ID as a string if found.
- Returns
"0"if the item has no enchant or"-1"if the slot is empty.
Example:¶
tier¶
- Returns the number of equipped items from a specific tier set for the player's class.
Parameters¶
Tnum: The tier set number (e.g.,"T18", "T19", "T20", etc).
Returns NUMBER¶
- The number of equipped items from the specified tier set for the player's class.