public void Reset() //寻路开始时清空成本和指向 { _state = AStarEightDirectionsNodeState.unopened; _nextNode = null; _startToCost = 0; _toEndCost = 0; _totalCost = 0; }
public void Open(AStarEightDirectionsHeapNode nextNode, Vector2 destination) { _state = AStarEightDirectionsNodeState.opened; _nextNode = nextNode; ComputeCost(destination); }
public void Open(Vector2 destination) { _state = AStarEightDirectionsNodeState.opened; ComputeCost(destination); }
public void Close() { _state = AStarEightDirectionsNodeState.closed; }