added multi source lookup for items

This commit is contained in:
telkar-rg
2023-11-12 11:07:10 +01:00
parent d76a363d37
commit b886af56b5
+10 -3
View File
@@ -512,11 +512,18 @@ local function ProcessTooltip(tooltip, name, link)
-- these are the cpu intensive parts of the update .. so do them only if necessary -- these are the cpu intensive parts of the update .. so do them only if necessary
cachedSource = nil cachedSource = nil
if addon.Options:Get("TooltipSource") == 1 then if addon.Options:Get("TooltipSource") == 1 then
local Instance, Boss = addon.Loots:GetSource(itemID) local Instance, Boss
local Instance_Boss = addon.Loots:GetSource_multi(itemID)
if not Instance_Boss then
Instance, Boss = addon.Loots:GetSource(itemID)
if Instance then
Instance_Boss = format("%s, %s", Instance, Boss)
end
end
cachedItemID = itemID -- we have searched this ID .. cachedItemID = itemID -- we have searched this ID ..
if Instance then if Instance_Boss then
cachedSource = format("%s: %s, %s", GOLD..L["Source"], TEAL..Instance, Boss) cachedSource = format("%s: %s", GOLD..L["Source"], TEAL..Instance_Boss)
end end
end end