View Single Post
01-05-20, 11:17 AM   #4
Vrul
A Scalebane Royal Guard
 
Vrul's Avatar
AddOn Author - Click to view addons
Join Date: Nov 2007
Posts: 404
Not tested but you can try:
Code:
hooksecurefunc("CompactUnitFrame_UpdateStatusText", function(self)
	local statusText = self.statusText
	if statusText and statusText:IsShown() then
		if self.optionTable.healthText == "losthealth" and tonumber(statusText:GetText() or "") then
			if not statusText.fontOverridden then
				statusText.fontOverridden = true
				statusText:SetFont("Fonts\\ARIALN.TTF", 16)
				statusText:SetTextColor(0.95, 0.2, 0.2)
			end
		elseif statusText.fontOverridden then
			statusText.fontOverridden = nil
			statusText:SetFont("Fonts\\FRIZQT__.TTF", 12)
			statusText:SetTextColor(0.5, 0.5, 0.5)
		end
	end
end)
  Reply With Quote