Where did the post from nevereg go? I thought about it a bit more and I think going for the GameTooltip_SetBackdropStyle hook might be a the best approach.
We can get rid of so many other hooks and we have access to the backdrop attributes from blizzard.
You could just match style against GAME_TOOLTIP_BACKDROP_STYLE_AZERITE_ITEM and know that the style you are handling is for azerite.
alternative A
Lua Code:
local azerite = style == GAME_TOOLTIP_BACKDROP_STYLE_AZERITE_ITEM or false
alternative B
Lua Code:
local _, itemLink = self:GetItem()
local azerite = false
if itemLink and (C_AzeriteEmpoweredItem.IsAzeriteEmpoweredItemByID(itemLink) or C_AzeriteItem.IsAzeriteItemByID(itemLink)) then
azerite = true
end
I am going to change my tooltip to that method. It seems convenient for what I am trying to do.
*edit* Commit hooking into SetBackdropStyle
https://github.com/zorker/rothui/com...ceda45d583d2fa