Skip to content

Commit

Permalink
Update TOC
Browse files Browse the repository at this point in the history
  • Loading branch information
b-morgan committed Nov 7, 2023
1 parent d0368f3 commit bb78bb0
Show file tree
Hide file tree
Showing 4 changed files with 27 additions and 15 deletions.
27 changes: 14 additions & 13 deletions Plugins/Auctionator.lua
Original file line number Diff line number Diff line change
Expand Up @@ -490,7 +490,7 @@ local function GetBuyout(recipe)
end
if isRetail and Skillet.db.profile.plugins.ATR.minmaxBuyout then
minBuyout, maxBuyout = GetMinMaxBuyout(recipe)
if Skillet.db.char.best_quality then
if Skillet.db.profile.best_quality then
buyout = maxBuyout
else
buyout = minBuyout
Expand All @@ -500,7 +500,7 @@ local function GetBuyout(recipe)
buyout = (Atr_GetAuctionBuyout(itemID) or 0) * recipe.numMade
elseif Auctionator and Auctionator.API.v1 then
if isRetail then
if Skillet.db.char.best_quality then
if Skillet.db.profile.best_quality then
outputItemInfo = C_TradeSkillUI.GetRecipeOutputItemData(recipe.spellID, {}, nil, 8)
else
outputItemInfo = C_TradeSkillUI.GetRecipeOutputItemData(recipe.spellID, {}, nil, 4)
Expand All @@ -512,10 +512,10 @@ local function GetBuyout(recipe)
buyout = (Auctionator.API.v1.GetAuctionPriceByItemID(addonName, itemID) or 0) * recipe.numMade
end
else
return
return 0
end
end
return buyout
return buyout or 0
end

local function GetReagentData(reagent)
Expand Down Expand Up @@ -945,7 +945,7 @@ function plugin.GetExtraText(skill, recipe)
cost = cost + value
end
if recipe.modifiedData then
--DA.DEBUG(0,"GetRecipeData: modifiedData= "..DA.DUMP(recipe.modifiedData))
--DA.DEBUG(0,"GetExtraText: modifiedData= "..DA.DUMP(recipe.modifiedData))
for i=1,#recipe.modifiedData do
local value, needed, id, name, custom = GetReagentData(recipe.modifiedData[i])
value = AddExtraText(value, needed, id, name, custom)
Expand Down Expand Up @@ -1013,28 +1013,28 @@ function plugin.GetExtraText(skill, recipe)
end
lastSold = Journalator.API.v1.GetRealmLastSoldByItemName(addonName, itemName)
lastBought = Journalator.API.v1.GetRealmLastBoughtByItemName(addonName, itemName)
--DA.DEBUG(0,"itemName= "..tostring(itemName)..", successCount= "..tostring(successCount)..", failedCount= "..tostring(failedCount)..", lastSold= "..tostring(lastSold)..", lastBought= "..tostring(lastBought))
--DA.DEBUG(0,"GetExtraText(1): itemName= "..tostring(itemName)..", successCount= "..tostring(successCount)..", failedCount= "..tostring(failedCount)..", lastSold= "..tostring(lastSold)..", lastBought= "..tostring(lastBought))
elseif itemName then
salesRate, failedCount, lastSold, lastBought = Journalator.Tooltips.GetSalesInfo(itemName)
--DA.DEBUG(0,"itemName= "..tostring(itemName)..", salesRate= "..tostring(salesRate)..", failedCount= "..tostring(failedCount)..", lastSold= "..tostring(lastSold)..", lastBought= "..tostring(lastBought))
--DA.DEBUG(0,"GetExtraText(2): itemName= "..tostring(itemName)..", salesRate= "..tostring(salesRate)..", failedCount= "..tostring(failedCount)..", lastSold= "..tostring(lastSold)..", lastBought= "..tostring(lastBought))
end
if salesRate and string.find(salesRate,"%%") then
if salesRate and (string.find(salesRate,"%%") or DA.DebugShow) then
label = label.." salesRate:\n"
extra_text = extra_text..tostring(salesRate).."\n"
end
if successCount and successCount > 0 then
if successCount and (successCount > 0 or DA.DebugShow) then
label = label.." successCount:\n"
extra_text = extra_text..tostring(successCount).."\n"
end
if failedCount and failedCount > 0 then
if failedCount and (failedCount > 0 or DA.DebugShow) then
label = label.." failedCount:\n"
extra_text = extra_text..tostring(failedCount).."\n"
end
if lastSold and lastSold > 0 then
if lastSold and (lastSold > 0 or DA.DebugShow) then
label = label.." lastSold:\n"
extra_text = extra_text..Skillet:FormatMoneyFull(lastSold, true).."\n"
end
if lastBought and lastBought > 0 then
if lastBought and (lastBought > 0 or DA.DebugShow) then
label = label.." lastBought:\n"
extra_text = extra_text..Skillet:FormatMoneyFull(lastBought, true).."\n"
end
Expand All @@ -1054,6 +1054,7 @@ function plugin.RecipeNameSuffix(skill, recipe)
if not recipe then return end
--DA.DEBUG(0,"RecipeNameSuffix: recipe= "..DA.DUMP1(recipe,1))
local itemID = recipe.itemID
--DA.DEBUG(0,"RecipeNameSuffix: itemID= "..tostring(itemID)..", type= "..type(itemID))
--
-- Check for Enchanting. Most recipes don't produce an item but
-- we still should get reagent prices.
Expand Down Expand Up @@ -1104,7 +1105,7 @@ function plugin.RecipeNameSuffix(skill, recipe)
salesRate = string.format("%2.0f", 0).."%"
end
end
--DA.DEBUG(0, "RecipeNameSuffix: successCount="..tostring(successCount)..", failedCount="..tostring(failedCount)..", salesRate="..tostring(salesRate))
--DA.DEBUG(0, "RecipeNameSuffix: itemName= "..tostring(itemName)..", successCount="..tostring(successCount)..", failedCount="..tostring(failedCount)..", salesRate="..tostring(salesRate))
end

--
Expand Down
4 changes: 3 additions & 1 deletion Skillet.lua
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,9 @@ Skillet.unknownRecipe = {

function Skillet:DisableBlizzardFrame()
DA.DEBUG(0,"DisableBlizzardFrame()")
if self.BlizzardTradeSkillFrame == nil then
if not ProfessionsFrame then
DA.WARN("DisableBlizzardFrame: ProfessionsFrame is nil")
elseif self.BlizzardTradeSkillFrame == nil then
self.BlizzardTradeSkillFrame = ProfessionsFrame
self.tradeSkillHide = ProfessionsFrame:GetScript("OnHide")
ProfessionsFrame:SetScript("OnHide", nil)
Expand Down
2 changes: 1 addition & 1 deletion Skillet.toc
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
## Interface: 100107
## Interface: 100200
## Title: Skillet |cff7fff7f -Ace3-|r
## IconTexture: Interface\AddOns\Skillet\Icons\Skillet.tga
## Notes: A replacement tradeskill window
Expand Down
9 changes: 9 additions & 0 deletions SkilletNewsData.lua
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,15 @@ local isWrath = WOW_PROJECT_ID == WOW_PROJECT_WRATH_CLASSIC

Skillet.NewsName = "Skillet News"
Skillet.NewsData = {
{ version = "5.23",
data = {
{ name = "Changes",
data = {
{ header = "TOC", body = "Update TOC to 100200" },
},
},
},
},
{ version = "5.22",
data = {
{ name = "Changes",
Expand Down

0 comments on commit bb78bb0

Please sign in to comment.