

However, it runs before the contents of the tooltip are updated. OnTooltipSetDefaultAnchor runs every time you mouse over a world object, so it's a reliable script handler to check. This is the text you see in the second line in your tooltip when you mouseover a gathering node, so keep that in mind, just in case it's different from the profession names in some localizations. GameTooltip:HookScript("OnSizeChanged", function()Įnd)It scans tooltip text, so it requires localized version of "Mining" and "Herbalism". GameTooltip:HookScript("OnTooltipSetDefaultAnchor", function(self)

Local text = GameTooltipTextLeft2:GetText()Įlseif text:find(LOCALIZED_HERBALISM) then If GameTooltip:NumLines() ~= 2 then return end Local GameTooltipTextLeft2 = GameTooltipTextLeft2 Local HERBALISM_GLOVES = "Dreadhide Girdle" Code: local MINING_GLOVES = "Biornskin Belt"
