Make the "marked recipe" display in Provisioning work better, and add recipe sorting by result level
katkat42 [08-03-14 - 17:11]
Make the "marked recipe" display in Provisioning work better, and add recipe sorting by result level
diff --git a/Provisioning.lua b/Provisioning.lua
index 1d24859..ad2ec9e 100644
--- a/Provisioning.lua
+++ b/Provisioning.lua
@@ -89,7 +89,7 @@ function SousChef:getMarkedIcon(row, marked)
InitializeTooltip(InformationTooltip, rankIcon, RIGHT, -15, 0)
InformationTooltip:AddLine("Marked by: " .. marked)
end)
- if not marked:find(GetUnitName("player")) then
+ if not marked:find(GetUnitName("player"), 1, true) then
rankIcon:SetColor(1,1,1,0.2)
else
rankIcon:SetColor(1,1,1,1)
@@ -207,6 +207,7 @@ function SousChef:RefreshRecipeTree()
for recipeIndex = 1, numRecipes do
local known, recipeName, numIngredients, provisionerLevelReq, qualityReq, specialIngredientType = GetRecipeInfo(recipeListIndex, recipeIndex)
+ local useLevelReq = GetItemLinkRequiredLevel(GetRecipeResultItemLink(recipeListIndex, recipeIndex))
if known then
local numCreatable = CalculateHowManyCouldBeCreated(recipeListIndex, recipeIndex, numIngredients)
if self:DoesRecipePassFilter(specialIngredientType, numCreatable, provisionerLevelReq, qualityReq) then
@@ -217,6 +218,7 @@ function SousChef:RefreshRecipeTree()
name = recipeName,
provisionerLevelReq = provisionerLevelReq,
qualityReq = qualityReq,
+ useLevelReq = useLevelReq,
specialIngredientType = specialIngredientType,
numIngredients = numIngredients,
numCreatable = numCreatable,