WoWInterface

WoWInterface (https://www.wowinterface.com/forums/index.php)
-   oUF (Otravi Unit Frames) (https://www.wowinterface.com/forums/forumdisplay.php?f=87)
-   -   Use default UI "TargetFrameSpellBar" Frame (https://www.wowinterface.com/forums/showthread.php?t=38245)

matt.wow 01-08-11 04:04 AM

Use default UI "TargetFrameSpellBar" Frame
 
Hi,
I always used the default UI target castbar for my oUF layout. Since oUF 1.5 the code didn't work anymore.

Code:

TargetFrameSpellBar:RegisterEvent("UNIT_SPELLCAST_START")
TargetFrameSpellBar:RegisterEvent("UNIT_SPELLCAST_STOP")
TargetFrameSpellBar:RegisterEvent("UNIT_SPELLCAST_FAILED")
TargetFrameSpellBar:RegisterEvent("UNIT_SPELLCAST_INTERRUPTED")
TargetFrameSpellBar:RegisterEvent("UNIT_SPELLCAST_DELAYED")
TargetFrameSpellBar:RegisterEvent("UNIT_SPELLCAST_CHANNEL_START")
TargetFrameSpellBar:RegisterEvent("UNIT_SPELLCAST_CHANNEL_UPDATE")
TargetFrameSpellBar:RegisterEvent("UNIT_SPELLCAST_CHANNEL_STOP")
TargetFrameSpellBar:RegisterEvent("UNIT_SPELLCAST_INTERRUPTIBLE")
TargetFrameSpellBar:RegisterEvent("UNIT_SPELLCAST_NOT_INTERRUPTIBLE ")
TargetFrameSpellBar:RegisterEvent("PLAYER_ENTERING_WORLD")
TargetFrameSpellBar:RegisterEvent("PLAYER_TARGET_CHANGED")

TargetFrameSpellBar:SetParent(UIParent)
TargetFrameSpellBar:ClearAllPoints()
TargetFrameSpellBar:SetPoint('BOTTOM', UIParent, 0, 265)

function RemoveBlizzFunction()
end

Target_Spellbar_AdjustPosition = RemoveBlizzFunction
TargetFrameSpellBar:SetScript("OnShow", function() end)

How do I get the castbar back?

matt

haste 01-08-11 04:51 AM

You need to run the code after the oUF target frame has been spawned.

matt.wow 01-08-11 05:48 AM

Thanks. Worked.

sirann 09-11-14 12:00 AM

Apologies for the necro, but instead of adding this code after the desired unit's spawn, is it possible to stop ouf from disabling it in the first place, in the effort of efficiency?

zork 09-11-14 01:58 AM

You could embed oUF into your layout and adjust whatever part of oUF is disabling the castbar.

haste 09-11-14 03:22 AM

Quote:

Originally Posted by sirann (Post 296523)
Apologies for the necro, but instead of adding this code after the desired unit's spawn, is it possible to stop ouf from disabling it in the first place, in the effort of efficiency?

You could replace the spellbar's UnregisterAllEvents and SetParent with an empty function, so oUFs function call does nothing.

Alternatively, just re-enable it and spend your time optimizing something else. You aren't exactly gaining a lot by doing this. :)

sirann 09-11-14 07:10 AM

thank you both :)


All times are GMT -6. The time now is 10:23 AM.

vBulletin © 2024, Jelsoft Enterprises Ltd
© 2004 - 2022 MMOUI