Package net.minecraft.entity.ai.pathing
Class EntityNavigation
java.lang.Object
net.minecraft.entity.ai.pathing.EntityNavigation
- Direct Known Subclasses:
BirdNavigation,MobNavigation,SwimNavigation
public abstract class EntityNavigation extends Object
- Mappings:
Namespace Name official azlintermediary net/minecraft/class_1408named net/minecraft/entity/ai/pathing/EntityNavigation
-
Field Summary
Fields Modifier and Type Field Description private intcurrentDistanceprotected longcurrentNodeMsprotected doublecurrentNodeTimeoutprotected PathcurrentPathprivate BlockPoscurrentTargetprotected MobEntityentityprotected longlastActiveTickMsprotected Vec3ilastNodePositionprotected longlastRecalculateTimeprivate booleannearPathStartPosprotected PathNodeMakernodeMakerprotected floatnodeReachProximityIf the Chebyshev distance from the entity to the next node is less than or equal to this value, the entity is considered "reached" the node.private PathNodeNavigatorpathNodeNavigatorprotected Vec3dpathStartPosprotected intpathStartTimeprivate floatrangeMultiplierprotected booleanshouldRecalculateprotected doublespeedprotected inttickCountprotected Worldworld -
Constructor Summary
Constructors Constructor Description EntityNavigation(MobEntity mob, World world) -
Method Summary
Modifier and Type Method Description protected voidadjustPath()Adjusts the current path according to various special obstacles that may be in the way, for example sunlightprotected abstract booleancanPathDirectlyThrough(Vec3d origin, Vec3d target, int sizeX, int sizeY, int sizeZ)booleancanSwim()protected voidcheckTimeouts(Vec3d currentPos)protected voidcontinueFollowingPath()protected abstract PathNodeNavigatorcreatePathNodeNavigator(int range)PathfindPathTo(double x, double y, double z, int distance)PathfindPathTo(Entity entity, int distance)PathfindPathTo(BlockPos target, int distance)protected PathfindPathToAny(Set<BlockPos> positions, int range, boolean bool, int distance)PathfindPathToAny(Stream<BlockPos> positions, int distance)PathgetCurrentPath()PathNodeMakergetNodeMaker()protected abstract Vec3dgetPos()The position to act as if the entity is at for pathfinding purposesBlockPosgetTargetPos()protected abstract booleanisAtValidPosition()booleanisFollowingPath()booleanisIdle()protected booleanisInLiquid()booleanisNearPathStartPos()booleanisValidPosition(BlockPos pos)private booleanmethod_27799(Vec3d vec3d)Pathmethod_29934(Set<BlockPos> set, int int2)voidonBlockChanged(BlockPos pos)voidrecalculatePath()private voidresetNode()private voidresetNodeAndStop()voidresetRangeMultiplier()voidsetCanSwim(boolean canSwim)voidsetRangeMultiplier(float rangeMultiplier)voidsetSpeed(double speed)booleanshouldRecalculatePath()booleanstartMovingAlong(Path path, double speed)booleanstartMovingTo(double x, double y, double z, double speed)booleanstartMovingTo(Entity entity, double speed)voidstop()voidtick()
-
Field Details
-
entity
- Mappings:
Namespace Name Mixin selector official aLazl;a:Larj;intermediary field_6684Lnet/minecraft/class_1408;field_6684:Lnet/minecraft/class_1308;named entityLnet/minecraft/entity/ai/pathing/EntityNavigation;entity:Lnet/minecraft/entity/mob/MobEntity;
-
world
- Mappings:
Namespace Name Mixin selector official bLazl;b:Lbtv;intermediary field_6677Lnet/minecraft/class_1408;field_6677:Lnet/minecraft/class_1937;named worldLnet/minecraft/entity/ai/pathing/EntityNavigation;world:Lnet/minecraft/world/World;
-
currentPath
- Mappings:
Namespace Name Mixin selector official cLazl;c:Ldct;intermediary field_6681Lnet/minecraft/class_1408;field_6681:Lnet/minecraft/class_11;named currentPathLnet/minecraft/entity/ai/pathing/EntityNavigation;currentPath:Lnet/minecraft/entity/ai/pathing/Path;
-
speed
protected double speed- Mappings:
Namespace Name Mixin selector official dLazl;d:Dintermediary field_6668Lnet/minecraft/class_1408;field_6668:Dnamed speedLnet/minecraft/entity/ai/pathing/EntityNavigation;speed:D
-
tickCount
protected int tickCount- Mappings:
Namespace Name Mixin selector official eLazl;e:Iintermediary field_6675Lnet/minecraft/class_1408;field_6675:Inamed tickCountLnet/minecraft/entity/ai/pathing/EntityNavigation;tickCount:I
-
pathStartTime
protected int pathStartTime- Mappings:
Namespace Name Mixin selector official fLazl;f:Iintermediary field_6674Lnet/minecraft/class_1408;field_6674:Inamed pathStartTimeLnet/minecraft/entity/ai/pathing/EntityNavigation;pathStartTime:I
-
pathStartPos
- Mappings:
Namespace Name Mixin selector official gLazl;g:Ldiu;intermediary field_6672Lnet/minecraft/class_1408;field_6672:Lnet/minecraft/class_243;named pathStartPosLnet/minecraft/entity/ai/pathing/EntityNavigation;pathStartPos:Lnet/minecraft/util/math/Vec3d;
-
lastNodePosition
- Mappings:
Namespace Name Mixin selector official hLazl;h:Lgs;intermediary field_6680Lnet/minecraft/class_1408;field_6680:Lnet/minecraft/class_2382;named lastNodePositionLnet/minecraft/entity/ai/pathing/EntityNavigation;lastNodePosition:Lnet/minecraft/util/math/Vec3i;
-
currentNodeMs
protected long currentNodeMs- Mappings:
Namespace Name Mixin selector official iLazl;i:Jintermediary field_6670Lnet/minecraft/class_1408;field_6670:Jnamed currentNodeMsLnet/minecraft/entity/ai/pathing/EntityNavigation;currentNodeMs:J
-
lastActiveTickMs
protected long lastActiveTickMs- Mappings:
Namespace Name Mixin selector official jLazl;j:Jintermediary field_6669Lnet/minecraft/class_1408;field_6669:Jnamed lastActiveTickMsLnet/minecraft/entity/ai/pathing/EntityNavigation;lastActiveTickMs:J
-
currentNodeTimeout
protected double currentNodeTimeout- Mappings:
Namespace Name Mixin selector official kLazl;k:Dintermediary field_6682Lnet/minecraft/class_1408;field_6682:Dnamed currentNodeTimeoutLnet/minecraft/entity/ai/pathing/EntityNavigation;currentNodeTimeout:D
-
nodeReachProximity
protected float nodeReachProximityIf the Chebyshev distance from the entity to the next node is less than or equal to this value, the entity is considered "reached" the node.- Mappings:
Namespace Name Mixin selector official lLazl;l:Fintermediary field_6683Lnet/minecraft/class_1408;field_6683:Fnamed nodeReachProximityLnet/minecraft/entity/ai/pathing/EntityNavigation;nodeReachProximity:F
-
shouldRecalculate
protected boolean shouldRecalculate- Mappings:
Namespace Name Mixin selector official mLazl;m:Zintermediary field_6679Lnet/minecraft/class_1408;field_6679:Znamed shouldRecalculateLnet/minecraft/entity/ai/pathing/EntityNavigation;shouldRecalculate:Z
-
lastRecalculateTime
protected long lastRecalculateTime- Mappings:
Namespace Name Mixin selector official nLazl;n:Jintermediary field_6685Lnet/minecraft/class_1408;field_6685:Jnamed lastRecalculateTimeLnet/minecraft/entity/ai/pathing/EntityNavigation;lastRecalculateTime:J
-
nodeMaker
- Mappings:
Namespace Name Mixin selector official oLazl;o:Ldcs;intermediary field_6678Lnet/minecraft/class_1408;field_6678:Lnet/minecraft/class_8;named nodeMakerLnet/minecraft/entity/ai/pathing/EntityNavigation;nodeMaker:Lnet/minecraft/entity/ai/pathing/PathNodeMaker;
-
currentTarget
- Mappings:
Namespace Name Mixin selector official pLazl;p:Lfx;intermediary field_20293Lnet/minecraft/class_1408;field_20293:Lnet/minecraft/class_2338;named currentTargetLnet/minecraft/entity/ai/pathing/EntityNavigation;currentTarget:Lnet/minecraft/util/math/BlockPos;
-
currentDistance
private int currentDistance- Mappings:
Namespace Name Mixin selector official qLazl;q:Iintermediary field_20294Lnet/minecraft/class_1408;field_20294:Inamed currentDistanceLnet/minecraft/entity/ai/pathing/EntityNavigation;currentDistance:I
-
rangeMultiplier
private float rangeMultiplier- Mappings:
Namespace Name Mixin selector official rLazl;r:Fintermediary field_21642Lnet/minecraft/class_1408;field_21642:Fnamed rangeMultiplierLnet/minecraft/entity/ai/pathing/EntityNavigation;rangeMultiplier:F
-
nearPathStartPos
private boolean nearPathStartPos- Mappings:
Namespace Name Mixin selector official tLazl;t:Zintermediary field_26820Lnet/minecraft/class_1408;field_26820:Znamed nearPathStartPosLnet/minecraft/entity/ai/pathing/EntityNavigation;nearPathStartPos:Z
-
-
Constructor Details
-
EntityNavigation
- Mappings:
Namespace Name Mixin selector official <init>Lazl;<init>(Larj;Lbtv;)Vintermediary <init>Lnet/minecraft/class_1408;<init>(Lnet/minecraft/class_1308;Lnet/minecraft/class_1937;)Vnamed <init>Lnet/minecraft/entity/ai/pathing/EntityNavigation;<init>(Lnet/minecraft/entity/mob/MobEntity;Lnet/minecraft/world/World;)V
-
-
Method Details
-
resetRangeMultiplier
public void resetRangeMultiplier()- Mappings:
Namespace Name Mixin selector official gLazl;g()Vintermediary method_23965Lnet/minecraft/class_1408;method_23965()Vnamed resetRangeMultiplierLnet/minecraft/entity/ai/pathing/EntityNavigation;resetRangeMultiplier()V
-
setRangeMultiplier
public void setRangeMultiplier(float rangeMultiplier)- Mappings:
Namespace Name Mixin selector official aLazl;a(F)Vintermediary method_23964Lnet/minecraft/class_1408;method_23964(F)Vnamed setRangeMultiplierLnet/minecraft/entity/ai/pathing/EntityNavigation;setRangeMultiplier(F)V
-
getTargetPos
- Mappings:
Namespace Name Mixin selector official hLazl;h()Lfx;intermediary method_6355Lnet/minecraft/class_1408;method_6355()Lnet/minecraft/class_2338;named getTargetPosLnet/minecraft/entity/ai/pathing/EntityNavigation;getTargetPos()Lnet/minecraft/util/math/BlockPos;
-
setSpeed
public void setSpeed(double speed)- Mappings:
Namespace Name Mixin selector official aLazl;a(D)Vintermediary method_6344Lnet/minecraft/class_1408;method_6344(D)Vnamed setSpeedLnet/minecraft/entity/ai/pathing/EntityNavigation;setSpeed(D)V
-
shouldRecalculatePath
public boolean shouldRecalculatePath()- Mappings:
Namespace Name Mixin selector official iLazl;i()Zintermediary method_6343Lnet/minecraft/class_1408;method_6343()Znamed shouldRecalculatePathLnet/minecraft/entity/ai/pathing/EntityNavigation;shouldRecalculatePath()Z
-
recalculatePath
public void recalculatePath()- Mappings:
Namespace Name Mixin selector official jLazl;j()Vintermediary method_6356Lnet/minecraft/class_1408;method_6356()Vnamed recalculatePathLnet/minecraft/entity/ai/pathing/EntityNavigation;recalculatePath()V
-
findPathTo
- Mappings:
Namespace Name Mixin selector official aLazl;a(DDDI)Ldct;intermediary method_6352Lnet/minecraft/class_1408;method_6352(DDDI)Lnet/minecraft/class_11;named findPathToLnet/minecraft/entity/ai/pathing/EntityNavigation;findPathTo(DDDI)Lnet/minecraft/entity/ai/pathing/Path;
-
findPathToAny
- Mappings:
Namespace Name Mixin selector official aLazl;a(Ljava/util/stream/Stream;I)Ldct;intermediary method_21643Lnet/minecraft/class_1408;method_21643(Ljava/util/stream/Stream;I)Lnet/minecraft/class_11;named findPathToAnyLnet/minecraft/entity/ai/pathing/EntityNavigation;findPathToAny(Ljava/util/stream/Stream;I)Lnet/minecraft/entity/ai/pathing/Path;
-
method_29934
- Mappings:
Namespace Name Mixin selector official aLazl;a(Ljava/util/Set;I)Ldct;intermediary method_29934Lnet/minecraft/class_1408;method_29934(Ljava/util/Set;I)Lnet/minecraft/class_11;named method_29934Lnet/minecraft/entity/ai/pathing/EntityNavigation;method_29934(Ljava/util/Set;I)Lnet/minecraft/entity/ai/pathing/Path;
-
findPathTo
- Mappings:
Namespace Name Mixin selector official aLazl;a(Lfx;I)Ldct;intermediary method_6348Lnet/minecraft/class_1408;method_6348(Lnet/minecraft/class_2338;I)Lnet/minecraft/class_11;named findPathToLnet/minecraft/entity/ai/pathing/EntityNavigation;findPathTo(Lnet/minecraft/util/math/BlockPos;I)Lnet/minecraft/entity/ai/pathing/Path;
-
findPathTo
- Mappings:
Namespace Name Mixin selector official aLazl;a(Laqv;I)Ldct;intermediary method_6349Lnet/minecraft/class_1408;method_6349(Lnet/minecraft/class_1297;I)Lnet/minecraft/class_11;named findPathToLnet/minecraft/entity/ai/pathing/EntityNavigation;findPathTo(Lnet/minecraft/entity/Entity;I)Lnet/minecraft/entity/ai/pathing/Path;
-
findPathToAny
@Nullable protected Path findPathToAny(Set<BlockPos> positions, int range, boolean bool, int distance)- Mappings:
Namespace Name Mixin selector official aLazl;a(Ljava/util/Set;IZI)Ldct;intermediary method_18416Lnet/minecraft/class_1408;method_18416(Ljava/util/Set;IZI)Lnet/minecraft/class_11;named findPathToAnyLnet/minecraft/entity/ai/pathing/EntityNavigation;findPathToAny(Ljava/util/Set;IZI)Lnet/minecraft/entity/ai/pathing/Path;
-
startMovingTo
public boolean startMovingTo(double x, double y, double z, double speed)- Mappings:
Namespace Name Mixin selector official aLazl;a(DDDD)Zintermediary method_6337Lnet/minecraft/class_1408;method_6337(DDDD)Znamed startMovingToLnet/minecraft/entity/ai/pathing/EntityNavigation;startMovingTo(DDDD)Z
-
startMovingTo
- Mappings:
Namespace Name Mixin selector official aLazl;a(Laqv;D)Zintermediary method_6335Lnet/minecraft/class_1408;method_6335(Lnet/minecraft/class_1297;D)Znamed startMovingToLnet/minecraft/entity/ai/pathing/EntityNavigation;startMovingTo(Lnet/minecraft/entity/Entity;D)Z
-
startMovingAlong
- Mappings:
Namespace Name Mixin selector official aLazl;a(Ldct;D)Zintermediary method_6334Lnet/minecraft/class_1408;method_6334(Lnet/minecraft/class_11;D)Znamed startMovingAlongLnet/minecraft/entity/ai/pathing/EntityNavigation;startMovingAlong(Lnet/minecraft/entity/ai/pathing/Path;D)Z
-
getCurrentPath
- Mappings:
Namespace Name Mixin selector official kLazl;k()Ldct;intermediary method_6345Lnet/minecraft/class_1408;method_6345()Lnet/minecraft/class_11;named getCurrentPathLnet/minecraft/entity/ai/pathing/EntityNavigation;getCurrentPath()Lnet/minecraft/entity/ai/pathing/Path;
-
tick
public void tick()- Mappings:
Namespace Name Mixin selector official cLazl;c()Vintermediary method_6360Lnet/minecraft/class_1408;method_6360()Vnamed tickLnet/minecraft/entity/ai/pathing/EntityNavigation;tick()V
-
continueFollowingPath
protected void continueFollowingPath()- Mappings:
Namespace Name Mixin selector official lLazl;l()Vintermediary method_6339Lnet/minecraft/class_1408;method_6339()Vnamed continueFollowingPathLnet/minecraft/entity/ai/pathing/EntityNavigation;continueFollowingPath()V
-
method_27799
- Mappings:
Namespace Name Mixin selector official bLazl;b(Ldiu;)Zintermediary method_27799Lnet/minecraft/class_1408;method_27799(Lnet/minecraft/class_243;)Znamed method_27799Lnet/minecraft/entity/ai/pathing/EntityNavigation;method_27799(Lnet/minecraft/util/math/Vec3d;)Z
-
checkTimeouts
- Mappings:
Namespace Name Mixin selector official aLazl;a(Ldiu;)Vintermediary method_6346Lnet/minecraft/class_1408;method_6346(Lnet/minecraft/class_243;)Vnamed checkTimeoutsLnet/minecraft/entity/ai/pathing/EntityNavigation;checkTimeouts(Lnet/minecraft/util/math/Vec3d;)V
-
resetNodeAndStop
private void resetNodeAndStop()- Mappings:
Namespace Name Mixin selector official eLazl;e()Vintermediary method_31266Lnet/minecraft/class_1408;method_31266()Vnamed resetNodeAndStopLnet/minecraft/entity/ai/pathing/EntityNavigation;resetNodeAndStop()V
-
resetNode
private void resetNode()- Mappings:
Namespace Name Mixin selector official fLazl;f()Vintermediary method_26085Lnet/minecraft/class_1408;method_26085()Vnamed resetNodeLnet/minecraft/entity/ai/pathing/EntityNavigation;resetNode()V
-
isIdle
public boolean isIdle()- Mappings:
Namespace Name Mixin selector official mLazl;m()Zintermediary method_6357Lnet/minecraft/class_1408;method_6357()Znamed isIdleLnet/minecraft/entity/ai/pathing/EntityNavigation;isIdle()Z
-
isFollowingPath
public boolean isFollowingPath()- Mappings:
Namespace Name Mixin selector official nLazl;n()Zintermediary method_23966Lnet/minecraft/class_1408;method_23966()Znamed isFollowingPathLnet/minecraft/entity/ai/pathing/EntityNavigation;isFollowingPath()Z
-
stop
public void stop()- Mappings:
Namespace Name Mixin selector official oLazl;o()Vintermediary method_6340Lnet/minecraft/class_1408;method_6340()Vnamed stopLnet/minecraft/entity/ai/pathing/EntityNavigation;stop()V
-
getPos
The position to act as if the entity is at for pathfinding purposes- Mappings:
Namespace Name Mixin selector official bLazl;b()Ldiu;intermediary method_6347Lnet/minecraft/class_1408;method_6347()Lnet/minecraft/class_243;named getPosLnet/minecraft/entity/ai/pathing/EntityNavigation;getPos()Lnet/minecraft/util/math/Vec3d;
-
isAtValidPosition
protected abstract boolean isAtValidPosition()- Mappings:
Namespace Name Mixin selector official aLazl;a()Zintermediary method_6358Lnet/minecraft/class_1408;method_6358()Znamed isAtValidPositionLnet/minecraft/entity/ai/pathing/EntityNavigation;isAtValidPosition()Z
-
isInLiquid
protected boolean isInLiquid()- Mappings:
Namespace Name Mixin selector official pLazl;p()Zintermediary method_6351Lnet/minecraft/class_1408;method_6351()Znamed isInLiquidLnet/minecraft/entity/ai/pathing/EntityNavigation;isInLiquid()Z
-
adjustPath
protected void adjustPath()Adjusts the current path according to various special obstacles that may be in the way, for example sunlight- Mappings:
Namespace Name Mixin selector official F_Lazl;F_()Vintermediary method_6359Lnet/minecraft/class_1408;method_6359()Vnamed adjustPathLnet/minecraft/entity/ai/pathing/EntityNavigation;adjustPath()V
-
canPathDirectlyThrough
protected abstract boolean canPathDirectlyThrough(Vec3d origin, Vec3d target, int sizeX, int sizeY, int sizeZ)- Mappings:
Namespace Name Mixin selector official aLazl;a(Ldiu;Ldiu;III)Zintermediary method_6341Lnet/minecraft/class_1408;method_6341(Lnet/minecraft/class_243;Lnet/minecraft/class_243;III)Znamed canPathDirectlyThroughLnet/minecraft/entity/ai/pathing/EntityNavigation;canPathDirectlyThrough(Lnet/minecraft/util/math/Vec3d;Lnet/minecraft/util/math/Vec3d;III)Z
-
isValidPosition
- Mappings:
Namespace Name Mixin selector official aLazl;a(Lfx;)Zintermediary method_6333Lnet/minecraft/class_1408;method_6333(Lnet/minecraft/class_2338;)Znamed isValidPositionLnet/minecraft/entity/ai/pathing/EntityNavigation;isValidPosition(Lnet/minecraft/util/math/BlockPos;)Z
-
getNodeMaker
- Mappings:
Namespace Name Mixin selector official qLazl;q()Ldcs;intermediary method_6342Lnet/minecraft/class_1408;method_6342()Lnet/minecraft/class_8;named getNodeMakerLnet/minecraft/entity/ai/pathing/EntityNavigation;getNodeMaker()Lnet/minecraft/entity/ai/pathing/PathNodeMaker;
-
setCanSwim
public void setCanSwim(boolean canSwim)- Mappings:
Namespace Name Mixin selector official dLazl;d(Z)Vintermediary method_6354Lnet/minecraft/class_1408;method_6354(Z)Vnamed setCanSwimLnet/minecraft/entity/ai/pathing/EntityNavigation;setCanSwim(Z)V
-
canSwim
public boolean canSwim()- Mappings:
Namespace Name Mixin selector official rLazl;r()Zintermediary method_6350Lnet/minecraft/class_1408;method_6350()Znamed canSwimLnet/minecraft/entity/ai/pathing/EntityNavigation;canSwim()Z
-
onBlockChanged
- Mappings:
Namespace Name Mixin selector official bLazl;b(Lfx;)Vintermediary method_18053Lnet/minecraft/class_1408;method_18053(Lnet/minecraft/class_2338;)Vnamed onBlockChangedLnet/minecraft/entity/ai/pathing/EntityNavigation;onBlockChanged(Lnet/minecraft/util/math/BlockPos;)V
-
isNearPathStartPos
public boolean isNearPathStartPos()- Mappings:
Namespace Name Mixin selector official tLazl;t()Zintermediary method_31267Lnet/minecraft/class_1408;method_31267()Znamed isNearPathStartPosLnet/minecraft/entity/ai/pathing/EntityNavigation;isNearPathStartPos()Z
-