View Single Post
08-20-14, 07:28 PM   #6
jeruku
A Cobalt Mageweaver
 
jeruku's Avatar
AddOn Author - Click to view addons
Join Date: Oct 2010
Posts: 223
If you want you can use the fact that the UpdateAuraPositions(at tail-end of UpdateAuras) loops through the buffs as well. Works great for hiding or repositioning those squirmy target de/buffs and adding timers.

Code:
hooksecurefunc('TargetFrame_UpdateBuffAnchor', function(self, name, index, ...)
	if name == 'TargetFrameBuff' then
		local _, _, _, debuffType, _, _, _, _, _, id = UnitBuff(unit, index)
		if not id then return end

		local stealable = _G[name .. "Buff" .. index .."Stealable"]
		if not stealable then return end

		stealable:SetShown(debuffType == "Magic" and spellIDs[id])
	end
end)
__________________
"I have not failed, I simply found 10,000 ways that did not work." - Thomas Edison
  Reply With Quote