Class GroundPathNavigation
java.lang.Object
net.minecraft.world.entity.ai.navigation.PathNavigation
net.minecraft.world.entity.ai.navigation.GroundPathNavigation
- Direct Known Subclasses:
Creaking.CreakingPathNavigation, Strider.StriderPathNavigation, WallClimberNavigation
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate booleanprivate booleanFields inherited from class PathNavigation
hasDelayedRecomputation, lastStuckCheck, lastStuckCheckPos, lastTimeoutCheck, level, maxDistanceToWaypoint, mob, nodeEvaluator, path, speedModifier, tick, timeLastRecompute, timeoutCachedNode, timeoutLimit, timeoutTimer -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanprotected booleancreatePath(BlockPos pos, int reachRange) Returns path to given BlockPoscreatePath(Entity target, int reachRange) Returns a path to the given entity or nullprotected PathFindercreatePathFinder(int maxVisitedNodes) (package private) final BlockPosfindSurfacePosition(LevelChunk chunk, BlockPos pos, int reachRange) private intprotected Vec3protected booleanhasValidPathType(PathType pathType) voidsetAvoidSun(boolean avoidSun) voidsetCanPathToTargetsBelowSurface(boolean canPathToTargetsBelowSurface) voidsetCanWalkOverFences(boolean canWalkOverFences) protected voidtrimPath()Methods inherited from class PathNavigation
canCutCorner, canFloat, canMoveDirectly, createPath, createPath, createPath, createPath, createPath, createPath, doStuckDetection, followThePath, getGroundY, getMaxDistanceToWaypoint, getNodeEvaluator, getPath, getTargetPos, isClearForMovementBetween, isDone, isInProgress, isStableDestination, isStuck, moveTo, moveTo, moveTo, moveTo, recomputePath, resetMaxVisitedNodesMultiplier, setCanFloat, setCanOpenDoors, setMaxVisitedNodesMultiplier, setRequiredPathLength, setSpeedModifier, shouldRecomputePath, stop, tick, updatePathfinderMaxVisitedNodes
-
Field Details
-
avoidSun
private boolean avoidSun -
canPathToTargetsBelowSurface
private boolean canPathToTargetsBelowSurface
-
-
Constructor Details
-
GroundPathNavigation
-
-
Method Details
-
createPathFinder
- Specified by:
createPathFinderin classPathNavigation
-
canUpdatePath
protected boolean canUpdatePath()- Specified by:
canUpdatePathin classPathNavigation
-
getTempMobPos
- Specified by:
getTempMobPosin classPathNavigation
-
createPath
Returns path to given BlockPos- Overrides:
createPathin classPathNavigation
-
findSurfacePosition
-
createPath
Returns a path to the given entity or null- Overrides:
createPathin classPathNavigation
-
getSurfaceY
private int getSurfaceY() -
trimPath
protected void trimPath()- Overrides:
trimPathin classPathNavigation
-
hasValidPathType
-
setAvoidSun
public void setAvoidSun(boolean avoidSun) -
setCanWalkOverFences
public void setCanWalkOverFences(boolean canWalkOverFences) -
setCanPathToTargetsBelowSurface
public void setCanPathToTargetsBelowSurface(boolean canPathToTargetsBelowSurface)
-