Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local PostUpdateHealth = function(s, unit)
- local r, g, b, t
- if(UnitIsPlayer(unit)) then
- local _, class = UnitClass(unit)
- t = oUF.colors.class[class]
- else
- r, g, b = .2, .9, .1
- end
- if(t) then
- r, g, b = t[1], t[2], t[3]
- end
- if(b) then
- local bg = s.bg
- if UnitIsDeadOrGhost(unit) or not UnitIsConnected(unit) then
- bg:SetVertexColor(r/3, g/3, b/3, 0.8)
- else
- bg:SetVertexColor(r, g, b, 1)
- end
- s:SetStatusBarColor(0, 0, 0, .8)
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement