[:1]What is the tooltip reference to grab only equipped items from your own character profile? I've seen GameTooltip, ItemRefTooltip and ShoppingTooltip#. I've also seen OnTooltipSetItem used for the HookScript. What would be the proper way to achieve what I want?|||Again, answering my own question. I found that hooking
OnTooltipSetItem with
GameTooltip was the best way to get
Characet Info tooltip.
Code:
-- hooks
GameTooltip:HookScript("OnTooltipSetItem", GameTooltip_OnTooltipSetItem)
-- func
function GameTooltip_OnTooltipSetItem()
local _, igtLink = GameTooltip:GetItem()
if igtLink and IsEquippedItem(igtLink) then
local iName, iLink = GetItemInfo(igtLink)
[...]
end
end
No comments:
Post a Comment