@@ -142,23 +142,26 @@ local function setRadiusJewelStats(radiusJewel, radiusJewelStats)
142
142
end
143
143
144
144
local function addStats (jewel , node , spec )
145
- -- reset node stats to base or override for attributes
146
- if spec .hashOverrides and spec .hashOverrides [node .id ] then
147
- node .sd = copyTable (spec .hashOverrides [node .id ].sd , true )
148
- else
149
- node .sd = copyTable (spec .tree .nodes [node .id ].sd , true )
150
- end
145
+ -- short term to avoid running the logic on AddItemTooltip
146
+ if not spec .build .treeTab .skipTimeLostJewelProcessing then
147
+ -- reset node stats to base or override for attributes
148
+ if spec .hashOverrides and spec .hashOverrides [node .id ] then
149
+ node .sd = copyTable (spec .hashOverrides [node .id ].sd , true )
150
+ else
151
+ node .sd = copyTable (spec .tree .nodes [node .id ].sd , true )
152
+ end
151
153
152
- local radiusJewelStats = { }
153
- setRadiusJewelStats (jewel , radiusJewelStats )
154
- for _ , stat in ipairs (radiusJewelStats ) do
155
- -- the node and stat types match, add sd to node if it's not already there and it's an 'also grant' mod
156
- if not isValueInTable (node .sd , stat .sd ) and ((node .type == " Notable" and stat .isNotable ) or (node .type == " Normal" and not stat .isNotable ))
157
- and stat .toAdd then
158
- t_insert (node .sd , stat .sd )
154
+ local radiusJewelStats = { }
155
+ setRadiusJewelStats (jewel , radiusJewelStats )
156
+ for _ , stat in ipairs (radiusJewelStats ) do
157
+ -- the node and stat types match, add sd to node if it's not already there and it's an 'also grant' mod
158
+ if not isValueInTable (node .sd , stat .sd ) and ((node .type == " Notable" and stat .isNotable ) or (node .type == " Normal" and not stat .isNotable ))
159
+ and stat .toAdd then
160
+ t_insert (node .sd , stat .sd )
161
+ end
159
162
end
163
+ spec .tree :ProcessStats (node )
160
164
end
161
- spec .tree :ProcessStats (node )
162
165
return node .modList
163
166
end
164
167
@@ -169,7 +172,7 @@ local function addStatsFromJewelToNode(jewel, node, spec)
169
172
-- if the Time-Lost jewel is socketed, add the stat
170
173
if itemsTab .activeSocketList then
171
174
for _ , nodeId in pairs (itemsTab .activeSocketList ) do
172
- local _ , socketedJewel = itemsTab :GetSocketAndJewelForNodeID (nodeId )
175
+ local socketIndex , socketedJewel = itemsTab :GetSocketAndJewelForNodeID (nodeId )
173
176
if socketedJewel and socketedJewel .baseName :find (" Time%-Lost" ) == 1 then
174
177
return addStats (jewel , node , spec )
175
178
end
0 commit comments