Interface PathfinderResult


public interface PathfinderResult
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns the found Path regardless if successful or not.
    Returns the state of the pathfinding.
    boolean
    Whether the pathfinder has failed to reach its target.
    boolean
    Whether a pathfinder has resulted in a fallback.
    boolean
    Returns whether the pathfinding was successful.
  • Method Details

    • successful

      boolean successful()
      Returns whether the pathfinding was successful.
      Returns:
      true if the pathfinding was successful
    • hasFailed

      boolean hasFailed()
      Whether the pathfinder has failed to reach its target. This includes PathState.FAILED, PathState.LENGTH_LIMITED, PathState.MAX_ITERATIONS_REACHED and PathState.FALLBACK
      Returns:
      Whether the pathfinder has failed to reach its target
    • hasFallenBack

      boolean hasFallenBack()
      Whether a pathfinder has resulted in a fallback.
      Returns:
      Whether a pathfinder has resulted in a fallback
    • getPathState

      PathState getPathState()
      Returns the state of the pathfinding.
      Returns:
      The PathState
    • getPath

      Path getPath()
      Returns the found Path regardless if successful or not. The path is empty if the pathfinding failed.
      Returns:
      The found Path