A* Pathfinding Project
4.3.2
The A* Pathfinding Project for Unity 3D
|
Calculates the grid connections for a single node. More...
Calculates the grid connections for a single node.
Note that to ensure that connections are completely up to date after updating a node you have to calculate the connections for both the changed node and its neighbours.
In a layered grid graph, this will recalculate the connections for all nodes in the (x,z) cell (it may have multiple layers of nodes).
Public Member Functions | |
void | Execute () |
bool | IsValidConnection (float4 nodeAPosition, int nodeB, float4 up) |
Check if a connection to node B is valid. More... | |
Public Attributes | |
IntRect | bounds |
bool | cutCorners |
float | maxClimb |
NumNeighbours | neighbours |
NativeArray< int > | neighbourXOffsets |
NativeArray< int > | neighbourZOffsets |
NativeArray< Vector3 > | nodePositions |
NativeArray< bool > | nodeWalkable |
NativeArray< int > | outNodeConnections |
Vector3 | up |
bool | use2D |
void Execute | ( | ) |
bool IsValidConnection | ( | float4 | nodeAPosition, |
int | nodeB, | ||
float4 | up | ||
) |
Check if a connection to node B is valid.
Node A is assumed to be walkable already
IntRect bounds |
bool cutCorners |
float maxClimb |
NumNeighbours neighbours |
NativeArray<int> neighbourXOffsets |
NativeArray<int> neighbourZOffsets |
NativeArray<Vector3> nodePositions |
NativeArray<bool> nodeWalkable |
NativeArray<int> outNodeConnections |
Vector3 up |
bool use2D |