From 29492263fe6b0ea56a746ead6e6ec25cd96f3314 Mon Sep 17 00:00:00 2001 From: Apollyonn Date: Sun, 20 Jan 2019 12:57:36 +0200 Subject: [PATCH] update --- ElvUI/modules/skins/blizzard/craft.lua | 18 +++++++----------- ElvUI/modules/skins/blizzard/tradeskill.lua | 18 +++++++----------- ElvUI/modules/skins/blizzard/trainer.lua | 12 ++++++------ 3 files changed, 20 insertions(+), 28 deletions(-) diff --git a/ElvUI/modules/skins/blizzard/craft.lua b/ElvUI/modules/skins/blizzard/craft.lua index 2a65ead..364174d 100644 --- a/ElvUI/modules/skins/blizzard/craft.lua +++ b/ElvUI/modules/skins/blizzard/craft.lua @@ -238,22 +238,18 @@ local function LoadSkin() end local _, _, craftType = GetCraftInfo(id) + local r, g, b if craftType == "trivial" then - CraftHighlightFrame.Left:SetGradientAlpha("Horizontal", 0.5, 0.5, 0.5, 0.40, 0.5, 0.5, 0.5, 0) - CraftHighlightFrame.Right:SetGradientAlpha("Horizontal", 0.5, 0.5, 0.5, 0, 0.5, 0.5, 0.5, 0.40) + r, g, b = 0.5, 0.5, 0.5 elseif craftType == "easy" then - CraftHighlightFrame.Left:SetGradientAlpha("Horizontal", 0, 1, 0, 0.35, 0, 1, 0, 0) - CraftHighlightFrame.Right:SetGradientAlpha("Horizontal", 0, 1, 0, 0, 0, 1, 0, 0.35) + r, g, b = 0, 1, 0 elseif craftType == "medium" then - CraftHighlightFrame.Left:SetGradientAlpha("Horizontal", 1, 1, 0, 0.35, 1, 1, 0, 0) - CraftHighlightFrame.Right:SetGradientAlpha("Horizontal", 1, 1, 0, 0, 1, 1, 0, 0.35) + r, g, b = 1, 1, 0 elseif craftType == "optimal" then - CraftHighlightFrame.Left:SetGradientAlpha("Horizontal", 1, 0.45, 0.15, 0.35, 1, 0.45, 0.15, 0) - CraftHighlightFrame.Right:SetGradientAlpha("Horizontal", 1, 0.45, 0.15, 0, 1, 0.45, 0.15, 0.35) - elseif craftType == "difficult" then - CraftHighlightFrame.Left:SetGradientAlpha("Horizontal", 1, 0, 0, 0.35, 1, 0, 0, 0) - CraftHighlightFrame.Right:SetGradientAlpha("Horizontal", 1, 0, 0, 0, 1, 0, 0, 0.35) + r, g, b = 1, 0.45, 0.15 end + CraftHighlightFrame.Left:SetGradientAlpha("Horizontal", r, g, b, 0.35, r, g, b, 0) + CraftHighlightFrame.Right:SetGradientAlpha("Horizontal", r, g, b, 0, r, g, b, 0.35) local numReagents = GetCraftNumReagents(id) for i = 1, numReagents, 1 do diff --git a/ElvUI/modules/skins/blizzard/tradeskill.lua b/ElvUI/modules/skins/blizzard/tradeskill.lua index d2176f3..604cfe6 100644 --- a/ElvUI/modules/skins/blizzard/tradeskill.lua +++ b/ElvUI/modules/skins/blizzard/tradeskill.lua @@ -250,22 +250,18 @@ local function LoadSkin() end local _, skillType = GetTradeSkillInfo(id) + local r, g, b if skillType == "trivial" then - TradeSkillHighlightFrame.Left:SetGradientAlpha("Horizontal", 0.5, 0.5, 0.5, 0.40, 0.5, 0.5, 0.5, 0) - TradeSkillHighlightFrame.Right:SetGradientAlpha("Horizontal", 0.5, 0.5, 0.5, 0, 0.5, 0.5, 0.5, 0.40) + r, g, b = 0.5, 0.5, 0.5 elseif skillType == "easy" then - TradeSkillHighlightFrame.Left:SetGradientAlpha("Horizontal", 0, 1, 0, 0.35, 0, 1, 0, 0) - TradeSkillHighlightFrame.Right:SetGradientAlpha("Horizontal", 0, 1, 0, 0, 0, 1, 0, 0.35) + r, g, b = 0, 1, 0 elseif skillType == "medium" then - TradeSkillHighlightFrame.Left:SetGradientAlpha("Horizontal", 1, 1, 0, 0.35, 1, 1, 0, 0) - TradeSkillHighlightFrame.Right:SetGradientAlpha("Horizontal", 1, 1, 0, 0, 1, 1, 0, 0.35) + r, g, b = 1, 1, 0 elseif skillType == "optimal" then - TradeSkillHighlightFrame.Left:SetGradientAlpha("Horizontal", 1, 0.45, 0.15, 0.35, 1, 0.45, 0.15, 0) - TradeSkillHighlightFrame.Right:SetGradientAlpha("Horizontal", 1, 0.45, 0.15, 0, 1, 0.45, 0.15, 0.35) - elseif skillType == "difficult" then - TradeSkillHighlightFrame.Left:SetGradientAlpha("Horizontal", 1, 0, 0, 0.35, 1, 0, 0, 0) - TradeSkillHighlightFrame.Right:SetGradientAlpha("Horizontal", 1, 0, 0, 0, 1, 0, 0, 0.35) + r, g, b = 1, 0.45, 0.15 end + TradeSkillHighlightFrame.Left:SetGradientAlpha("Horizontal", r, g, b, 0.35, r, g, b, 0) + TradeSkillHighlightFrame.Right:SetGradientAlpha("Horizontal", r, g, b, 0, r, g, b, 0.35) local numReagents = GetTradeSkillNumReagents(id) for i = 1, numReagents, 1 do diff --git a/ElvUI/modules/skins/blizzard/trainer.lua b/ElvUI/modules/skins/blizzard/trainer.lua index 41341cd..2fbae4f 100644 --- a/ElvUI/modules/skins/blizzard/trainer.lua +++ b/ElvUI/modules/skins/blizzard/trainer.lua @@ -96,16 +96,16 @@ local function LoadSkin() end local _, _, serviceType = GetTrainerServiceInfo(id) + local r, g, b if serviceType == "available" then - ClassTrainerSkillHighlightFrame.Left:SetGradientAlpha("Horizontal", 0, 1, 0, 0.35, 0, 1, 0, 0) - ClassTrainerSkillHighlightFrame.Right:SetGradientAlpha("Horizontal", 0, 1, 0, 0, 0, 1, 0, 0.35) + r, g, b = 0, 1, 0 elseif serviceType == "used" then - ClassTrainerSkillHighlightFrame.Left:SetGradientAlpha("Horizontal", 0.5, 0.5, 0.5, 0.40, 0.5, 0.5, 0.5, 0) - ClassTrainerSkillHighlightFrame.Right:SetGradientAlpha("Horizontal", 0.5, 0.5, 0.5, 0, 0.5, 0.5, 0.5, 0.40) + r, g, b = 0.5, 0.5, 0.5 elseif serviceType == "unavailable" then - ClassTrainerSkillHighlightFrame.Left:SetGradientAlpha("Horizontal", 1, 0, 0, 0.35, 1, 0, 0, 0) - ClassTrainerSkillHighlightFrame.Right:SetGradientAlpha("Horizontal", 1, 0, 0, 0, 1, 0, 0, 0.35) + r, g, b = 1, 0, 0 end + ClassTrainerSkillHighlightFrame.Left:SetGradientAlpha("Horizontal", r, g, b, 0.35, r, g, b, 0) + ClassTrainerSkillHighlightFrame.Right:SetGradientAlpha("Horizontal", r, g, b, 0, r, g, b, 0.35) end) CLASS_TRAINER_SKILLS_DISPLAYED = 19