WoW:API GameTooltip SetInventoryItem

From AddOn Studio
Revision as of 04:23, 11 January 2005 by WoWWiki>WoWWiki-Fitz
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
Title -Documentation by fitz-


hasItem, hasCooldown = SetInventoryItem("unit", slot {, nameOnly});


This function sets a tooltip widget to display information for the given unit's given inventory slot.


Arguments


("unit", slot {, nameOnly})
unit
String - the unit whose inventory should be searched
slot
Number - the inventory slot number to search
nameOnly
Unknown - unknown argument

Returns


hasItem, hasCooldown
hasItem
Boolean - is there an item at the given slot?
hasCooldown
Boolean - unknown

Example


-- See if the player has head gear
local headSlot = getglobal("CharacterHeadSlot");
local hasItem, hasCooldown = MyTooltip:SetInventoryItem("player", headSlot:GetID());

Source

This information was obtained via a Google cached page of a Thottbot index of a now expired official US beta forum post by Angarth. It appears to still be correct.


Template:WoW API