I just came back to retail and i have ran into an issue with a couple of my interface scripts to recolor some panels. I modified the character / spellbook and a couple other frames already but for some reason some of them have broken and i cant seem to find the issue, The code works fine if i use it in a kgpanels format but not in my addon script. This is one of the shorter ones maybe make it easier for an answer
Credits for this script goes to SUI creator: Syiana
Not sure if they are active anymore but the scipt isnt updated.
If anybody could help me sort this issue thatd be appreicated.
Code:
local Module = SUI:NewModule("Skins.Talents");
local _,class = UnitClass("player")
function Module:OnEnable()
if (SUI:Color()) then
local f = CreateFrame("Frame")
f:RegisterEvent("ADDON_LOADED")
f:SetScript("OnEvent", function(self, event, name)
if name == "Blizzard_ClassTalentUI" then
for i, v in pairs({
ClassTalentFrame.NineSlice.TopEdge,
ClassTalentFrame.NineSlice.RightEdge,
ClassTalentFrame.NineSlice.BottomEdge,
ClassTalentFrame.NineSlice.LeftEdge,
ClassTalentFrame.NineSlice.TopRightCorner,
ClassTalentFrame.NineSlice.TopLeftCorner,
ClassTalentFrame.NineSlice.BottomLeftCorner,
ClassTalentFrame.NineSlice.BottomRightCorner, }) do
v:SetVertexColor(RAID_CLASS_COLORS[class].r, RAID_CLASS_COLORS[class].g, RAID_CLASS_COLORS[class].b)
end
end)
end
end