Ahh, missed the scoping...
Code:
local PostUpdateHealth = function(unit, min, max)
-- set health background color
local color = RAID_CLASS_COLORS[select(2, UnitClass(unit))]
if (UnitIsPlayer(unit) and color) then
self.Health:SetBackdropColor(color.r, color.g, color.b, .5)
else
local r, g, b = UnitSelectionColor(unit)
self.Health:SetBackdropColor(r, g, b, .5)
end
end
Still untested