Thread Tools Display Modes
05-24-13, 04:07 PM   #21
GeneralWurst
A Defias Bandit
Join Date: Oct 2006
Posts: 2
Can someone please make this addon work with Skillet and Advanced Tradeskill Window?
  Reply With Quote
05-25-13, 06:59 AM   #22
Tonyleila
A Molten Giant
 
Tonyleila's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2010
Posts: 758
Yes woud be cool if someone coud look into support of Skillet and Advanced and Tradeskill Window.

Also I there was a request to color the catogery names of gems. Like "Blue Gems" colored in blue.

If anyone wants to be added to the wowinterface project please contact me.

This is how the lua file of the addon looks right now:

Code:
local disabled = false
local button

local tip = CreateFrame('GameTooltip', 'GemStatsTip')
local line1 = tip:CreateFontString()
local line2 = tip:CreateFontString()
local line3 = tip:CreateFontString()

tip:AddFontStrings(tip:CreateFontString(), tip:CreateFontString())
tip:AddFontStrings(line1, tip:CreateFontString())
tip:AddFontStrings(line2, tip:CreateFontString())
tip:AddFontStrings(line3, tip:CreateFontString())

local JEWELCRAFTING_S = GetSpellInfo(25229)
local GEM_S = '%+[0-9]+.*'

local match = string.match

local function GetGemStats(id)
    tip:SetOwner(WorldFrame, 'ANCHOR_NONE')
    tip:SetTradeSkillItem(id)

    if(tip:IsShown()) then
        return match(line1:GetText() or '', GEM_S) or match(line2:GetText() or '', GEM_S) or match(line3:GetText() or '', GEM_S)
    end
end

local function Update()
    if(GetTradeSkillLine() ~= JEWELCRAFTING_S) then
        if(button) then
            button:Hide()
        end

        return
    else
        button:Show()
    end

    if(not IsTradeSkillReady()) then return end
    if(disabled) then return end

    local filterBar = TradeSkillFilterBar:IsShown()
    for index = 1, TRADE_SKILLS_DISPLAYED, 1 do
        local buttonIndex = filterBar and index + 1 or index

        local button = _G['TradeSkillSkill' .. buttonIndex]
        if(button) then
            local stats = GetGemStats(button:GetID())
            if(stats) then
                _G['TradeSkillSkill' .. buttonIndex .. 'Text']:SetText(stats)
            end
        end
    end
end

local f = CreateFrame('Frame')
f:RegisterEvent('ADDON_LOADED')
f:SetScript('OnEvent', function(self, event, name)
    if(name == 'Blizzard_TradeSkillUI') then
        button = CreateFrame('Button', 'SomeRandomButton123', TradeSkillFrame, 'UIPanelButtonTemplate')
        button:SetPoint('TOPRIGHT', TradeSkillFrameCloseButton, 'TOPLEFT', -4, -1)
        button:SetSize(15, 15)
        button:SetText('J')
        button:SetScript('OnClick', function()
            disabled = not disabled
            TradeSkillFrame_Update()
        end)

        hooksecurefunc('TradeSkillFrame_Update', Update)
    end
end)
__________________
Author of: LeilaUI and Aurora: Missing Textures
__________________
  Reply With Quote
05-26-13, 08:43 AM   #23
Vis
A Pyroguard Emberseer
 
Vis's Avatar
Join Date: Mar 2009
Posts: 1,827
Originally Posted by GeneralWurst View Post
Can someone please make this addon work with Skillet and Advanced Tradeskill Window?
Originally Posted by Tonyleila View Post
Yes woud be cool if someone coud look into support of Skillet and Advanced and Tradeskill Window.
Skillet already has some support for searching crafted items by stats. You can also search by materials that are used in the crafted recipe. You can type nearly anything into the Filter box to narrow down what youd like to see.
Attached Thumbnails
Click image for larger version

Name:	WoWScrnShot_052613_103543.jpg
Views:	344
Size:	397.1 KB
ID:	7738  Click image for larger version

Name:	WoWScrnShot_052613_103836.jpg
Views:	332
Size:	409.0 KB
ID:	7739  Click image for larger version

Name:	WoWScrnShot_052613_104421.jpg
Views:	345
Size:	413.1 KB
ID:	7740  

Last edited by Vis : 05-26-13 at 08:46 AM.
  Reply With Quote
05-26-13, 12:29 PM   #24
GeneralWurst
A Defias Bandit
Join Date: Oct 2006
Posts: 2
Originally Posted by Vis View Post
Skillet already has some support for searching crafted items by stats. You can also search by materials that are used in the crafted recipe. You can type nearly anything into the Filter box to narrow down what youd like to see.
Ok, what about ATSW then?
  Reply With Quote
05-26-13, 12:39 PM   #25
Vis
A Pyroguard Emberseer
 
Vis's Avatar
Join Date: Mar 2009
Posts: 1,827
ATSW may also, but I don't use that one so I can't say for sure one way or another.
  Reply With Quote

WoWInterface » AddOns, Compilations, Macros » AddOn Search/Requests » Jewelcrafting


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