Thread Tools Display Modes
Prev Previous Post   Next Post Next
08-06-16, 01:54 AM   #1
Layback_
An Onyxian Warder
Join Date: Feb 2016
Posts: 358
Could it be a bug with aura element?

Hi all,

I have noticed this issue(?) about 2 days ago, tried to figure it out by myself and failed...

The current bug is about the cooldown display of aura element.

Let's say I have these 5 different buffs.



As I get them, cooldowns of each buffs will be displayed properly.

However, when I log-out and re-enter the toon, this strange thing will happen.



The cooldown is increased by '1h'.
(Yeah, I know that '1h' does not actually mean a whole hour in this case, but it is still increased ...)

I've set some prints within L#201~L#208 to see what is going wrong.

Lua Code:
  1. if(cd and not icons.disableCooldown) then
  2.     if(duration and duration > 0) then
  3.         print(icon:GetName() .. ": " .. timeLeft)
  4.         print(icon:GetName() .. ": " .. timeLeft - duration .. ", " .. duration)
  5.  
  6.         cd:SetCooldown(timeLeft - duration, duration)
  7.         cd:Show()
  8.     else
  9.         cd:Hide()
  10.     end
  11. end

And here's the result that I got when I re-entered a toon 3 times.



If my understanding is correct, "timeLeft" variable should remain still, but it is actually (slightly...) increased by certain amount.

The cooldown text '2h' does not seem to be changing until it's expiration as well.

I thought my custom CreateIcon constructor was the one that caused this issue, but it seems to be acting same with default constructor.

Lua Code:
  1. A.CreateAura = function(f, unit)
  2.     A.CreateBuffs(f, unit);
  3.     A.CreateDebuffs(f, unit);
  4. end
  5.  
  6. A.CreateBuffs = function(f, unit)
  7.     local Buffs = CreateFrame("Frame", "$parentBuffs", f);
  8.     Buffs:SetPoint("BOTTOMLEFT", f, "TOPLEFT", 0, 20);
  9.     Buffs:SetSize(G["buff"]["frameSize"], G["buff"]["frameSize"] * 2 - G["buff"]["spacing"]);
  10.  
  11.     Buffs.size = G["buff"]["size"];
  12.     Buffs.spacing = G["buff"]["spacing"];
  13.     Buffs.num = 32;
  14.  
  15.     f.Buffs = Buffs;
  16. end
  17.  
  18. A.CreateDebuffs = function(f, unit)
  19.     local Debuffs = CreateFrame("Frame", "$parentDebuffs", f);
  20.     Debuffs:SetPoint("BOTTOMRIGHT", f, "TOPRIGHT", 0, 20);
  21.     Debuffs:SetSize(G["buff"]["frameSize"], G["buff"]["frameSize"] * 2 - G["buff"]["spacing"]);
  22.  
  23.     Debuffs.size = G["buff"]["size"];
  24.     Debuffs.spacing = G["buff"]["spacing"];
  25.     Debuffs['growth-x'] = "LEFT";
  26.     Debuffs.initialAnchor = "BOTTOMRIGHT";
  27.     Debuffs.num = 32;
  28.  
  29.     f.Debuffs = Debuffs;
  30. end

EDIT: For 30 minutes buff, the cooldown text displays '31m' even if it acutally expires after 25 minutes.

EDIT1: As long as the toon is logged in, it works fine. However, once I log off and re-enter the toon, this strange thing happens

Last edited by Layback_ : 08-06-16 at 02:46 AM.
  Reply With Quote
 

WoWInterface » Featured Projects » oUF (Otravi Unit Frames) » Could it be a bug with aura element?


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off