View Single Post
03-31-17, 03:32 PM   #4
Aftermathhqt
A Molten Giant
 
Aftermathhqt's Avatar
AddOn Author - Click to view addons
Join Date: Dec 2009
Posts: 784
Originally Posted by Layback_ View Post
Hi kurapica.iga,

Thank you for your advice

What about the borders for debuffs?

As you know some debuffs have a different border colors based on their types (like red or blue).

Would this be considered on BuffButton_OnLoad or SetTexture functions?

I would do this

Lua Code:
  1. function SkinDebuff()
  2.     local button, icon;
  3.     for i = LayAura.debuffs + 1, DEBUFF_ACTUAL_DISPLAY do
  4.         button = _G["DebuffButton" .. i];
  5.         icon = _G["DebuffButton" .. i .. "Icon"];
  6.        
  7.         local Border = _G[button .. "Border"]
  8.         if (Border) then
  9.             Border:SetTexture(nil)
  10.             Border:Hide()
  11.        
  12.             local R, G, B = Border:GetVertexColor()
  13.             button:SetColorHere
  14.         end
  15.  
  16.         CutOffEdges(icon);
  17.         SetTemplate(button);
  18.     end
  19.  
  20.     LayAura.debuffs = DEBUFF_ACTUAL_DISPLAY;
  21. end
  Reply With Quote