Thread Tools Display Modes
10-28-16, 08:31 AM   #1
zork
A Pyroguard Emberseer
 
zork's Avatar
AddOn Author - Click to view addons
Join Date: Jul 2008
Posts: 1,740
TemporaryEnchantFrame_Hide only hiding 2 out of 3 TempEnchant buttons

function TemporaryEnchantFrame_Hide
Lua Code:
  1. function TemporaryEnchantFrame_Hide()
  2.     if ( BuffFrame.numEnchants > 0 ) then
  3.         BuffFrame.numEnchants = 0;
  4.         BuffFrame_Update();    
  5.     end
  6.     TempEnchant1:Hide();
  7.     TempEnchant1Duration:Hide();
  8.     TempEnchant2:Hide();
  9.     TempEnchant2Duration:Hide();
  10. end
https://github.com/tomrus88/Blizzard...Frame.lua#L346

The function is missing the third button.
https://github.com/tomrus88/Blizzard...Frame.xml#L149

When the player is in a vehicle the TempEnchant3 button will pop up because TemporaryEnchantFrame_Update() is not called.

Function should look like this
Lua Code:
  1. function TemporaryEnchantFrame_Hide()
  2.     if ( BuffFrame.numEnchants > 0 ) then
  3.         BuffFrame.numEnchants = 0;
  4.         BuffFrame_Update();    
  5.     end
  6.     --Hide enchants
  7.     for i=1, NUM_TEMP_ENCHANT_FRAMES do
  8.         _G["TempEnchant"..i]:Hide();
  9.         _G["TempEnchant"..i.."Duration"]:Hide();
  10.     end
  11. end
__________________
| Simple is beautiful.
| WoWI AddOns | GitHub | Zork (WoW)

"I wonder what the non-pathetic people are doing tonight?" - Rajesh Koothrappali (The Big Bang Theory)
 
 

WoWInterface » Site Forums » Archived Beta Forums » Legion Beta archived threads » TemporaryEnchantFrame_Hide only hiding 2 out of 3 TempEnchant buttons

Thread Tools
Display Modes

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