WoWInterface

WoWInterface (https://www.wowinterface.com/forums/index.php)
-   oUF (Otravi Unit Frames) (https://www.wowinterface.com/forums/forumdisplay.php?f=87)
-   -   Overwriting an element (https://www.wowinterface.com/forums/showthread.php?t=49951)

Pyrates 09-21-14 04:31 AM

Overwriting an element
 
Hi there!

I can add an element to ouf via

Lua Code:
  1. oUF:AddElement('RaidDebuffs', Update, Enable, Disable)

In an older version of ouf, I could simply call AddElement again to overwrite the element with another one. After an update (I'm not sure about the version numbers, I'm basing my stuff on Tukui Beta), there's an error message and I assume that the element wasn't overwritten.

What can I do here without modifying the original code, i.e. I can't remove the lua code that adds the element. Is there something like oUF:RemoveElement or the like?

Thanks for any pointers!

haste 09-21-14 05:09 AM

I guess TukUI modified oUF to not error on name conflicts. The error has been there since the first commit of the element system in 2008.

Don't think there's a way to solve with without modifying at least some files.

Pyrates 09-21-14 01:31 PM

Ah, I just realized tukui had some conditional loading, so raiddebuffs wasn't actually loaded, so no conflict possible. But thanks for pointing out it's a name collision, I can easily rename my own copy to, say, "NotAuraWatch". Thanks!

Rainrider 09-28-14 01:35 PM

Isn't this doable by using oUF:DisableElement("ElementName")?

haste 09-28-14 02:33 PM

No, that would just disable the element on the frame and globally within oUF.


All times are GMT -6. The time now is 07:21 AM.

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