Quantcast WoWInterface - View Single Post - Need help coloring "widget"
View Single Post
05-27-11, 02:17 PM   #10
A Wyrmkin Dreamwalker
Sauerkraut's Avatar
AddOn Author - Click to view addons
Join Date: Oct 2008
Posts: 52
Again way over my head. I am amazed anything I write even works. Anyhow using PostUpdate works and seems to be doing exactly what I needed.

local PostUpdatePower = function(Power, unit, min, max)
	local _, ptype = UnitPowerType("player")
        if(oUF.colors.power[ptype]) then
		r, g, b = unpack(oUF.colors.power[ptype])
	Power.arrow:SetVertexColor(r, g, b)
		s.PostUpdate = PostUpdatePower
It may not be the most elegant or the best way to do it, but it seems to work.
  Reply With Quote