View Single Post
10-30-13, 10:59 AM   #4
Clamsoda
A Frostmaul Preserver
Join Date: Nov 2011
Posts: 269
Fixed Phanx's code. The first argument of a hooksecurefunc function is itself, and there was a missing comma between GameTooltip and "SetUnitAura". Fixed, and working great.

Code:
hooksecurefunc(GameTooltip, "SetUnitAura", function(self, unit, index, filter)
	local _, _, _, _, _, _, _, caster = UnitAura(unit, index, filter)
	local name = caster and UnitName(caster)
	if name then
		GameTooltip:AddDoubleLine("Cast by:", name, nil, nil, nil, 1, 1, 1)
		GameTooltip:Show()
	end
end)
  Reply With Quote