WoWInterface

WoWInterface (https://www.wowinterface.com/forums/index.php)
-   oUF (Otravi Unit Frames) (https://www.wowinterface.com/forums/forumdisplay.php?f=87)
-   -   aura tooltip error (https://www.wowinterface.com/forums/showthread.php?t=39081)

Dawn 02-25-11 06:51 PM

aura tooltip error
 
I get this error when I mouseover a debuff on my raidframes.

I do not get an error when I mouseover a buff/debuff on target or focus.
I disabled my tooltip addon to see if it's the cause, it doesn't matter.
I'm using the latest version of oUF from Github, but tried to use 1.5.8 aswell.

Code:

Message: Interface\AddOns\oUF\elements\aura.lua:8: Usage: GameTooltip:SetUnitAura("unit", [index] or ["name", "rank"][, "filter"])
Time: 02/26/11 01:45:45
Count: 1
Stack: [C]: in function `SetUnitAura'
Interface\AddOns\oUF\elements\aura.lua:8: in function `UpdateTooltip'
Interface\AddOns\oUF\elements\aura.lua:15: in function <Interface\AddOns\oUF\elements\aura.lua:11>

Locals: (*temporary) = GameTooltip {
 0 = <userdata>
 FadeOut = <function> defined @Interface\AddOns\dTooltip\dTooltip.lua:40
 updateTooltip = 0.086999992653728
 comparing = false
 shoppingTooltips = <table> {
 }
}
(*temporary) = nil
(*temporary) = 1
(*temporary) = "HARMFUL"

My debuff code is pretty straight forward ...
Code:

                -- debuffs
                local Debuffs = CreateFrame("Frame", nil, self.Health)
                Debuffs:SetSize(22, 22)
                Debuffs:SetPoint("TOPLEFT", self.Health, "TOPLEFT", 1, -1)
                Debuffs.initialAnchor = "TOPLEFT"
                Debuffs.num = 1
                Debuffs.size = 22
                Debuffs.PostCreateIcon = PostCreateIcon
                Debuffs.PostUpdateIcon = PostUpdateIcon       
                Debuffs.CustomFilter = CustomFilter
                self.Debuffs = Debuffs

I also tried it without
Code:

                Debuffs.PostCreateIcon = PostCreateIcon
                Debuffs.PostUpdateIcon = PostUpdateIcon

and still get the exact same error ... which is really strange. :rolleyes:

Any ideas?

tecu 02-26-11 02:35 AM

It looks like the unit argument to SetUnitAura is nil. Which would mean, from oUF/elements/auras.lua, 'self.parent:GetParent().unit' is nil (self is the aura button, self.parent is the auras frame, and self.parent:GetParent() should be the unit frame itself).

You parent your buff frame to self.Health (self in this case is your unit frame), so the :GetParent() call above is returning the Health element rather than the unit frame.

The easiest temp fix would be to change self.parent.GetParent().unit to self.parent.__owner.unit in auras.lua.

haste 02-26-11 06:01 AM

Looks like I forgot to change that one when I added .__owner. :(

Just so I don't forget about it: https://github.com/haste/oUF/issues/75

Dawn 02-26-11 09:19 AM

I'm just glad it wasn't me. I was about going crazy on this. :banana:

Seems to work fine with the latest version on github, thanks. :)


All times are GMT -6. The time now is 06:56 PM.

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