/// <summary> /// Destroyes the given node. /// This is to be called after the node has been disconnected from the graph so that it cannot be reached from any other nodes. /// It should only be called during graph updates, that is when the pathfinding threads are either not running or paused. /// /// Warning: This method should not be called by user code. It is used internally by the system. /// </summary> public void DestroyNode(GraphNode node) { if (node.NodeIndex == -1) { return; } nodeIndexPool.Push(node.NodeIndex); for (int i = 0; i < pathHandlers.Length; i++) { pathHandlers[i].DestroyNode(node); } astar.hierarchicalGraph.OnDestroyedNode(node); }
public virtual void PushLoop(LabelOperand continueTarget, LabelOperand breakTarget) { _loopLabels.Push(Tuple.Create(continueTarget, breakTarget)); }