View Single Post
06-30-13, 04:59 AM   #1
Belechannas
A Warpwood Thunder Caller
Join Date: May 2010
Posts: 86
nUI5: flyout spell cooldowns ignored

After being annoyed long enough with nUI not showing the cooldowns of my Shaman's totems (why does nUI hate Shaman?!), I dug into the code and figured out why.

The problem is that now all totems are stored in the spellbook as flyout lists, and nUI essentially ignores spells buried in there when building its spell table (which is in turn used to build the cooldown table). In particular, when scanning the spellbook, it finds the top-level flyout item (which has nil spell name, and hence is ignored), but doesn't "drill down" to the spells contained.

This presumably affects various other flyout abilities (hunter and warlock pets, rogue poisons, mage ports being some I can think of), but none of these have cooldowns (I think).

The solution is slightly messy, since nUI tracks spells using their index in the spellbook, which does not exist for flyout abilities.

The attached hack seems to work, but it is hardly beautiful code; it also contains the fix for passive spell cooldowns (e.g. Reincarnation) discussed in the above-linked thread.

Edit: to be clear, the problem is totems (and any other flyout spells) not appearing on the cooldown bar of the HUD.
Attached Files
File Type: lua nUI_CooldownBar.lua (34.7 KB, 493 views)

Last edited by Belechannas : 06-30-13 at 05:06 AM.