From fecea289d52f475cc193996e9249680c1947004d Mon Sep 17 00:00:00 2001 From: Wires77 Date: Sat, 6 Sep 2025 22:31:22 -0500 Subject: [PATCH] Fixes #1318, Fixes #1317: Essences mods were trying to apply to incompatible base types --- src/Classes/ItemsTab.lua | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/src/Classes/ItemsTab.lua b/src/Classes/ItemsTab.lua index b52e38d7a2..2017698929 100644 --- a/src/Classes/ItemsTab.lua +++ b/src/Classes/ItemsTab.lua @@ -2516,12 +2516,14 @@ function ItemsTabClass:AddCustomModifierToDisplayItem() local modId = essence.mods[self.displayItem.type] if modId then local mod = self.displayItem.affixes[modId] or data.itemMods.Exclusive[modId] - t_insert(modList, { - label = essence.name .. " " .. "^8[" .. table.concat(mod, "/") .. "]" .. " (" .. (mod.type or "Suffix") .. ")", - mod = mod, - type = "custom", - essence = essence, - }) + if mod then -- passive_hash mods don't get described + t_insert(modList, { + label = essence.name .. " " .. "^8[" .. table.concat(mod, "/") .. "]" .. " (" .. (mod.type or "Suffix") .. ")", + mod = mod, + type = "custom", + essence = essence, + }) + end end end table.sort(modList, function(a, b) @@ -2537,7 +2539,9 @@ function ItemsTabClass:AddCustomModifierToDisplayItem() t_insert(sourceList, { label = "Prefix", sourceId = "PREFIX" }) t_insert(sourceList, { label = "Suffix", sourceId = "SUFFIX" }) end - if self.displayItem.type ~= "Jewel" and self.displayItem.type ~= "Flask" then + buildMods("ESSENCE") -- This is technically a waste if there aren't any essence mods, + -- but it makes it so we don't have to maintain a list of applicable essence-able base types + if #modList > 0 then t_insert(sourceList, { label = "Essence", sourceId = "ESSENCE" }) end t_insert(sourceList, { label = "Custom", sourceId = "CUSTOM" })