Class AbsoluteHeuristic

  • All Implemented Interfaces:
    org.dreambot.api.methods.walking.pathfinding.impl.astar.heuristic.Heuristic

    public class AbsoluteHeuristic
    extends java.lang.Object
    implements org.dreambot.api.methods.walking.pathfinding.impl.astar.heuristic.Heuristic
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      float getCost​(int x, int y, int tx, int ty)
      Get the additional heuristic cost of the given tile.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • AbsoluteHeuristic

        public AbsoluteHeuristic()
    • Method Detail

      • getCost

        public float getCost​(int x,
                             int y,
                             int tx,
                             int ty)
        Get the additional heuristic cost of the given tile. This controls the order in which tiles are searched while attempting to find a path to the target location. The lower the cost the more likely the tile will be searched.
        Specified by:
        getCost in interface org.dreambot.api.methods.walking.pathfinding.impl.astar.heuristic.Heuristic
        Parameters:
        x - The x coordinate of the tile being evaluated
        y - The y coordinate of the tile being evaluated
        tx - The x coordinate of the destination location
        ty - Teh y coordinate of the destination location
        Returns:
        The cost associated with the given tile