Package baritone.api.behavior
Interface IPathingBehavior
- All Superinterfaces:
AbstractGameEventListener,IBehavior,IGameEventListener
- Since:
- 9/23/2018
- Author:
- Brady
-
Method Summary
Modifier and TypeMethodDescriptionbooleanCancels the pathing behavior or the current path calculation, and all processes that could be controlling path.Returns the estimated remaining ticks to the current goal.voidPLEASE never call thisgetGoal()Optional<? extends IPathFinder> getNext()Returns the next path executor, created when planning ahead.getPath()Returns the current path, from the current path executor, if there is one.default booleanhasPath()booleanReturns the estimated remaining ticks in the current pathing segment.ticksRemainingInSegment(boolean includeCurrentMovement) Returns the estimated remaining ticks in the current pathing segment.Methods inherited from interface baritone.api.event.listener.AbstractGameEventListener
onBlockChange, onBlockInteract, onChunkEvent, onPathEvent, onPlayerDeath, onPlayerRotationMove, onPlayerSprintState, onPlayerUpdate, onPostTick, onPreTabComplete, onReceivePacket, onRenderPass, onSendChatMessage, onSendPacket, onTick, onWorldEvent
-
Method Details
-
ticksRemainingInSegment
Returns the estimated remaining ticks in the current pathing segment. Given that the return type is an optional,Optional.empty()will be returned in the case that there is no current segment being pathed.- Returns:
- The estimated remaining ticks in the current segment.
-
ticksRemainingInSegment
Returns the estimated remaining ticks in the current pathing segment. Given that the return type is an optional,Optional.empty()will be returned in the case that there is no current segment being pathed.- Parameters:
includeCurrentMovement- whether or not to include the entirety of the cost of the currently executing movement in the total- Returns:
- The estimated remaining ticks in the current segment.
-
estimatedTicksToGoal
Returns the estimated remaining ticks to the current goal. Given that the return type is an optional,Optional.empty()will be returned in the case that there is no current goal.- Returns:
- The estimated remaining ticks to the current goal.
-
getGoal
- Returns:
- The current pathing goal
-
isPathing
boolean isPathing()- Returns:
- Whether or not a path is currently being executed. This will be false if there's currently a pause.
- See Also:
-
hasPath
- Returns:
- If there is a current path. Note that the path is not necessarily being executed, for example when there is a pause in effect.
- See Also:
-
cancelEverything
boolean cancelEverything()Cancels the pathing behavior or the current path calculation, and all processes that could be controlling path.Basically, "MAKE IT STOP".
- Returns:
- Whether or not the pathing behavior was canceled. All processes are guaranteed to be canceled, but the PathingBehavior might be in the middle of an uncancelable action like a parkour jump
-
forceCancel
void forceCancel()PLEASE never call thisIf cancelEverything was like "kill" this is "sudo kill -9". Or shutting off your computer.
-
getPath
Returns the current path, from the current path executor, if there is one.- Returns:
- The current path
-
getInProgress
Optional<? extends IPathFinder> getInProgress()- Returns:
- The current path finder being executed
-
getCurrent
- Returns:
- The current path executor
-
getNext
Returns the next path executor, created when planning ahead.- Returns:
- The next path executor
-