fix crash caused by invalid impossible escape keystone (#7731)

This commit is contained in:
trimbe
2024-07-20 17:57:17 -07:00
committed by GitHub
parent b536f24931
commit 459d5bb330

View File

@@ -896,7 +896,7 @@ function PassiveSpecClass:NodesInIntuitiveLeapLikeRadius(node)
if item.jewelData and item.jewelData.impossibleEscapeKeystone then
for keyName, keyNode in pairs(item.jewelData.impossibleEscapeKeystones) do
if self.tree.keystoneMap[keyName].nodesInRadius then
if self.tree.keystoneMap[keyName] and self.tree.keystoneMap[keyName].nodesInRadius then
for affectedNodeId in pairs(self.tree.keystoneMap[keyName].nodesInRadius[radiusIndex]) do
if self.nodes[affectedNodeId].alloc then
t_insert(result, self.nodes[affectedNodeId])