Quantcast
Issue Changing CraftFrame Colors - WoWInterface
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
05-17-21, 03:02 AM   #1
pinkney
A Defias Bandit
Join Date: May 2021
Posts: 3
Issue Changing CraftFrame Colors

I have an addon (Lorti-UI-Classic) that recolors the default WoW UI frames. However it's not applied to the craft frame and tradeskill frames. I am trying to add that.

Here's an example of the code it has that successfully recolors the Character frame:

--PAPERDOLL/Characterframe
local a, b, c, d, _, e = PaperDollFrame:GetRegions()
for _, v in pairs({a, b, c, d, e

})do
v:SetVertexColor(.35, .35, .35)
end


When I try to do the same to the CraftFrame window, it throws a Lua error.

The code I used is basically the same as above:

--CraftFrame
local a, b, c, d, _, e = CraftFrame:GetRegions()
for _, v in pairs({a, b, c, d, e

})do
v:SetVertexColor(.35, .35, .35)
end


I used "/framestack" to get the names of the windows. I did it for CraftFrame and TradeFrame. The error says:

Message: Interface\AddOns\Lorti-UI-Classic\core\frames.lua:383: attempt to index global 'CraftFrame' (a nil value)

Even if I try to just manually set the region windows without the loop, it still doesn't seem to work. However there is no error -- I think it just doesn't recolor anything.

Any ideas? Thanks in advance!

Last edited by pinkney : 05-17-21 at 05:57 AM.
  Reply With Quote
 

WoWInterface » Developer Discussions » Lua/XML Help » Issue Changing CraftFrame Colors

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