Class GoToTargetLocation<E extends Mob>

java.lang.Object
net.minecraft.world.entity.ai.behavior.Behavior<E>
net.minecraft.world.entity.ai.behavior.GoToTargetLocation<E>

public class GoToTargetLocation<E extends Mob> extends Behavior<E>
  • Field Details

    • locationMemory

      private final MemoryModuleType<BlockPos> locationMemory
    • closeEnoughDist

      private final int closeEnoughDist
    • speedModifier

      private final float speedModifier
  • Constructor Details

    • GoToTargetLocation

      public GoToTargetLocation(MemoryModuleType<BlockPos> p_217235_, int p_217236_, float p_217237_)
  • Method Details

    • start

      protected void start(ServerLevel p_217243_, Mob p_217244_, long p_217245_)
      Overrides:
      start in class Behavior<E extends Mob>
    • getNearbyPos

      private static BlockPos getNearbyPos(Mob p_217251_, BlockPos p_217252_)
    • getRandomOffset

      private static int getRandomOffset(RandomSource p_217247_)
    • getTargetLocation

      private BlockPos getTargetLocation(Mob p_217249_)