Class GraphNode

Public Abstract

Base class for all nodes.

Public Methods

AddPartialConnection (node, cost, isOutgoing, isIncoming)

Add a connection from this node to the specified node.

Public Abstract
ClearConnections (alsoReverse=true)

Remove all connections between this node and other nodes.

Public Abstract
ClosestPointOnNode (p)

Closest point on the surface of this node to the point p.

Public Abstract
ContainsOutgoingConnection (node)

True if this node contains a connection to the given node.

Public
ContainsPoint (point)

Checks if point is inside the node when seen from above.

Public
ContainsPoint (point)

Checks if point is inside the node when seen from above.

Public Abstract
ContainsPointInGraphSpace (point)

Checks if point is inside the node in graph space.

Public Abstract
DecodeVariantPosition (pathNodeIndex, fractionAlongEdge)

The position of the path node during the search.

Public
DeserializeNode (ctx)

Deserializes the node data from a byte array.

Public
DeserializeReferences (ctx)

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

Public
Destroy ()

Destroys the node.

Public
GetConnections (action, connectionFilter=…)

Calls the delegate with all connections from this node.

Public
GetConnections<T> (action, data, connectionFilter=…)

Calls the delegate with all connections from or to this node, and passes a custom data value to the delegate.

Public Abstract
GetConnectionsWithData<T> (node, data)
Public
GetGizmoHashCode ()

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

Public
GetPortal (other, left, right)

Add a portal from this node to the specified node.

Public
Open (path, pathNodeIndex, gScore)

Open the node.

Public Abstract
OpenAtPoint (path, pathNodeIndex, position, gScore)

Open the node at a specific point.

Public Abstract
RandomPointOnSurface ()

A random point on the surface of the node.

Public
RemovePartialConnection (node)

Removes any connection from this node to the specified node.

Public Abstract
SerializeNode (ctx)

Serialized the node data to a byte array.

Public
SerializeReferences (ctx)

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

Public
SetConnectivityDirty ()

Inform the system that the node's connectivity has changed.

Public
SurfaceArea ()

The surface area of the node in square world units.

Public

Public Static Methods

Connect (lhs, rhs, cost, directionality=…)

Adds a connection between two nodes.

Public Static
Disconnect (lhs, rhs)

Removes the connection between two nodes.

Public Static

Public Variables

Area

Connected component that contains the node.

Public
Destroyed
Public
Flags

Holds various bitpacked variables.

Public
Graph

Graph which this node belongs to.

Public
GraphIndex

Graph which contains this node.

Public
NodeIndex

Internal unique index.

Public
Penalty

Penalty cost for walking on this node.

Public
Tag

Node tag.

Public
Walkable

True if the node is traversable.

Public
position

Position of the node in world space.

Public

Public Static Variables

DestroyedNodeIndex
Public Static
InvalidNodeIndex
Public Static
MaxGraphIndex

Max number of graphs-1.

Public Static
MaxHierarchicalNodeIndex
Public Static
MaxTagIndex

Max number of tags - 1.

Public Static

Private/Protected Members

FlagsGraphMask

Mask of graph index bits.

Private Static
FlagsGraphOffset

Start of graph index bits.

Private Static
FlagsHierarchicalIndexOffset

Start of hierarchical node index bits.

Private Static
FlagsTagMask

Mask of tag bits.

Private Static
FlagsTagOffset

Start of tag bits.

Private Static
FlagsWalkableMask

Mask of the walkable bit.

Private Static
FlagsWalkableOffset

Position of the walkable bit.

Private Static
HierarchicalDirtyMask

Mask of the IsHierarchicalNodeDirty bit.

Private Static
HierarchicalDirtyOffset

Start of IsHierarchicalNodeDirty bits.

Private Static
HierarchicalIndexMask

Mask of hierarchical node index bits.

Private Static
HierarchicalNodeIndex

Hierarchical Node that contains this node.

Internal
IsHierarchicalNodeDirty

Some internal bookkeeping.

Internal
NodeIndexMask
Private Static
PathNodeVariants

How many path node variants should be created for each node.

Internal
TemporaryFlag1

Temporary flag for internal purposes.

Internal
TemporaryFlag1Mask
Private Static
TemporaryFlag2

Temporary flag for internal purposes.

Internal
TemporaryFlag2Mask
Private Static
flags

Bitpacked field holding several pieces of data.

Protected
nodeIndex

Internal unique index.

Private
penalty

Penalty cost for walking on this node.

Private

Deprecated Members

AddConnection (node, cost)

Adds a connection to the given node.

Public
ContainsConnection (node)

True if this node contains a connection to the given node.

Public
GetPortal (other, left, right, backwards)

Add a portal from this node to the specified node.

Public
RemoveConnection (node)

Removes a connection to the given node.

Public