1
0
mirror of https://github.com/JezuzLizard/BO2-Reimagined.git synced 2025-06-11 23:57:59 -05:00

Tranzit: fix cornfield_spawn_path_nodes

This commit is contained in:
Jbleezy
2023-04-19 00:21:58 -07:00
parent 7bf1cd4a15
commit 98e19073e3

View File

@ -267,27 +267,27 @@ cornfield_spawn_path_nodes()
spawn_path_node(origin, (0, 0, 0)); spawn_path_node(origin, (0, 0, 0));
} }
for (i = level._spawned_path_nodes.size - 1; i >= level._spawned_path_nodes.size - (new_origins.size + 1); i--) nodes1 = getNodesInRadius( (7040, -128, -196), 64, 0, 512, "Path" );
nodes2 = getNodesInRadius( (7040, -896, -196), 64, 0, 512, "Path" );
foreach (node1 in nodes1)
{ {
node = level._spawned_path_nodes[i]; foreach (node2 in nodes2)
nodes = getNodesInRadius( node.origin, 256, 0, 512, "Path" );
foreach (other_node in nodes)
{ {
if (node.origin[0] - 128 == other_node.origin[0] || node.origin[0] + 128 == other_node.origin[0] || node.origin[1] - 128 == other_node.origin[1] || node.origin[1] + 128 == other_node.origin[1]) link_nodes(node1, node2);
{ link_nodes(node2, node1);
link_nodes(node, other_node);
}
} }
}
for (j = i; j >= level._spawned_path_nodes.size - (new_origins.size + 1); j--) nodes1 = getNodesInRadius( (7168, -128, -196), 64, 0, 512, "Path" );
nodes2 = getNodesInRadius( (7168, -896, -196), 64, 0, 512, "Path" );
foreach (node1 in nodes1)
{
foreach (node2 in nodes2)
{ {
other_node = level._spawned_path_nodes[j]; link_nodes(node1, node2);
link_nodes(node2, node1);
if (node.origin[0] - 128 == other_node.origin[0] || node.origin[0] + 128 == other_node.origin[0] || node.origin[1] - 128 == other_node.origin[1] || node.origin[1] + 128 == other_node.origin[1])
{
link_nodes(node, other_node);
}
} }
} }
} }