Class AStarNode
java.lang.Object
de.gurkenlabs.litiengine.entities.behavior.AStarNode
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidclear()Clears the assigned costs and the predecessor.doubledoublegetFCost()Gets the total costs for this node.doublegetGCost()Gets the costs so far for this node.intgetGridX()intgetGridY()doublegetHCost()Gets the estimated costs for this node.doublebooleanvoidsetGCost(double gCost) voidsetHCost(double hCost) voidsetPenalty(double penalty) voidsetPredecessor(AStarNode predecessor) voidsetWalkable(boolean walkable) toString()
-
Constructor Details
-
AStarNode
-
-
Method Details
-
getBounds
-
getCosts
-
getFCost
public double getFCost()Gets the total costs for this node.- Returns:
- The total costs.
-
getGCost
public double getGCost()Gets the costs so far for this node.- Returns:
- The costs so far.
-
getGridX
public int getGridX() -
getGridY
public int getGridY() -
getHCost
public double getHCost()Gets the estimated costs for this node.- Returns:
- The estimated costs.
-
getLocation
-
getPenalty
public double getPenalty() -
getPredecessor
-
isWalkable
public boolean isWalkable() -
setGCost
public void setGCost(double gCost) -
setHCost
public void setHCost(double hCost) -
setPenalty
public void setPenalty(double penalty) -
setPredecessor
-
setWalkable
public void setWalkable(boolean walkable) -
clear
public void clear()Clears the assigned costs and the predecessor. -
toString
-