Ok I tried that but the text is still behind the buffs/auras/debuffs. No issues but nothing is changing.
Also it happens that the text-position is different for some player frames (resettet, from what I changed it to in the first place)
And the outline is missing too (which I added). But I think thats related to the sort per role/name/group option.
Code:
hooksecurefunc("DefaultCompactUnitFrameSetup", function(self)
local fontSize = 12 * min(DefaultCompactUnitFrameSetupOptions.height / 36, DefaultCompactUnitFrameSetupOptions.width / 72)
local statusText = self.statusText
statusText:SetFont("Fonts\\ARIALN.TTF", fontSize, "OUTLINE")
statusText:SetHeight(fontSize)
statusText:SetShadowColor(0, 0, 0, 1)
statusText:SetShadowOffset(1, -1)
statusText:ClearAllPoints()
statusText:SetPoint("CENTER", 0, -6)
statusText:SetDrawLayer("OVERLAY", 7)
end)
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.colorOverridden then
statusText.colorOverridden = true
statusText:SetTextColor(0.95, 0.1, 0.1, 1)
end
elseif statusText.colorOverridden then
statusText.colorOverridden = nil
statusText:SetTextColor(0.5, 0.5, 0.5, 1)
end
end
end)