Rarity

Rarity

17M Downloads

Avoid creating potentially unnecessary globals for the scanning tooltip

rdw-software opened this issue ยท 0 comments

commented

Source: Discord (DM)

First time I've seen this when looking at _G, use devtool with, find __Rarity
image

Looking at the code, there's one global being created for the tooltip itself:

local scanTip = CreateFrame("GameTooltip", "__Rarity_ScanTip", nil, "GameTooltipTemplate")

The other globals appear to be indexed directly, one for each tooltip line. It's probably cleaner to store them locally, though?

Not sure why they're global. Maybe a limitation of Blizzard's UI? I'd try moving them into the GUI module to see what happens.