/* * static int GetObstructionCount(int index1, int index2) * { * if (CheckInvalid(currentNode.NeighborNodes[index1])) { * if (CheckInvalid(currentNode.NeighborNodes[index2])) { * return 2; * } * return 1; * } * if (CheckInvalid(currentNode.NeighborNodes[index2])) * return 1; * return 0; * }*/ static bool CheckInvalid(GridNode gridNode) { return(gridNode.IsNull() || GridHeap.Closed(gridNode) || gridNode.Unpassable()); }
static bool CheckNeighborSearchable() { return(neighbor.IsNull() || GridHeap.Closed(neighbor)); }
static bool CheckNeighborSearchable() { return(neighbor.IsNotNull() && GridHeap.Closed(neighbor) == false); }