Class GridNode Extends GridNodeBase

Public

Node used for the GridGraph.

Public Methods

ClearConnections (alsoReverse)

Remove all connections from this node.

Public
ClosestPointOnNode (p)
Public
DeserializeNode (ctx)
Public
FloodFill (stack, region)
Public
GetConnections (action)

Calls the delegate with all connections from this node.

Public
GetNeighbourAlongDirection (direction)

Adjacent grid node in the specified direction.

Public
GetPortal (other, left, right, backwards)

Add a portal from this node to the specified node.

Public
GridNode (astar)
Public
HasConnectionInDirection (dir)

True if the node has a connection in the specified direction.

Public
Open (path, pathNode, handler)

Open the node.

Public
ResetConnectionsInternal ()

Disables all grid connections from this node.

Public
SerializeNode (ctx)
Public
SetAllConnectionInternal (connections)

Sets the state of all grid connections.

Public
SetConnectionInternal (dir, value)

Enables or disables a connection in a specified direction on the graph.

Public
UpdateRecursiveG (path, pathNode, handler)
Public

Public Static Methods

GetGridGraph (graphIndex)
Public Static
SetGridGraph (graphIndex, graph)
Public Static

Public Variables

EdgeNode

Work in progress for a feature that required info about which nodes were at the border of the graph.

Public
HasConnectionsToAllEightNeighbours
Public

Inherited Public Members

AddConnection (node, cost)

Add a connection from this node to the specified node.

Public
Area

Connected component that contains the node.

Public
ClearConnections (alsoReverse)

Remove all connections from this node.

Public
ClearCustomConnections (alsoReverse)

Same as ClearConnections, but does not clear grid connections, only custom ones (e.g added by AddConnection or a NodeLink component)

Public
connections
Public
ContainsConnection (node)

Checks if this node has a connection to the specified node.

Public
DeserializeReferences (ctx)

Used to deserialize references to other nodes e.g connections.

Public
Destroyed
Public
Flags

Holds various bitpacked variables.

Public
FloodFill (stack, region)
Public
GetConnections (action)

Calls the delegate with all connections from this node.

Public
GetGizmoHashCode ()

Hash code used for checking if the gizmos need to be updated.

Public
Graph

Graph which this node belongs to.

Public
GraphIndex

Graph which contains this node.

Public
MaxAreaIndex
Public
MaxGraphIndex

Max number of graphs-1.

Public
NodeIndex

Internal unique index.

Public
NodeInGridIndex

The index of the node in the grid.

Public
Open (path, pathNode, handler)

Open the node.

Public
Penalty

Penalty cost for walking on this node.

Public
position

Position of the node in world space.

Public
RandomPointOnSurface ()

A random point on the surface of the node.

Public
RecalculateConnectionCosts ()

Recalculates all connection costs from this node.

Public
RemoveConnection (node)

Removes any connection from this node to the specified node.

Public
SerializeReferences (ctx)

Used to serialize references to other nodes e.g connections.

Public
SurfaceArea ()

The surface area of the node in square world units.

Public
Tag

Node tag.

Public
TmpWalkable

Temporary variable used internally when updating the graph.

Public
UpdateRecursiveG (path, pathNode, handler)
Public
Walkable

True if the node is traversable.

Public
WalkableErosion

Stores walkability before erosion is applied.

Public
XCoordinateInGrid

X coordinate of the node in the grid.

Public
ZCoordinateInGrid

Z coordinate of the node in the grid.

Public

Private/Protected Members

_gridGraphs
Private Static
Destroy ()

Destroys the node.

Package
flags

Bitpacked field holding several pieces of data.

Protected
gridFlags
Protected
GridFlagsConnectionBit0
Private
GridFlagsConnectionMask
Private
GridFlagsConnectionOffset
Private
GridFlagsEdgeNodeMask
Private
GridFlagsEdgeNodeOffset
Private
InternalGridFlags

Internal use only.

Package
nodeInGridIndex

Bitfield containing the x and z coordinates of the node as well as the layer (for layered grid graphs).

Protected
NodeInGridIndexLayerOffset
Protected
NodeInGridIndexMask
Protected

Deprecated Members

GetConnectionInternal (dir)

True if the node has a connection in the specified direction.

Public