Class HeuristicWeights
java.lang.Object
de.metaphoriker.pathetic.api.pathing.configuration.HeuristicWeights
Represents a set of weights used to calculate a heuristic for the A* pathfinding algorithm. These
weights influence the prioritization of different path characteristics during the search.
This class defines weights for the following distance metrics:
- Manhattan Distance: Prioritizes direct movement along axes.
- Octile Distance: Allows for diagonal movement for finer-grained pathing.
- Perpendicular Distance: Penalizes deviation from the straight line to the target, aiding in smoother paths.
- Height Difference: Factors in elevation changes when calculating path costs.
-
Field Summary
Modifier and TypeFieldDescriptionstatic final HeuristicWeights
Provides a set of weights strongly prioritizing the shortest direct path, even if diagonally.static final HeuristicWeights
Provides a set of default heuristic weights that may be suitable for natural pathfinding. -
Constructor Summary
-
Method Summary
-
Field Details
-
NATURAL_PATH_WEIGHTS
Provides a set of default heuristic weights that may be suitable for natural pathfinding. These values can be adjusted for specific scenarios. -
DIRECT_PATH_WEIGHTS
Provides a set of weights strongly prioritizing the shortest direct path, even if diagonally.
-
-
Constructor Details
-
HeuristicWeights
public HeuristicWeights()
-