[Feature] Is there any possibility to show the default focus/target/targetoftarget at the same time?
starlessly opened this issue ยท 2 comments
Describe the feature
I was wondering if it is possible not to replace the default focus/target/targetoftarget, but to show the default ones and the Unit Frames ones at the same time. Thank you so much!
Describe the implementation
It sounds a little bit silly but my settings only show few status (debuff) on the Unit Frame focus & target, it would be great if the default (original) ones can be exisisting at the same time.
This would most easily be resolved by a snippet I think. I need to make some core changes for that to work, but can prolly work it into the next update.
Added a new Callback that can be listened to that's fired when the addon is loaded, which allows manipulating functions before they are used to initialize the frames.
Will be in next update ๐
Wrote this snippet that can be used to disable hiding certain Blizz frames
local function OverrideHideBlizzard()
-- Make sure CUF is actually loaded
local CUF = _G["CUF"]
if not CUF then return end
-- Store original function so we can still hide frames
local _HideBlizzardUnitFrame = CUF.HideBlizzardUnitFrame
-- Override default function
CUF.HideBlizzardUnitFrame = function(self, unit)
-- Early return on specific units
if unit == "target" or unit == "targetoftarget" or unit == "focus" then
return
end
-- Call orignial function to hide frames we don't want
_HideBlizzardUnitFrame(self, unit)
end
end
Cell:RegisterCallback("CUF_AddonLoaded", "Snippet_OverrideHideBlizzard", OverrideHideBlizzard)