Skip to content
This repository was archived by the owner on Oct 21, 2025. It is now read-only.

Commit c04e12c

Browse files
committed
fix ATD adding stats to attribute nodes
1 parent 4858033 commit c04e12c

File tree

1 file changed

+13
-9
lines changed

1 file changed

+13
-9
lines changed

src/Modules/CalcSetup.lua

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -148,17 +148,21 @@ local function addStats(jewel, node, spec)
148148
end
149149

150150
local function addStatsFromJewelToNode(jewel, node, spec)
151-
local itemsTab = spec.build.itemsTab
152-
--
153-
if itemsTab.activeSocketList then
154-
for _, nodeId in pairs(itemsTab.activeSocketList) do
155-
local _, socketedJewel = itemsTab:GetSocketAndJewelForNodeID(nodeId)
156-
if socketedJewel and socketedJewel.title == "Against the Darkness" then
157-
return addStats(jewel, node, spec)
151+
-- attribute nodes do not count as Small Passives
152+
if not node.isAttribute then
153+
local itemsTab = spec.build.itemsTab
154+
-- if Against the Darkness is socketed, add the stat
155+
if itemsTab.activeSocketList then
156+
for _, nodeId in pairs(itemsTab.activeSocketList) do
157+
local _, socketedJewel = itemsTab:GetSocketAndJewelForNodeID(nodeId)
158+
if socketedJewel and socketedJewel.title == "Against the Darkness" then
159+
return addStats(jewel, node, spec)
160+
end
158161
end
162+
-- activeSocketList isn't init on Load, need to run once
163+
elseif itemsTab.initSockets then
164+
return addStats(jewel, node, spec)
159165
end
160-
elseif itemsTab.initSockets then
161-
return addStats(jewel, node, spec)
162166
end
163167
end
164168
function calcs.buildModListForNode(env, node, incSmallPassiveSkill)

0 commit comments

Comments
 (0)