C# Class HPASharp.HierarchicalMap

Abstract maps represent, as the name implies, an abstraction built over the concrete map.
Inheritance: IMap
Afficher le fichier Open project: Rydra/HierarchicalPathfinder Class Usage Examples

Méthodes publiques

Méthode Description
AddEdge ( int sourceNodeId, int destNodeId, int cost, int level = 1, bool inter = false ) : void
BelongToSameCluster ( int node1Id, int node2Id, int level ) : bool
FindClusterForPosition ( Position pos ) : Cluster
GetCluster ( int id ) : Cluster
GetCurrentClusterRectangle ( ) : Rectangle
GetHeuristic ( int startNodeId, int targetNodeId ) : int
GetNeighbours ( int nodeId ) : IEnumerable

Gets the neighbours(successors) of the nodeId for the level set in the currentLevel

GetNodeEdges ( int nodeId ) : AbsTilingEdgeInfo>.Edge>.List
GetOffset ( int level ) : int
HierarchicalMap ( ConcreteMap concreteMap, int clusterSize, int maxLevel ) : System
PositionInCurrentCluster ( Position position ) : bool
SetCurrentCluster ( Position pos, int level ) : void

Defines the bounding box of the cluster we want to process based on a given level and a position in the grid

SetCurrentCluster ( int x, int y, int offset ) : void

Defines the bounding box of the cluster we want to process

SetCurrentLevel ( int level ) : void
SetType ( TileType tileType ) : void

Method Details

AddEdge() public méthode

public AddEdge ( int sourceNodeId, int destNodeId, int cost, int level = 1, bool inter = false ) : void
sourceNodeId int
destNodeId int
cost int
level int
inter bool
Résultat void

BelongToSameCluster() public méthode

public BelongToSameCluster ( int node1Id, int node2Id, int level ) : bool
node1Id int
node2Id int
level int
Résultat bool

FindClusterForPosition() public méthode

public FindClusterForPosition ( Position pos ) : Cluster
pos Position
Résultat Cluster

GetCluster() public méthode

public GetCluster ( int id ) : Cluster
id int
Résultat Cluster

GetCurrentClusterRectangle() public méthode

public GetCurrentClusterRectangle ( ) : Rectangle
Résultat HPASharp.Infrastructure.Rectangle

GetHeuristic() public méthode

public GetHeuristic ( int startNodeId, int targetNodeId ) : int
startNodeId int
targetNodeId int
Résultat int

GetNeighbours() public méthode

Gets the neighbours(successors) of the nodeId for the level set in the currentLevel
public GetNeighbours ( int nodeId ) : IEnumerable
nodeId int
Résultat IEnumerable

GetNodeEdges() public méthode

public GetNodeEdges ( int nodeId ) : AbsTilingEdgeInfo>.Edge>.List
nodeId int
Résultat AbsTilingEdgeInfo>.Edge>.List

GetOffset() public méthode

public GetOffset ( int level ) : int
level int
Résultat int

HierarchicalMap() public méthode

public HierarchicalMap ( ConcreteMap concreteMap, int clusterSize, int maxLevel ) : System
concreteMap ConcreteMap
clusterSize int
maxLevel int
Résultat System

PositionInCurrentCluster() public méthode

public PositionInCurrentCluster ( Position position ) : bool
position Position
Résultat bool

SetCurrentCluster() public méthode

Defines the bounding box of the cluster we want to process based on a given level and a position in the grid
public SetCurrentCluster ( Position pos, int level ) : void
pos Position
level int
Résultat void

SetCurrentCluster() public méthode

Defines the bounding box of the cluster we want to process
public SetCurrentCluster ( int x, int y, int offset ) : void
x int
y int
offset int
Résultat void

SetCurrentLevel() public méthode

public SetCurrentLevel ( int level ) : void
level int
Résultat void

SetType() public méthode

public SetType ( TileType tileType ) : void
tileType TileType
Résultat void