Uses of Class
net.minecraft.entity.LivingEntity
Package
Description
This and its subpackages make up the brain system used by some modern Minecraft entities,
such as villagers, piglins, and axolotls.
The basic AI system for Minecraft living entities.
-
Uses of LivingEntity in net.minecraft.block
Modifier and TypeMethodDescriptionvoid
AbstractRedstoneGateBlock.onPlaced
(World world, BlockPos pos, BlockState state, LivingEntity placer, ItemStack itemStack) Called when the player placed the block.void
BedBlock.onPlaced
(World world, BlockPos pos, BlockState state, @Nullable LivingEntity placer, ItemStack itemStack) Called when the player placed the block.void
Block.onPlaced
(World world, BlockPos pos, BlockState state, @Nullable LivingEntity placer, ItemStack itemStack) Called when the player placed the block.void
CommandBlock.onPlaced
(World world, BlockPos pos, BlockState state, LivingEntity placer, ItemStack itemStack) Called when the player placed the block.void
CrafterBlock.onPlaced
(World world, BlockPos pos, BlockState state, LivingEntity placer, ItemStack itemStack) Called when the player placed the block.void
DoorBlock.onPlaced
(World world, BlockPos pos, BlockState state, LivingEntity placer, ItemStack itemStack) Called when the player placed the block.void
JukeboxBlock.onPlaced
(World world, BlockPos pos, BlockState state, @Nullable LivingEntity placer, ItemStack itemStack) Called when the player placed the block.void
PaleMossCarpetBlock.onPlaced
(World world, BlockPos pos, BlockState state, @Nullable LivingEntity placer, ItemStack itemStack) Called when the player placed the block.void
PistonBlock.onPlaced
(World world, BlockPos pos, BlockState state, LivingEntity placer, ItemStack itemStack) Called when the player placed the block.void
PitcherCropBlock.onPlaced
(World world, BlockPos pos, BlockState state, LivingEntity placer, ItemStack itemStack) Called when the player placed the block.void
SmallDripleafBlock.onPlaced
(World world, BlockPos pos, BlockState state, LivingEntity placer, ItemStack itemStack) Called when the player placed the block.void
StructureBlock.onPlaced
(World world, BlockPos pos, BlockState state, @Nullable LivingEntity placer, ItemStack itemStack) Called when the player placed the block.void
TallPlantBlock.onPlaced
(World world, BlockPos pos, BlockState state, LivingEntity placer, ItemStack itemStack) Called when the player placed the block.void
TripwireHookBlock.onPlaced
(World world, BlockPos pos, BlockState state, LivingEntity placer, ItemStack itemStack) Called when the player placed the block.void
WallWitherSkullBlock.onPlaced
(World world, BlockPos pos, BlockState state, @Nullable LivingEntity placer, ItemStack itemStack) Called when the player placed the block.void
WitherSkullBlock.onPlaced
(World world, BlockPos pos, BlockState state, @Nullable LivingEntity placer, ItemStack itemStack) Called when the player placed the block.private static void
TntBlock.primeTnt
(World world, BlockPos pos, @Nullable LivingEntity igniter) private static void
LecternBlock.putBook
(@Nullable LivingEntity user, World world, BlockPos pos, BlockState state, ItemStack stack) static boolean
LecternBlock.putBookIfAbsent
(@Nullable LivingEntity user, World world, BlockPos pos, BlockState state, ItemStack stack) -
Uses of LivingEntity in net.minecraft.block.entity
Modifier and TypeMethodDescriptionprivate static @Nullable LivingEntity
ConduitBlockEntity.findTargetEntity
(World world, BlockPos pos, UUID uuid) Modifier and TypeMethodDescriptionboolean
CampfireBlockEntity.addItem
(ServerWorld world, @Nullable LivingEntity entity, ItemStack stack) private static void
BellBlockEntity.applyGlowToEntity
(LivingEntity entity) Gives theStatusEffects.GLOWING
status effect to the given entity for 3 seconds (60 ticks).private static boolean
BellBlockEntity.isRaiderEntity
(BlockPos pos, LivingEntity entity) Determines whether the given entity is in theEntityTypeTags.RAIDERS
entity type tag and within 48 blocks of the given position.void
StructureBlockBlockEntity.setAuthor
(LivingEntity entity) private void
SculkCatalystBlockEntity.Listener.triggerCriteria
(World world, LivingEntity deadEntity) Modifier and TypeMethodDescriptionprivate static void
BellBlockEntity.applyGlowToRaiders
(World world, BlockPos pos, List<LivingEntity> hearingEntities) private static void
BellBlockEntity.applyParticlesToRaiders
(World world, BlockPos pos, List<LivingEntity> hearingEntities) SpawnsParticleTypes.ENTITY_EFFECT
particles around raiders within 48 blocks.private static boolean
BellBlockEntity.raidersHearBell
(BlockPos pos, List<LivingEntity> hearingEntities) Determines whether at least one of the given entities would be affected by the bell.void
BellBlockEntity.Effect.run
(World world, BlockPos pos, List<LivingEntity> hearingEntities) -
Uses of LivingEntity in net.minecraft.client.gui
Modifier and TypeMethodDescriptionprivate void
DrawContext.drawItem
(@Nullable LivingEntity entity, @Nullable World world, ItemStack stack, int x, int y, int seed) private void
DrawContext.drawItem
(@Nullable LivingEntity entity, @Nullable World world, ItemStack stack, int x, int y, int seed, int z) void
DrawContext.drawItem
(LivingEntity entity, ItemStack stack, int x, int y, int seed) -
Uses of LivingEntity in net.minecraft.client.gui.hud
Modifier and TypeMethodDescriptionprivate int
InGameHud.getHeartCount
(@Nullable LivingEntity entity) -
Uses of LivingEntity in net.minecraft.client.gui.screen.ingame
Modifier and TypeMethodDescriptionstatic void
InventoryScreen.drawEntity
(DrawContext context, float x, float y, float size, Vector3f vector3f, Quaternionf quaternionf, @Nullable Quaternionf quaternionf2, LivingEntity entity) static void
InventoryScreen.drawEntity
(DrawContext context, int x1, int y1, int x2, int y2, int size, float float2, float mouseX, float mouseY, LivingEntity entity) -
Uses of LivingEntity in net.minecraft.client.item
Modifier and TypeMethodDescriptiondefault float
ClampedModelPredicateProvider.call
(ItemStack stack, @Nullable ClientWorld world, @Nullable LivingEntity entity, int seed) Deprecated.float
ModelPredicateProvider.call
(ItemStack stack, @Nullable ClientWorld world, @Nullable LivingEntity entity, int seed) Deprecated.float
ClampedModelPredicateProvider.unclampedCall
(ItemStack stack, @Nullable ClientWorld world, @Nullable LivingEntity entity, int seed) float
CompassAnglePredicateProvider.unclampedCall
(ItemStack stack, @Nullable ClientWorld world, @Nullable LivingEntity entity, int seed) -
Uses of LivingEntity in net.minecraft.client.network
Modifier and TypeClassDescriptionclass
class
Represents the client's own player entity.class
Represents a player entity that is present on the client but is not the client's own player. -
Uses of LivingEntity in net.minecraft.client.render
Modifier and TypeMethodDescriptionfloat
BackgroundRenderer.DarknessFogModifier.applyColorModifier
(LivingEntity entity, StatusEffectInstance effect, float defaultModifier, float tickDelta) default float
BackgroundRenderer.StatusEffectFogModifier.applyColorModifier
(LivingEntity entity, StatusEffectInstance effect, float defaultModifier, float tickDelta) void
BackgroundRenderer.BlindnessFogModifier.applyStartEndModifier
(BackgroundRenderer.FogData fogData, LivingEntity entity, StatusEffectInstance effect, float viewDistance, float tickDelta) void
BackgroundRenderer.DarknessFogModifier.applyStartEndModifier
(BackgroundRenderer.FogData fogData, LivingEntity entity, StatusEffectInstance effect, float viewDistance, float tickDelta) void
BackgroundRenderer.StatusEffectFogModifier.applyStartEndModifier
(BackgroundRenderer.FogData fogData, LivingEntity entity, StatusEffectInstance effect, float viewDistance, float tickDelta) private float
LightmapTextureManager.getDarkness
(LivingEntity entity, float factor, float delta) static float
GameRenderer.getNightVisionStrength
(LivingEntity entity, float tickDelta) default boolean
BackgroundRenderer.StatusEffectFogModifier.shouldApply
(LivingEntity entity, float tickDelta) -
Uses of LivingEntity in net.minecraft.client.render.entity
Modifier and TypeClassDescriptionclass
LivingEntityRenderer<T extends LivingEntity,
S extends LivingEntityRenderState, M extends EntityModel<? super S>> Modifier and TypeMethodDescriptionprivate static float
LivingEntityRenderer.clampBodyYaw
(LivingEntity entity, float degrees, float tickDelta) private Vec3d
GuardianEntityRenderer.fromLerpedPosition
(LivingEntity entity, double yOffset, float delta) private static Arm
BipedEntityRenderer.getPreferredArm
(LivingEntity entity) static boolean
LivingEntityRenderer.shouldFlipUpsideDown
(LivingEntity entity) static void
BipedEntityRenderer.updateBipedRenderState
(LivingEntity entity, BipedEntityRenderState state, float tickDelta) -
Uses of LivingEntity in net.minecraft.client.render.item
Modifier and TypeMethodDescriptionItemRenderer.getModel
(ItemStack stack, LivingEntity entity, ModelTransformationMode transformationMode) ItemRenderer.getModel
(ItemStack stack, @Nullable World world, @Nullable LivingEntity entity, int seed) private BakedModel
ItemRenderer.getModelOrOverride
(BakedModel model, ItemStack stack, @Nullable World world, @Nullable LivingEntity entity, int seed) void
ItemRenderer.renderBundle
(ItemStack stack, ModelTransformationMode transformationMode, boolean leftHanded, MatrixStack matrices, VertexConsumerProvider vertexConsumers, int light, int overlay, BakedModel model, @Nullable World world, @Nullable LivingEntity entity, int seed) void
HeldItemRenderer.renderItem
(LivingEntity entity, ItemStack stack, ModelTransformationMode renderMode, boolean leftHanded, MatrixStack matrices, VertexConsumerProvider vertexConsumers, int light) void
ItemRenderer.renderItem
(@Nullable LivingEntity entity, ItemStack item, ModelTransformationMode transformationMode, boolean leftHanded, MatrixStack matrices, VertexConsumerProvider vertexConsumers, @Nullable World world, int light, int overlay, int seed) -
Uses of LivingEntity in net.minecraft.client.render.model.json
Modifier and TypeMethodDescriptionModelOverrideList.getModel
(ItemStack stack, @Nullable ClientWorld world, @Nullable LivingEntity entity, int seed) -
Uses of LivingEntity in net.minecraft.component.type
Modifier and TypeMethodDescriptionvoid
PotionContentsComponent.apply
(LivingEntity user) void
DeathProtectionComponent.applyDeathEffects
(ItemStack stack, LivingEntity entity) boolean
ConsumableComponent.canConsume
(LivingEntity user, ItemStack stack) ConsumableComponent.consume
(LivingEntity user, ItemStack stack, Hand hand) ConsumableComponent.finishConsumption
(World world, LivingEntity user, ItemStack stack) void
Consumable.onConsume
(World world, LivingEntity user, ItemStack stack, ConsumableComponent consumable) void
FoodComponent.onConsume
(World world, LivingEntity user, ItemStack stack, ConsumableComponent consumable) void
OminousBottleAmplifierComponent.onConsume
(World world, LivingEntity user, ItemStack stack, ConsumableComponent consumable) void
PotionContentsComponent.onConsume
(World world, LivingEntity user, ItemStack stack, ConsumableComponent consumable) void
SuspiciousStewEffectsComponent.onConsume
(World world, LivingEntity user, ItemStack stack, ConsumableComponent consumable) void
UseCooldownComponent.set
(ItemStack stack, LivingEntity user) void
ConsumableComponent.spawnParticlesAndPlaySound
(Random random, LivingEntity user, ItemStack stack, int particleCount) -
Uses of LivingEntity in net.minecraft.enchantment
Modifier and TypeFieldDescriptionprivate final @Nullable LivingEntity
EnchantmentEffectContext.owner
The field for theowner
record component.Modifier and TypeMethodDescriptionEnchantmentEffectContext.owner()
Returns the value of theowner
record component.Modifier and TypeMethodDescriptionvoid
Enchantment.applyLocationBasedEffects
(ServerWorld world, int level, EnchantmentEffectContext context, LivingEntity user) static void
EnchantmentHelper.applyLocationBasedEffects
(ServerWorld world, LivingEntity user) static void
EnchantmentHelper.applyLocationBasedEffects
(ServerWorld world, ItemStack stack, LivingEntity user, EquipmentSlot slot) static Optional
<EnchantmentEffectContext> EnchantmentHelper.chooseEquipmentWith
(ComponentType<?> componentType, LivingEntity entity, Predicate<ItemStack> stackPredicate) Returns a pair of an equipment slot and the item stack in the supplied entity's slot.private static void
EnchantmentHelper.forEachEnchantment
(LivingEntity entity, EnchantmentHelper.ContextAwareConsumer contextAwareConsumer) private static void
EnchantmentHelper.forEachEnchantment
(ItemStack stack, EquipmentSlot slot, LivingEntity entity, EnchantmentHelper.ContextAwareConsumer contextAwareConsumer) static float
EnchantmentHelper.getCrossbowChargeTime
(ItemStack stack, LivingEntity user, float baseCrossbowChargeTime) Enchantment.getEquipment
(LivingEntity entity) static float
EnchantmentHelper.getEquipmentDropChance
(ServerWorld world, LivingEntity attacker, DamageSource damageSource, float baseEquipmentDropChance) static int
EnchantmentHelper.getEquipmentLevel
(RegistryEntry<Enchantment> enchantment, LivingEntity entity) Returns the highest level of the passed enchantment in the enchantment's applicable equipment slots' item stacks.static float
EnchantmentHelper.getProtectionAmount
(ServerWorld world, LivingEntity user, DamageSource damageSource) static float
EnchantmentHelper.getTridentSpinAttackStrength
(ItemStack stack, LivingEntity user) static boolean
EnchantmentHelper.isInvulnerableTo
(ServerWorld world, LivingEntity user, DamageSource damageSource) static void
EnchantmentHelper.onHitBlock
(ServerWorld world, ItemStack stack, @Nullable LivingEntity user, Entity enchantedEntity, @Nullable EquipmentSlot slot, Vec3d pos, BlockState state, Consumer<Item> onBreak) static void
EnchantmentHelper.onTick
(ServerWorld world, LivingEntity user) void
Enchantment.removeLocationBasedEffects
(int level, EnchantmentEffectContext context, LivingEntity user) static void
EnchantmentHelper.removeLocationBasedEffects
(LivingEntity user) static void
EnchantmentHelper.removeLocationBasedEffects
(ItemStack stack, LivingEntity user, EquipmentSlot slot) ModifierConstructorDescriptionEnchantmentEffectContext
(ItemStack itemStack, @Nullable EquipmentSlot equipmentSlot, @Nullable LivingEntity livingEntity, Consumer<Item> consumer) EnchantmentEffectContext
(ItemStack stack, EquipmentSlot slot, LivingEntity owner) -
Uses of LivingEntity in net.minecraft.entity
Modifier and TypeFieldDescriptionprivate @Nullable LivingEntity
LivingEntity.attacker
private @Nullable LivingEntity
LivingEntity.attacking
private @Nullable LivingEntity
TntEntity.causingEntity
private @Nullable LivingEntity
AreaEffectCloudEntity.owner
Modifier and TypeFieldDescriptionstatic final Predicate
<LivingEntity> LivingEntity.NOT_WEARING_GAZE_DISGUISE_PREDICATE
Modifier and TypeMethodDescriptionstatic <T extends LivingEntity & Bucketable>
Optional<ActionResult> Bucketable.tryBucket
(PlayerEntity player, Hand hand, T entity) Modifier and TypeMethodDescriptionLivingEntity.getAttacker()
LivingEntity.getAttacking()
Entity.getControllingPassenger()
Returns the passenger in control of this entity, ornull
if there is none.Attackable.getLastAttacker()
LivingEntity.getLastAttacker()
AreaEffectCloudEntity.getOwner()
default @Nullable LivingEntity
Tameable.getOwner()
TntEntity.getOwner()
LivingEntity.getPrimeAdversary()
CrossbowUser.getTarget()
Targeter.getTarget()
Modifier and TypeMethodDescriptionprotected void
LivingEntity.attackLivingEntity
(LivingEntity target) static boolean
Dismounting.canPlaceEntityAt
(CollisionView world, LivingEntity entity, Box targetBox) static boolean
Dismounting.canPlaceEntityAt
(CollisionView world, Vec3d offset, LivingEntity entity, EntityPose pose) boolean
LivingEntity.canTarget
(LivingEntity target) static float
DamageUtil.getDamageLeft
(LivingEntity armorWearer, float damageAmount, DamageSource damageSource, float armor, float armorToughness) private static StackReference
LivingEntity.getStackReference
(LivingEntity entity, EquipmentSlot slot) boolean
LivingEntity.isEntityLookingAtMe
(LivingEntity entity, double double2, boolean bool, boolean visualShape, Predicate<LivingEntity> predicate, DoubleSupplier[] entityYChecks) protected void
LivingEntity.knockback
(LivingEntity target) protected void
LivingEntity.onKilledBy
(@Nullable LivingEntity adversary) Performs secondary effects after this mob has been killed.boolean
Entity.onKilledOther
(ServerWorld world, LivingEntity other) Called when this entity killsother
.void
LivingEntity.setAttacker
(@Nullable LivingEntity attacker) void
AreaEffectCloudEntity.setOwner
(@Nullable LivingEntity owner) default void
CrossbowUser.shoot
(LivingEntity entity, float speed) protected void
LivingEntity.takeShieldHit
(LivingEntity attacker) Entity.updatePassengerForDismount
(LivingEntity passenger) Returns the position of the dismountedpassenger
.Modifier and TypeMethodDescriptionboolean
LivingEntity.isEntityLookingAtMe
(LivingEntity entity, double double2, boolean bool, boolean visualShape, Predicate<LivingEntity> predicate, DoubleSupplier[] entityYChecks) ModifierConstructorDescriptionTntEntity
(World world, double x, double y, double z, @Nullable LivingEntity igniter) ModifierConstructorDescriptionprotected
LivingEntity
(EntityType<? extends LivingEntity> type, World world) -
Uses of LivingEntity in net.minecraft.entity.ai
Modifier and TypeMethodDescriptionvoid
RangedAttackMob.shootAt
(LivingEntity target, float pullProgress) boolean
TargetPredicate.EntityPredicate.test
(LivingEntity target, ServerWorld world) boolean
TargetPredicate.test
(ServerWorld world, @Nullable LivingEntity tester, LivingEntity target) -
Uses of LivingEntity in net.minecraft.entity.ai.brain
Modifier and TypeClassDescriptionclass
Brain<E extends LivingEntity>
A brain is associated with each living entity.static final class
Brain.Profile<E extends LivingEntity>
A simple profile of a brain.Modifier and TypeFieldDescriptionstatic final MemoryModuleType
<LivingEntity> MemoryModuleType.ATTACK_TARGET
static final MemoryModuleType
<LivingEntity> MemoryModuleType.AVOID_TARGET
private final List
<LivingEntity> LivingTargetCache.entities
static final MemoryModuleType
<LivingEntity> MemoryModuleType.HURT_BY_ENTITY
static final MemoryModuleType
<LivingEntity> MemoryModuleType.INTERACTION_TARGET
static final MemoryModuleType
<List<LivingEntity>> MemoryModuleType.MOBS
static final MemoryModuleType
<LivingEntity> MemoryModuleType.NEAREST_ATTACKABLE
static final MemoryModuleType
<LivingEntity> MemoryModuleType.NEAREST_HOSTILE
static final MemoryModuleType
<LivingEntity> MemoryModuleType.NEAREST_VISIBLE_ZOMBIFIED
static final MemoryModuleType
<LivingEntity> MemoryModuleType.ROAR_TARGET
private final Predicate
<LivingEntity> LivingTargetCache.targetPredicate
static final MemoryModuleType
<List<LivingEntity>> MemoryModuleType.VISIBLE_VILLAGER_BABIES
Modifier and TypeMethodDescriptionstatic <E extends LivingEntity>
com.mojang.serialization.Codec<Brain<E>> Brain.createBrainCodec
(Collection<? extends MemoryModuleType<?>> memoryModules, Collection<? extends SensorType<? extends Sensor<? super E>>> sensors) static <E extends LivingEntity>
Brain.Profile<E> Brain.createProfile
(Collection<? extends MemoryModuleType<?>> memoryModules, Collection<? extends SensorType<? extends Sensor<? super E>>> sensors) Modifier and TypeMethodDescriptionLivingTargetCache.findFirst
(Predicate<LivingEntity> predicate) LivingTargetCache.iterate
(Predicate<LivingEntity> predicate) LivingTargetCache.stream
(Predicate<LivingEntity> predicate) Modifier and TypeMethodDescriptionboolean
LivingTargetCache.contains
(LivingEntity entity) boolean
BlockPosLookTarget.isSeenBy
(LivingEntity entity) boolean
EntityLookTarget.isSeenBy
(LivingEntity entity) boolean
LookTarget.isSeenBy
(LivingEntity entity) Modifier and TypeMethodDescriptionboolean
LivingTargetCache.anyMatch
(Predicate<LivingEntity> predicate) LivingTargetCache.findFirst
(Predicate<LivingEntity> predicate) LivingTargetCache.iterate
(Predicate<LivingEntity> predicate) LivingTargetCache.stream
(Predicate<LivingEntity> predicate) ModifierConstructorDescriptionLivingTargetCache
(ServerWorld world, LivingEntity owner, List<LivingEntity> entities) ModifierConstructorDescriptionLivingTargetCache
(ServerWorld world, LivingEntity owner, List<LivingEntity> entities) -
Uses of LivingEntity in net.minecraft.entity.ai.brain.sensor
Modifier and TypeClassDescriptionclass
ArmadilloScareDetectedSensor<T extends LivingEntity>
class
NearestLivingEntitiesSensor<T extends LivingEntity>
class
Sensor<E extends LivingEntity>
A sensor can update memories over time in a brain.Modifier and TypeFieldDescriptionstatic final SensorType
<NearestLivingEntitiesSensor<LivingEntity>> SensorType.NEAREST_LIVING_ENTITIES
private final BiPredicate
<T, LivingEntity> ArmadilloScareDetectedSensor.threateningEntityPredicate
Modifier and TypeMethodDescriptionprivate static Optional
<LivingEntity> WardenAttackablesSensor.findNearestTarget
(WardenEntity warden, Predicate<LivingEntity> targetPredicate) private Optional
<LivingEntity> NearestVisibleLivingEntitySensor.getNearestVisibleLivingEntity
(ServerWorld world, LivingEntity entity) protected MemoryModuleType
<LivingEntity> AxolotlAttackablesSensor.getOutputMemoryModule()
protected MemoryModuleType
<LivingEntity> FrogAttackablesSensor.getOutputMemoryModule()
protected abstract MemoryModuleType
<LivingEntity> NearestVisibleLivingEntitySensor.getOutputMemoryModule()
protected MemoryModuleType
<LivingEntity> VillagerHostilesSensor.getOutputMemoryModule()
private List
<LivingEntity> VillagerBabiesSensor.getVisibleVillagerBabies
(LivingEntity entities) static BiPredicate
<ServerWorld, LivingEntity> Sensor.hasTargetBeenAttackableRecently
(LivingEntity entity, int ticks) Modifier and TypeMethodDescriptionprivate boolean
AxolotlAttackablesSensor.canHunt
(LivingEntity axolotl, LivingEntity target) PiglinSpecificSensor.findPiglinRepellent
(ServerWorld world, LivingEntity entity) protected double
NearestPlayersSensor.getFollowRange
(LivingEntity entity) private Optional
<LivingEntity> NearestVisibleLivingEntitySensor.getNearestVisibleLivingEntity
(ServerWorld world, LivingEntity entity) protected Optional
<LivingTargetCache> NearestVisibleLivingEntitySensor.getVisibleLivingEntities
(LivingEntity entity) private LivingTargetCache
VillagerBabiesSensor.getVisibleMobs
(LivingEntity entity) private List
<LivingEntity> VillagerBabiesSensor.getVisibleVillagerBabies
(LivingEntity entities) static BiPredicate
<ServerWorld, LivingEntity> Sensor.hasTargetBeenAttackableRecently
(LivingEntity entity, int ticks) private boolean
AxolotlAttackablesSensor.isAlwaysHostileTo
(LivingEntity axolotl) private boolean
VillagerHostilesSensor.isCloseEnoughForDanger
(LivingEntity villager, LivingEntity target) private boolean
VillagerHostilesSensor.isHostile
(LivingEntity entity) private boolean
AxolotlAttackablesSensor.isInRange
(LivingEntity axolotl, LivingEntity target) private boolean
FrogAttackablesSensor.isTargetUnreachable
(LivingEntity entity, LivingEntity target) private boolean
VillagerBabiesSensor.isVillagerBaby
(LivingEntity entity) protected boolean
AxolotlAttackablesSensor.matches
(ServerWorld world, LivingEntity entity, LivingEntity target) protected boolean
FrogAttackablesSensor.matches
(ServerWorld world, LivingEntity entity, LivingEntity target) protected abstract boolean
NearestVisibleLivingEntitySensor.matches
(ServerWorld world, LivingEntity entity, LivingEntity target) protected boolean
VillagerHostilesSensor.matches
(ServerWorld world, LivingEntity entity, LivingEntity target) static void
GolemLastSeenSensor.rememberIronGolem
(LivingEntity entity) protected void
DummySensor.sense
(ServerWorld world, LivingEntity entity) protected void
GolemLastSeenSensor.sense
(ServerWorld world, LivingEntity entity) protected void
HurtBySensor.sense
(ServerWorld world, LivingEntity entity) protected void
IsInWaterSensor.sense
(ServerWorld world, LivingEntity entity) protected void
NearestPlayersSensor.sense
(ServerWorld world, LivingEntity entity) protected void
NearestVisibleLivingEntitySensor.sense
(ServerWorld world, LivingEntity entity) protected void
PiglinBruteSpecificSensor.sense
(ServerWorld world, LivingEntity entity) protected void
PiglinSpecificSensor.sense
(ServerWorld world, LivingEntity entity) protected void
VillagerBabiesSensor.sense
(ServerWorld world, LivingEntity entity) static void
GolemLastSeenSensor.senseIronGolem
(LivingEntity entity) static boolean
Sensor.testAttackableTargetPredicate
(ServerWorld world, LivingEntity entity, LivingEntity target) static boolean
Sensor.testAttackableTargetPredicateIgnoreVisibility
(ServerWorld world, LivingEntity entity, LivingEntity target) static boolean
Sensor.testTargetPredicate
(ServerWorld world, LivingEntity entity, LivingEntity target) Modifier and TypeMethodDescriptionprivate static Optional
<LivingEntity> WardenAttackablesSensor.findNearestTarget
(WardenEntity warden, Predicate<LivingEntity> targetPredicate) ModifierConstructorDescriptionArmadilloScareDetectedSensor
(int senseInterval, BiPredicate<T, LivingEntity> threateningEntityPredicate, Predicate<T> canRollUpPredicate, MemoryModuleType<Boolean> memoryModuleType, int expiry) -
Uses of LivingEntity in net.minecraft.entity.ai.brain.task
Modifier and TypeClassDescriptionclass
CompositeTask<E extends LivingEntity>
class
CrossbowAttackTask<E extends MobEntity & CrossbowUser,
T extends LivingEntity> class
GiveInventoryToLookTargetTask<E extends LivingEntity & InventoryOwner>
class
MultiTickTask<E extends LivingEntity>
class
RandomTask<E extends LivingEntity>
class
SingleTickTask<E extends LivingEntity>
interface
Task<E extends LivingEntity>
interface
TaskRunnable<E extends LivingEntity>
A functional interface that represents a task.class
TaskTriggerer<E extends LivingEntity,
M> A lambda-based alternative to subclassingTask
.static final class
TaskTriggerer.K1<E extends LivingEntity>
private static final class
TaskTriggerer.QueryMemory<E extends LivingEntity,
F extends com.mojang.datafixers.kinds.K1, Value> private static final class
TaskTriggerer.Supply<E extends LivingEntity,
A> static final class
TaskTriggerer.TaskContext<E extends LivingEntity>
private static final class
TaskTriggerer.TaskContext.Mu<E extends LivingEntity>
private static interface
TaskTriggerer.TaskFunction<E extends LivingEntity,
R> private static final class
TaskTriggerer.Trigger<E extends LivingEntity>
Modifier and TypeFieldDescriptionprivate final Function
<LivingEntity, Optional<LookTarget>> GiveInventoryToLookTargetTask.lookTargetFunction
private final Function
<LivingEntity, Float> TemptTask.speed
private final Function
<LivingEntity, Double> TemptTask.stopDistanceGetter
Modifier and TypeMethodDescriptionstatic <E extends LivingEntity,
M>
TaskTriggerer<E, M> TaskTriggerer.cast
(com.mojang.datafixers.kinds.App<TaskTriggerer.K1<E>, M> app) static <E extends LivingEntity,
T extends LivingEntity>
Task<E> FindEntityTask.create
(EntityType<? extends T> type, int maxDistance, Predicate<E> entityPredicate, Predicate<T> targetPredicate, MemoryModuleType<T> targetModule, float speed, int completionRange) static <E extends LivingEntity,
T extends LivingEntity>
Task<E> FindEntityTask.create
(EntityType<? extends T> type, int maxDistance, Predicate<E> entityPredicate, Predicate<T> targetPredicate, MemoryModuleType<T> targetModule, float speed, int completionRange) static <T extends LivingEntity>
Task<LivingEntity> FindEntityTask.create
(EntityType<? extends T> type, int maxDistance, MemoryModuleType<T> targetModule, float speed, int completionRange) static <E extends LivingEntity>
Task<E> ForgetTask.create
(Predicate<E> condition, MemoryModuleType<?> memory) static <E extends LivingEntity,
T>
Task<E> MemoryTransferTask.create
(Predicate<E> runPredicate, MemoryModuleType<? extends T> sourceType, MemoryModuleType<T> targetType, UniformIntProvider expiry) static <E extends LivingEntity>
Task<E> RidingTask.create
(int range, BiPredicate<E, Entity> alternativeRideCondition) static <E extends LivingEntity>
Task<E> WalkTowardsNearestVisibleWantedItemTask.create
(Predicate<E> startCondition, float speed, boolean requiresWalkTarget, int radius) (package private) static <E extends LivingEntity,
M>
TaskTriggerer.TaskFunction<E, M> TaskTriggerer.getFunction
(com.mojang.datafixers.kinds.App<TaskTriggerer.K1<E>, M> app) static <E extends LivingEntity>
TaskTriggerer.TaskContext<E> TaskTriggerer.newContext()
(package private) static <E extends LivingEntity,
M>
TaskTriggerer<E, M> TaskTriggerer.of
(TaskTriggerer.TaskFunction<E, M> function) static <E extends LivingEntity>
SingleTickTask<E> Tasks.pickRandomly
(List<com.mojang.datafixers.util.Pair<? extends TaskRunnable<? super E>, Integer>> weightedTasks) Returns a task that picks and runs a task fromweightedTasks
randomly.static <E extends LivingEntity>
SingleTickTask<E> TaskTriggerer.predicate
(BiPredicate<ServerWorld, E> predicate) static <E extends LivingEntity>
SingleTickTask<E> abstract <E extends LivingEntity>
voidCompositeTask.RunMode.run
(Stream<Task<? super E>> tasks, ServerWorld world, E entity, long time) static <E extends LivingEntity>
SingleTickTask<E> TaskTriggerer.runIf
(Predicate<E> predicate, SingleTickTask<? super E> task) static <E extends LivingEntity>
SingleTickTask<E> TaskTriggerer.runIf
(TaskRunnable<? super E> predicate, TaskRunnable<? super E> task) static <E extends LivingEntity>
SingleTickTask<E> TaskTriggerer.task
(Function<TaskTriggerer.TaskContext<E>, ? extends com.mojang.datafixers.kinds.App<TaskTriggerer.K1<E>, TaskRunnable<E>>> creator) static <E extends LivingEntity>
SingleTickTask<E> Tasks.weighted
(List<com.mojang.datafixers.util.Pair<? extends TaskRunnable<? super E>, Integer>> weightedTasks, CompositeTask.Order order, CompositeTask.RunMode runMode) Returns a task that runs task(s) fromweightedTasks
.Modifier and TypeMethodDescriptionprivate LivingEntity
HoldTradeOffersTask.findPotentialCustomer
(VillagerEntity villager) private static LivingEntity
CrossbowAttackTask.getAttackTarget
(LivingEntity entity) static LivingEntity
TargetUtil.getCloserEntity
(LivingEntity source, Optional<LivingEntity> first, LivingEntity second) static LivingEntity
TargetUtil.getCloserEntity
(LivingEntity source, LivingEntity first, LivingEntity second) PrepareRamTask.Ram.getEntity()
private static LivingEntity
PlayWithVillagerBabiesTask.getInteractionTarget
(LivingEntity baby) Modifier and TypeMethodDescriptionstatic Task
<LivingEntity> AdmireItemTask.create
(int duration) static Task
<LivingEntity> AdmireItemTimeLimitTask.create
(int cooldown, int timeLimit) static Task
<LivingEntity> DefeatTargetTask.create
(int celebrationDuration, BiPredicate<LivingEntity, LivingEntity> predicate) static Task
<LivingEntity> EndRaidTask.create()
static <T extends LivingEntity>
Task<LivingEntity> FindEntityTask.create
(EntityType<? extends T> type, int maxDistance, MemoryModuleType<T> targetModule, float speed, int completionRange) static Task
<LivingEntity> FindInteractionTargetTask.create
(EntityType<?> type, int maxDistance) static Task
<LivingEntity> ForgetAngryAtTargetTask.create()
static Task
<LivingEntity> ForgetBellRingTask.create
(int maxHiddenSeconds, int distance) static Task
<LivingEntity> ForgetCompletedPointOfInterestTask.create
(Predicate<RegistryEntry<PointOfInterestType>> poiTypePredicate, MemoryModuleType<GlobalPos> poiPosModule) static SingleTickTask
<LivingEntity> GoToLookTargetTask.create
(float speed, int completionRange) static SingleTickTask
<LivingEntity> GoToLookTargetTask.create
(Predicate<LivingEntity> predicate, Function<LivingEntity, Float> speed, int completionRange) static SingleTickTask
<LivingEntity> HideInHomeTask.create
(int maxDistance, float walkSpeed, int preferredDistance) static Task
<LivingEntity> HideWhenBellRingsTask.create()
static Task
<LivingEntity> HuntFinishTask.create()
static Task
<LivingEntity> static Task
<LivingEntity> LookAtDisturbanceTask.create()
static SingleTickTask
<LivingEntity> LookAtMobTask.create
(float maxDistance) static SingleTickTask
<LivingEntity> LookAtMobTask.create
(Predicate<LivingEntity> predicate, float maxDistance) static SingleTickTask
<LivingEntity> LookAtMobTask.create
(EntityType<?> type, float maxDistance) static Task
<LivingEntity> LookAtMobTask.create
(SpawnGroup spawnGroup, float maxDistance) static SingleTickTask
<LivingEntity> MeetVillagerTask.create()
static Task
<LivingEntity> OpenDoorsTask.create()
static Task
<LivingEntity> PacifyTask.create
(MemoryModuleType<?> requiredMemory, int duration) static Task
<LivingEntity> PlayDeadTimerTask.create()
static Task
<LivingEntity> RingBellTask.create()
static Task
<LivingEntity> ScheduleActivityTask.create()
static SingleTickTask
<LivingEntity> SeekSkyTask.create
(float speed) static Task
<LivingEntity> StartRaidTask.create()
static Task
<LivingEntity> StartRidingTask.create
(float speed) static Task
<LivingEntity> StartSniffingTask.create()
static Task
<LivingEntity> StopPanickingTask.create()
static Task
<LivingEntity> WakeUpTask.create()
static Task
<LivingEntity> WalkTowardsLookTargetTask.create
(Function<LivingEntity, Optional<LookTarget>> lookTargetFunction, Predicate<LivingEntity> predicate, int completionRange, int searchRange, float speed) static Task
<LivingEntity> WalkTowardsNearestVisibleWantedItemTask.create
(float speed, boolean requiresWalkTarget, int radius) static Task
<LivingEntity> WantNewItemTask.create
(int range) private static com.mojang.datafixers.util.Pair
<Integer, Task<LivingEntity>> VillagerTaskListProvider.createBusyFollowTask()
private static com.mojang.datafixers.util.Pair
<Integer, Task<LivingEntity>> VillagerTaskListProvider.createFreeFollowTask()
static Task
<LivingEntity> LookAtMobWithIntervalTask.follow
(float maxDistance, UniformIntProvider interval) Deprecated.private static Task
<LivingEntity> LookAtMobWithIntervalTask.follow
(float maxDistance, UniformIntProvider interval, Predicate<LivingEntity> predicate) Deprecated.static Task
<LivingEntity> LookAtMobWithIntervalTask.follow
(EntityType<?> type, float maxDistance, UniformIntProvider interval) Deprecated.Optional
<? extends LivingEntity> UpdateAttackTargetTask.TargetGetter.get
(ServerWorld world, E entity) private static Map
<LivingEntity, Integer> PlayWithVillagerBabiesTask.getBabyInteractionTargetCounts
(List<LivingEntity> babies) static Optional
<LivingEntity> TargetUtil.getEntity
(LivingEntity entity, MemoryModuleType<UUID> uuidMemoryModule) private static Optional
<LivingEntity> PlayWithVillagerBabiesTask.getLeastPopularBabyInteractionTarget
(List<LivingEntity> babies) Modifier and TypeMethodDescriptionvoid
ForgetAttackTargetTask.ForgetCallback.accept
(ServerWorld world, E entity, LivingEntity target) private static boolean
OpenDoorsTask.cannotReachDoor
(ServerWorld world, LivingEntity entity, GlobalPos doorPos) private static boolean
ForgetAttackTargetTask.cannotReachTarget
(LivingEntity target, Optional<Long> lastReachTime) private static boolean
RidingTask.canRideTarget
(LivingEntity entity, Entity vehicle, int range) static boolean
TargetUtil.canSee
(Brain<?> brain, LivingEntity target) static void
SonicBoomTask.cooldown
(LivingEntity warden, int cooldown) SeekSkyTask.findNearbySky
(ServerWorld world, LivingEntity entity) private void
PrepareRamTask.findRam
(PathAwareEntity entity, LivingEntity target) PrepareRamTask.findRamStart
(PathAwareEntity entity, LivingEntity target) protected void
SleepTask.finishRunning
(ServerWorld world, LivingEntity entity, long time) protected void
TickCooldownTask.finishRunning
(ServerWorld world, LivingEntity entity, long time) private static LivingEntity
CrossbowAttackTask.getAttackTarget
(LivingEntity entity) static LivingEntity
TargetUtil.getCloserEntity
(LivingEntity source, Optional<LivingEntity> first, LivingEntity second) static LivingEntity
TargetUtil.getCloserEntity
(LivingEntity source, LivingEntity first, LivingEntity second) static Optional
<LivingEntity> TargetUtil.getEntity
(LivingEntity entity, MemoryModuleType<UUID> uuidMemoryModule) private static LivingEntity
PlayWithVillagerBabiesTask.getInteractionTarget
(LivingEntity baby) BreezeJumpTask.getPosToJumpTo
(LivingEntity breeze, Vec3d pos) static Vec3d
BreezeMovementUtil.getRandomPosBehindTarget
(LivingEntity target, Random random) private static Vec3d
BreezeSlideTowardsTargetTask.getRandomPosInMediumRange
(BreezeEntity breeze, LivingEntity target) TickCooldownTask.getRemainingCooldownTicks
(LivingEntity entity) static void
TargetUtil.give
(LivingEntity entity, ItemStack stack, Vec3d targetLocation) static void
TargetUtil.give
(LivingEntity entity, ItemStack stack, Vec3d targetLocation, Vec3d velocityFactor, float yOffset) private void
GiveGiftsToHeroTask.giveGifts
(ServerWorld world, VillagerEntity villager, LivingEntity recipient) private static void
GatherItemsVillagerTask.giveHalfOfStack
(VillagerEntity villager, Set<Item> validItems, LivingEntity target) private static boolean
VillagerTaskListProvider.hasActiveRaid
(ServerWorld world, LivingEntity entity) static boolean
TargetUtil.hasBreedTarget
(LivingEntity entity) private static boolean
PlayWithVillagerBabiesTask.hasInteractionTarget
(LivingEntity baby) private static boolean
OpenDoorsTask.hasOtherMobReachedDoor
(LivingEntity entity, BlockPos pos, Optional<List<LivingEntity>> otherMobs) private static boolean
ForgetCompletedPointOfInterestTask.isBedOccupiedByOthers
(ServerWorld world, BlockPos pos, LivingEntity entity) static boolean
PanicTask.isHostileNearby
(LivingEntity entity) private static boolean
PlayWithVillagerBabiesTask.isInteractionTargetOf
(LivingEntity entity, LivingEntity baby) static boolean
TargetUtil.isNewTargetTooFar
(LivingEntity source, LivingEntity target, double extraDistance) Checks if an entity can be a new attack target for the source entity.static boolean
SeekSkyTask.isSkyVisible
(ServerWorld world, LivingEntity entity, BlockPos pos) private static boolean
BreezeJumpTask.isTargetOutOfRange
(BreezeEntity breeze, LivingEntity target) private boolean
FrogEatEntityTask.isTargetReachable
(FrogEntity entity, LivingEntity target) private static boolean
BreezeJumpTask.isTargetTooClose
(BreezeEntity breeze, LivingEntity target) static boolean
TargetUtil.isTargetWithinAttackRange
(MobEntity mob, LivingEntity target, int rangedWeaponReachReduction) private static boolean
BreezeShootTask.isTargetWithinRange
(BreezeEntity breeze, LivingEntity target) static boolean
TargetUtil.isVisibleInMemory
(LivingEntity source, LivingEntity target) protected void
TickCooldownTask.keepRunning
(ServerWorld world, LivingEntity entity, long time) static void
TargetUtil.lookAt
(LivingEntity entity, LivingEntity target) static void
TargetUtil.lookAtAndWalkTowardsEachOther
(LivingEntity first, LivingEntity second, float speed, int walkCompletionRange) private static void
TargetUtil.lookAtEachOther
(LivingEntity first, LivingEntity second) private void
FrogEatEntityTask.markTargetAsUnreachable
(FrogEntity entity, LivingEntity target) static void
OpenDoorsTask.pathToDoor
(ServerWorld world, LivingEntity entity, @Nullable PathNode lastNode, @Nullable PathNode currentNode, Set<GlobalPos> doors, Optional<List<LivingEntity>> otherMobs) static void
GiveInventoryToLookTargetTask.playThrowSound
(LivingEntity entity, ItemStack stack, Vec3d target) protected void
DismountVehicleTask.run
(ServerWorld world, LivingEntity entity, long time) protected void
SleepTask.run
(ServerWorld world, LivingEntity entity, long time) private void
CrossbowAttackTask.setLookTarget
(MobEntity entity, LivingEntity target) private static void
PlayWithVillagerBabiesTask.setPlayTarget
(MemoryQueryResult<?, LivingEntity> interactionTarget, MemoryQueryResult<?, LookTarget> lookTarget, MemoryQueryResult<?, WalkTarget> walkTarget, LivingEntity baby) private void
HoldTradeOffersTask.setupOffers
(LivingEntity customer, VillagerEntity villager) protected boolean
SleepTask.shouldKeepRunning
(ServerWorld world, LivingEntity entity, long time) protected boolean
TickCooldownTask.shouldKeepRunning
(ServerWorld world, LivingEntity entity, long time) protected boolean
DismountVehicleTask.shouldRun
(ServerWorld world, LivingEntity entity) protected boolean
SleepTask.shouldRun
(ServerWorld world, LivingEntity entity) final void
WaitTask.stop
(ServerWorld world, LivingEntity entity, long time) boolean
ForgetAttackTargetTask.AlternativeCondition.test
(ServerWorld world, LivingEntity target) final void
WaitTask.tick
(ServerWorld world, LivingEntity entity, long time) private void
CrossbowAttackTask.tickState
(E entity, LivingEntity target) final boolean
WaitTask.tryStarting
(ServerWorld world, LivingEntity entity, long time) static void
TargetUtil.walkTowards
(LivingEntity entity, LookTarget target, float speed, int completionRange) static void
TargetUtil.walkTowards
(LivingEntity entity, Entity target, float speed, int completionRange) static void
TargetUtil.walkTowards
(LivingEntity entity, BlockPos target, float speed, int completionRange) private static void
TargetUtil.walkTowardsEachOther
(LivingEntity first, LivingEntity second, float speed, int completionRange) static boolean
PanicTask.wasHurt
(LivingEntity entity) private static boolean
VillagerTaskListProvider.wonRaid
(ServerWorld world, LivingEntity entity) Modifier and TypeMethodDescriptionprivate static boolean
TargetUtil.canSee
(Brain<?> brain, MemoryModuleType<? extends LivingEntity> memoryType, Predicate<LivingEntity> filter) private static boolean
TargetUtil.canSee
(Brain<?> brain, MemoryModuleType<? extends LivingEntity> memoryType, Predicate<LivingEntity> filter) static boolean
TargetUtil.canSee
(Brain<?> brain, MemoryModuleType<? extends LivingEntity> memoryModuleType, EntityType<?> entityType) static Task
<LivingEntity> DefeatTargetTask.create
(int celebrationDuration, BiPredicate<LivingEntity, LivingEntity> predicate) static Task
<LivingEntity> DefeatTargetTask.create
(int celebrationDuration, BiPredicate<LivingEntity, LivingEntity> predicate) static <E extends WardenEntity>
Task<E> FindRoarTargetTask.create
(Function<E, Optional<? extends LivingEntity>> targetFinder) static SingleTickTask
<LivingEntity> GoToLookTargetTask.create
(Predicate<LivingEntity> predicate, Function<LivingEntity, Float> speed, int completionRange) static SingleTickTask
<LivingEntity> GoToLookTargetTask.create
(Predicate<LivingEntity> predicate, Function<LivingEntity, Float> speed, int completionRange) static SingleTickTask
<LivingEntity> LookAtMobTask.create
(Predicate<LivingEntity> predicate, float maxDistance) RangedApproachTask.create
(Function<LivingEntity, Float> speed) static SingleTickTask
<PassiveEntity> WalkTowardsClosestAdultTask.create
(UniformIntProvider executionRange, Function<LivingEntity, Float> speed) static Task
<LivingEntity> WalkTowardsLookTargetTask.create
(Function<LivingEntity, Optional<LookTarget>> lookTargetFunction, Predicate<LivingEntity> predicate, int completionRange, int searchRange, float speed) static Task
<LivingEntity> WalkTowardsLookTargetTask.create
(Function<LivingEntity, Optional<LookTarget>> lookTargetFunction, Predicate<LivingEntity> predicate, int completionRange, int searchRange, float speed) private static Task
<LivingEntity> LookAtMobWithIntervalTask.follow
(float maxDistance, UniformIntProvider interval, Predicate<LivingEntity> predicate) Deprecated.private static Map
<LivingEntity, Integer> PlayWithVillagerBabiesTask.getBabyInteractionTargetCounts
(List<LivingEntity> babies) static LivingEntity
TargetUtil.getCloserEntity
(LivingEntity source, Optional<LivingEntity> first, LivingEntity second) private static Optional
<LivingEntity> PlayWithVillagerBabiesTask.getLeastPopularBabyInteractionTarget
(List<LivingEntity> babies) private static boolean
OpenDoorsTask.hasOtherMobReachedDoor
(LivingEntity entity, BlockPos pos, Optional<List<LivingEntity>> otherMobs) static void
OpenDoorsTask.pathToDoor
(ServerWorld world, LivingEntity entity, @Nullable PathNode lastNode, @Nullable PathNode currentNode, Set<GlobalPos> doors, Optional<List<LivingEntity>> otherMobs) private static void
PlayWithVillagerBabiesTask.setPlayTarget
(MemoryQueryResult<?, LivingEntity> interactionTarget, MemoryQueryResult<?, LookTarget> lookTarget, MemoryQueryResult<?, WalkTarget> walkTarget, LivingEntity baby) ModifierConstructorDescriptionGiveInventoryToLookTargetTask
(Function<LivingEntity, Optional<LookTarget>> lookTargetFunction, float speed, int runTime) TemptTask
(Function<LivingEntity, Float> speed) TemptTask
(Function<LivingEntity, Float> speed, Function<LivingEntity, Double> stopDistanceGetter) -
Uses of LivingEntity in net.minecraft.entity.ai.goal
Modifier and TypeClassDescriptionclass
ActiveTargetGoal<T extends LivingEntity>
A target goal that finds a target by entity class when the goal starts.class
DisableableFollowTargetGoal<T extends LivingEntity>
An active target goal that can be disabled so that it cannot start.class
FleeEntityGoal<T extends LivingEntity>
class
RaidGoal<T extends LivingEntity>
class
UntamedActiveTargetGoal<T extends LivingEntity>
An active target goal that only starts for untamed tameable animals.Modifier and TypeFieldDescriptionprivate LivingEntity
TrackOwnerAttackerGoal.attacker
private LivingEntity
AttackWithOwnerGoal.attacking
private @Nullable LivingEntity
FollowOwnerGoal.owner
private LivingEntity
AttackGoal.target
private @Nullable LivingEntity
CreeperIgniteGoal.target
private LivingEntity
PounceAtTargetGoal.target
private @Nullable LivingEntity
ProjectileAttackGoal.target
private @Nullable LivingEntity
TrackIronGolemTargetGoal.target
protected @Nullable LivingEntity
TrackTargetGoal.target
private @Nullable LivingEntity
WanderNearTargetGoal.target
protected @Nullable LivingEntity
ActiveTargetGoal.targetEntity
protected T
FleeEntityGoal.targetEntity
Modifier and TypeFieldDescriptionprotected final Predicate
<LivingEntity> FleeEntityGoal.extraInclusionSelector
protected final Predicate
<LivingEntity> FleeEntityGoal.inclusionSelector
protected final Class
<? extends LivingEntity> LookAtEntityGoal.targetType
Modifier and TypeMethodDescriptionprotected void
MeleeAttackGoal.attack
(LivingEntity target) protected boolean
MeleeAttackGoal.canAttack
(LivingEntity target) private boolean
TrackTargetGoal.canNavigateToEntity
(LivingEntity entity) protected boolean
TrackTargetGoal.canTrack
(@Nullable LivingEntity target, TargetPredicate targetPredicate) private boolean
TemptGoal.isTemptedBy
(LivingEntity entity) protected void
RevengeGoal.setMobEntityTarget
(MobEntity mob, LivingEntity target) void
ActiveTargetGoal.setTargetEntity
(@Nullable LivingEntity targetEntity) ModifierConstructorDescriptionFleeEntityGoal
(PathAwareEntity fleeingEntity, Class<T> classToFleeFrom, float fleeDistance, double fleeSlowSpeed, double fleeFastSpeed, Predicate<LivingEntity> inclusionSelector) FleeEntityGoal
(PathAwareEntity mob, Class<T> fleeFromType, Predicate<LivingEntity> extraInclusionSelector, float distance, double slowSpeed, double fastSpeed, Predicate<LivingEntity> inclusionSelector) LookAtEntityGoal
(MobEntity mob, Class<? extends LivingEntity> targetType, float range) LookAtEntityGoal
(MobEntity mob, Class<? extends LivingEntity> targetType, float range, float chance) LookAtEntityGoal
(MobEntity mob, Class<? extends LivingEntity> targetType, float range, float chance, boolean lookForward) StopAndLookAtEntityGoal
(MobEntity mob, Class<? extends LivingEntity> targetType, float range) StopAndLookAtEntityGoal
(MobEntity mob, Class<? extends LivingEntity> targetType, float range, float chance) -
Uses of LivingEntity in net.minecraft.entity.attribute
Modifier and TypeFieldDescriptionprivate static final Map
<EntityType<? extends LivingEntity>, DefaultAttributeContainer> DefaultAttributeRegistry.DEFAULT_ATTRIBUTE_REGISTRY
Modifier and TypeMethodDescriptionstatic DefaultAttributeContainer
DefaultAttributeRegistry.get
(EntityType<? extends LivingEntity> type) -
Uses of LivingEntity in net.minecraft.entity.boss
Modifier and TypeMethodDescriptionvoid
WitherEntity.shootAt
(LivingEntity target, float pullProgress) private void
WitherEntity.shootSkullAt
(int headIndex, LivingEntity target) -
Uses of LivingEntity in net.minecraft.entity.boss.dragon
-
Uses of LivingEntity in net.minecraft.entity.boss.dragon.phase
Modifier and TypeMethodDescriptionvoid
StrafePlayerPhase.setTargetEntity
(LivingEntity targetEntity) -
Uses of LivingEntity in net.minecraft.entity.damage
Modifier and TypeMethodDescriptionstatic @Nullable FallLocation
FallLocation.fromEntity
(LivingEntity entity) DamageSource.getDeathMessage
(LivingEntity killed) DamageSources.mobAttack
(LivingEntity attacker) DamageSources.mobAttackNoAggro
(LivingEntity attacker) DamageSources.mobProjectile
(Entity source, @Nullable LivingEntity attacker) DamageSources.spit
(Entity source, @Nullable LivingEntity attacker) DamageSources.sting
(LivingEntity attacker) DamageSources.windCharge
(Entity source, @Nullable LivingEntity attacker) -
Uses of LivingEntity in net.minecraft.entity.decoration
Modifier and TypeMethodDescriptionInteractionEntity.getLastAttacker()
InteractionEntity.getTarget()
-
Uses of LivingEntity in net.minecraft.entity.effect
Modifier and TypeMethodDescriptionvoid
InstantHealthOrDamageStatusEffect.applyInstantEffect
(ServerWorld world, @Nullable Entity effectEntity, @Nullable Entity attacker, LivingEntity target, int amplifier, double proximity) void
StatusEffect.applyInstantEffect
(ServerWorld world, @Nullable Entity effectEntity, @Nullable Entity attacker, LivingEntity target, int amplifier, double proximity) boolean
AbsorptionStatusEffect.applyUpdateEffect
(ServerWorld world, LivingEntity entity, int amplifier) boolean
BadOmenStatusEffect.applyUpdateEffect
(ServerWorld world, LivingEntity entity, int amplifier) boolean
HungerStatusEffect.applyUpdateEffect
(ServerWorld world, LivingEntity entity, int amplifier) boolean
InstantHealthOrDamageStatusEffect.applyUpdateEffect
(ServerWorld world, LivingEntity entity, int amplifier) boolean
PoisonStatusEffect.applyUpdateEffect
(ServerWorld world, LivingEntity entity, int amplifier) boolean
RaidOmenStatusEffect.applyUpdateEffect
(ServerWorld world, LivingEntity entity, int amplifier) boolean
RegenerationStatusEffect.applyUpdateEffect
(ServerWorld world, LivingEntity entity, int amplifier) boolean
SaturationStatusEffect.applyUpdateEffect
(ServerWorld world, LivingEntity entity, int amplifier) boolean
StatusEffect.applyUpdateEffect
(ServerWorld world, LivingEntity entity, int amplifier) boolean
WitherStatusEffect.applyUpdateEffect
(ServerWorld world, LivingEntity entity, int amplifier) OozingStatusEffect.SlimeCounter.around
(LivingEntity entity) float
StatusEffectInstance.Fading.calculate
(LivingEntity entity, float tickDelta) float
StatusEffectInstance.getFadeFactor
(LivingEntity entity, float tickDelta) Returns the factor (multiplier) for effect fade-in and fade-out.static int
StatusEffectUtil.getHasteAmplifier
(LivingEntity entity) static boolean
StatusEffectUtil.hasHaste
(LivingEntity entity) static boolean
StatusEffectUtil.hasWaterBreathing
(LivingEntity entity) void
AbsorptionStatusEffect.onApplied
(LivingEntity entity, int amplifier) void
StatusEffect.onApplied
(LivingEntity entity, int amplifier) void
StatusEffectInstance.onApplied
(LivingEntity entity) void
InfestedStatusEffect.onEntityDamage
(ServerWorld world, LivingEntity entity, int amplifier, DamageSource source, float amount) void
StatusEffect.onEntityDamage
(ServerWorld world, LivingEntity entity, int amplifier, DamageSource source, float amount) void
StatusEffectInstance.onEntityDamage
(ServerWorld world, LivingEntity entity, DamageSource source, float amount) void
OozingStatusEffect.onEntityRemoval
(ServerWorld world, LivingEntity entity, int amplifier, Entity.RemovalReason reason) void
StatusEffect.onEntityRemoval
(ServerWorld world, LivingEntity entity, int amplifier, Entity.RemovalReason reason) void
StatusEffectInstance.onEntityRemoval
(ServerWorld world, LivingEntity entity, Entity.RemovalReason reason) void
WeavingStatusEffect.onEntityRemoval
(ServerWorld world, LivingEntity entity, int amplifier, Entity.RemovalReason reason) void
WindChargedStatusEffect.onEntityRemoval
(ServerWorld world, LivingEntity entity, int amplifier, Entity.RemovalReason reason) void
StatusEffect.playApplySound
(LivingEntity entity, int amplifier) void
StatusEffectInstance.playApplySound
(LivingEntity entity) private void
InfestedStatusEffect.spawnSilverfish
(ServerWorld world, LivingEntity entity, double x, double y, double z) boolean
StatusEffectInstance.update
(LivingEntity entity, Runnable overwriteCallback) -
Uses of LivingEntity in net.minecraft.entity.mob
Modifier and TypeClassDescriptionprivate static class
SpiderEntity.TargetGoal<T extends LivingEntity>
Modifier and TypeClassDescriptionclass
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
Modifier and TypeFieldDescriptionprivate @Nullable LivingEntity
GuardianEntity.cachedBeamTarget
private final LivingEntity
ElytraFlightController.entity
private @Nullable LivingEntity
EvokerFangsEntity.owner
private @Nullable LivingEntity
EndermanEntity.ChasePlayerGoal.target
private @Nullable LivingEntity
MobEntity.target
Modifier and TypeFieldDescriptionprivate static final Predicate
<LivingEntity> RavagerEntity.CAN_KNOCK_BACK_WITH_ROAR_ON_CLIENT
Modifier and TypeMethodDescriptionAngerable.getAttacker()
GuardianEntity.getBeamTarget()
MobEntity.getControllingPassenger()
Returns the passenger in control of this entity, ornull
if there is none.EvokerFangsEntity.getOwner()
AbstractPiglinEntity.getTarget()
Angerable.getTarget()
BreezeEntity.getTarget()
CreakingEntity.getTarget()
HoglinEntity.getTarget()
MobEntity.getTarget()
WardenEntity.getTarget()
ZoglinEntity.getTarget()
protected final @Nullable LivingEntity
MobEntity.getTargetInBrain()
Modifier and TypeMethodDescriptionprivate static Optional
<LivingEntity> PiglinBrain.getAngryAt
(AbstractPiglinEntity piglin) static Optional
<LivingEntity> PiglinBrain.getAvoiding
(PiglinEntity piglin) private Optional
<? extends LivingEntity> ZoglinEntity.getHoglinTarget
(ServerWorld world) BreezeEntity.getHurtBy()
private static Optional
<? extends LivingEntity> HoglinBrain.getNearestVisibleTargetablePlayer
(ServerWorld world, HoglinEntity hoglin) private static Optional
<? extends LivingEntity> PiglinBrain.getPreferredTarget
(ServerWorld world, PiglinEntity piglin) WardenEntity.getPrimeSuspect()
private static Optional
<? extends LivingEntity> PiglinBruteBrain.getTarget
(ServerWorld world, AbstractPiglinEntity piglin) private static ImmutableList
<com.mojang.datafixers.util.Pair<SingleTickTask<LivingEntity>, Integer>> PiglinBrain.makeFollowTasks()
private static RandomTask
<LivingEntity> PiglinBrain.makeRandomFollowTask()
private static Task
<LivingEntity> PiglinBrain.makeRememberRideableHoglinTask()
Modifier and TypeMethodDescriptionprotected static void
PiglinBrain.angerAtCloserTargets
(ServerWorld world, AbstractPiglinEntity piglin, LivingEntity target) private static void
PiglinBrain.angerAtIfCloser
(ServerWorld world, AbstractPiglinEntity piglin, LivingEntity target) private static void
HoglinBrain.askAdultsForHelp
(HoglinEntity hoglin, LivingEntity target) private static void
HoglinBrain.askAdultsToAvoid
(HoglinEntity hoglin, LivingEntity target) private static void
HoglinBrain.avoid
(HoglinEntity hoglin, LivingEntity target) private static void
HoglinBrain.avoidEnemy
(HoglinEntity hoglin, LivingEntity target) protected static void
PiglinBrain.becomeAngryWith
(ServerWorld world, AbstractPiglinEntity piglin, LivingEntity target) private static void
PiglinBrain.becomeAngryWithPlayer
(ServerWorld world, AbstractPiglinEntity piglin, LivingEntity target) boolean
DrownedEntity.canDrownedAttackTarget
(@Nullable LivingEntity target) boolean
Angerable.canTarget
(LivingEntity target) boolean
IllagerEntity.canTarget
(LivingEntity target) private static boolean
PiglinBrain.canWander
(LivingEntity piglin) private void
EvokerFangsEntity.damage
(LivingEntity target) protected void
SlimeEntity.damage
(LivingEntity target) private static void
PiglinBrain.groupRunAwayFrom
(PiglinEntity piglin, LivingEntity target) private static boolean
PiglinBrain.hasBeenHurt
(LivingEntity piglin) private static boolean
PiglinBrain.hasPlayerHoldingWantedItemNearby
(LivingEntity entity) static boolean
PiglinBrain.isGoldHoldingPlayer
(LivingEntity target) private static boolean
PiglinBrain.isHoldingCrossbow
(LivingEntity piglin) private static boolean
PiglinBrain.isHuntingTarget
(LivingEntity piglin, LivingEntity target) boolean
MobEntity.isInAttackRange
(LivingEntity entity) private static boolean
PiglinBrain.isPreferredAttackTarget
(ServerWorld world, PiglinEntity piglin, LivingEntity target) private static boolean
PiglinBruteBrain.isTarget
(ServerWorld world, AbstractPiglinEntity piglin, LivingEntity target) private static boolean
WardenBrain.isTargeting
(WardenEntity warden, LivingEntity entity) static boolean
PiglinBrain.isWearingPiglinSafeArmor
(LivingEntity entity) static void
Hoglin.knockback
(LivingEntity attacker, LivingEntity target) protected void
HoglinEntity.knockback
(LivingEntity target) protected void
RavagerEntity.knockback
(LivingEntity target) protected void
ZoglinEntity.knockback
(LivingEntity target) protected static void
HoglinBrain.onAttacked
(ServerWorld world, HoglinEntity hoglin, LivingEntity attacker) protected static void
PiglinBrain.onAttacked
(ServerWorld world, PiglinEntity piglin, LivingEntity attacker) protected static void
HoglinBrain.onAttacking
(HoglinEntity hoglin, LivingEntity target) boolean
ZombieEntity.onKilledOther
(ServerWorld world, LivingEntity other) Called when this entity killsother
.private static void
WardenBrain.removeDeadSuspect
(ServerWorld world, WardenEntity warden, LivingEntity target) static void
WardenBrain.resetDigCooldown
(LivingEntity warden) private static void
PiglinBrain.runAwayFrom
(PiglinEntity piglin, LivingEntity target) private static void
PiglinBrain.runAwayFromClosestTarget
(PiglinEntity piglin, LivingEntity target) private static void
PiglinBrain.setAdmiringItem
(LivingEntity entity) void
Angerable.setAttacker
(@Nullable LivingEntity attacker) private static void
HoglinBrain.setAttackTarget
(HoglinEntity hoglin, LivingEntity target) private void
ZoglinEntity.setAttackTarget
(LivingEntity entity) private static void
HoglinBrain.setAttackTargetIfCloser
(HoglinEntity hoglin, LivingEntity targetCandidate) void
EvokerFangsEntity.setOwner
(@Nullable LivingEntity owner) void
Angerable.setTarget
(@Nullable LivingEntity target) void
CreeperEntity.setTarget
(@Nullable LivingEntity target) void
EndermanEntity.setTarget
(@Nullable LivingEntity target) void
MobEntity.setTarget
(@Nullable LivingEntity target) protected static void
PiglinBruteBrain.setTarget
(PiglinBruteEntity piglinBrute, LivingEntity target) void
ZombifiedPiglinEntity.setTarget
(@Nullable LivingEntity target) void
AbstractSkeletonEntity.shootAt
(LivingEntity target, float pullProgress) void
DrownedEntity.shootAt
(LivingEntity target, float pullProgress) void
IllusionerEntity.shootAt
(LivingEntity target, float pullProgress) void
PiglinEntity.shootAt
(LivingEntity target, float pullProgress) void
PillagerEntity.shootAt
(LivingEntity target, float pullProgress) void
WitchEntity.shootAt
(LivingEntity target, float pullProgress) default boolean
Angerable.shouldAngerAt
(LivingEntity entity, ServerWorld world) private boolean
ZoglinEntity.shouldAttack
(ServerWorld world, LivingEntity target) private static void
HoglinBrain.targetEnemy
(ServerWorld world, HoglinEntity hoglin, LivingEntity target) boolean
GuardianEntity.GuardianTargetPredicate.test
(@Nullable LivingEntity target, ServerWorld world) (package private) boolean
PhantomEntity.testTargetPredicate
(ServerWorld world, LivingEntity target, TargetPredicate predicate) static boolean
Hoglin.tryAttack
(ServerWorld world, LivingEntity attacker, LivingEntity target) protected static void
PiglinBrain.tryRevenge
(ServerWorld world, AbstractPiglinEntity piglin, LivingEntity target) protected static void
PiglinBruteBrain.tryRevenge
(ServerWorld world, PiglinBruteEntity piglinBrute, LivingEntity target) void
WardenEntity.updateAttackTarget
(LivingEntity target) ModifierConstructorDescriptionElytraFlightController
(LivingEntity entity) EvokerFangsEntity
(World world, double x, double y, double z, float yaw, int warmup, LivingEntity owner) -
Uses of LivingEntity in net.minecraft.entity.passive
Modifier and TypeClassDescriptionprivate static class
CatEntity.CatFleeGoal<T extends LivingEntity>
private static class
OcelotEntity.FleeGoal<T extends LivingEntity>
private static class
PandaEntity.PandaFleeGoal<T extends LivingEntity>
private static class
RabbitEntity.FleeGoal<T extends LivingEntity>
private class
WolfEntity.AvoidLlamaGoal<T extends LivingEntity>
Modifier and TypeClassDescriptionclass
class
class
class
class
class
Represents an axolotl, the cutest predator.class
class
class
class
Meow.class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
Modifier and TypeFieldDescriptionprivate @Nullable LivingEntity
FoxEntity.DefendFriendGoal.friend
private @Nullable LivingEntity
FoxEntity.DefendFriendGoal.offender
private LivingEntity
TraderLlamaEntity.DefendTraderGoal.offender
Modifier and TypeMethodDescriptionAbstractHorseEntity.getControllingPassenger()
Returns the passenger in control of this entity, ornull
if there is none.PigEntity.getControllingPassenger()
Returns the passenger in control of this entity, ornull
if there is none.StriderEntity.getControllingPassenger()
Returns the passenger in control of this entity, ornull
if there is none.AxolotlEntity.getTarget()
FrogEntity.getTarget()
Modifier and TypeMethodDescriptionprivate static Optional
<? extends LivingEntity> AxolotlBrain.getAttackTarget
(ServerWorld world, AxolotlEntity axolotl) Modifier and TypeMethodDescriptionstatic void
AxolotlEntity.appreciatePlayer
(ServerWorld world, AxolotlEntity axolotl, LivingEntity target) protected void
FoxEntity.AttackGoal.attack
(LivingEntity target) protected void
PolarBearEntity.AttackGoal.attack
(LivingEntity target) boolean
TameableEntity.canAttackWithOwner
(LivingEntity target, LivingEntity owner) boolean
WolfEntity.canAttackWithOwner
(LivingEntity target, LivingEntity owner) private static boolean
AxolotlBrain.canGoToLookTarget
(LivingEntity entity) static boolean
FoxEntity.canJumpChase
(FoxEntity fox, LivingEntity chasedEntity) boolean
DolphinEntity.canTarget
(LivingEntity target) boolean
TameableEntity.canTarget
(LivingEntity target) private static float
AxolotlBrain.getAdultFollowingSpeed
(LivingEntity entity) Returns the axolotl's speed when a baby axolotl is following an adult.protected Vec2f
AbstractHorseEntity.getControlledRotation
(LivingEntity controllingPassenger) protected Vec2f
CamelEntity.getControlledRotation
(LivingEntity controllingPassenger) private static Optional
<LookTarget> AllayBrain.getLikedLookTarget
(LivingEntity allay) static Optional
<ServerPlayerEntity> AllayBrain.getLikedPlayer
(LivingEntity allay) private static Optional
<LookTarget> AllayBrain.getLookTarget
(LivingEntity allay) private static float
AxolotlBrain.getTargetApproachingSpeed
(LivingEntity entity) Returns the axolotl's speed when approaching the attack target.private static float
AxolotlBrain.getTemptedSpeed
(LivingEntity entity) Returns the axolotl's speed when the axolotl is being tempted.private static boolean
AllayBrain.hasNearestVisibleWantedItem
(LivingEntity entity) boolean
ArmadilloEntity.isEntityThreatening
(LivingEntity entity) boolean
TameableEntity.isOwner
(LivingEntity entity) static boolean
FrogEntity.isValidFrogFood
(LivingEntity entity) AbstractHorseEntity.locateSafeDismountingPos
(Vec3d offset, LivingEntity passenger) static void
AllayBrain.rememberNoteBlock
(LivingEntity allay, BlockPos pos) void
VillagerEntity.setAttacker
(@Nullable LivingEntity attacker) protected void
BeeEntity.BeeRevengeGoal.setMobEntityTarget
(MobEntity mob, LivingEntity target) protected void
PandaEntity.PandaRevengeGoal.setMobEntityTarget
(MobEntity mob, LivingEntity target) protected void
PolarBearEntity.PolarBearRevengeGoal.setMobEntityTarget
(MobEntity mob, LivingEntity target) void
FoxEntity.setTarget
(@Nullable LivingEntity target) void
PandaEntity.LookAtEntityGoal.setTarget
(LivingEntity target) void
LlamaEntity.shootAt
(LivingEntity target, float pullProgress) void
SnowGolemEntity.shootAt
(LivingEntity target, float pullProgress) private static boolean
AllayBrain.shouldGoTowardsNoteBlock
(LivingEntity allay, Brain<?> brain, GlobalPos pos) private void
LlamaEntity.spitAt
(LivingEntity target) boolean
FoxEntity.WorriableEntityFilter.test
(LivingEntity target, ServerWorld world) AbstractHorseEntity.updatePassengerForDismount
(LivingEntity passenger) Returns the position of the dismountedpassenger
.PigEntity.updatePassengerForDismount
(LivingEntity passenger) Returns the position of the dismountedpassenger
.StriderEntity.updatePassengerForDismount
(LivingEntity passenger) Returns the position of the dismountedpassenger
.Modifier and TypeMethodDescriptionstatic boolean
AxolotlEntity.canSpawn
(EntityType<? extends LivingEntity> type, ServerWorldAccess world, SpawnReason reason, BlockPos pos, Random random) static boolean
GlowSquidEntity.canSpawn
(EntityType<? extends LivingEntity> type, ServerWorldAccess world, SpawnReason reason, BlockPos pos, Random random) ModifierConstructorDescriptionDefendFriendGoal
(Class<LivingEntity> targetEntityClass, boolean checkVisibility, boolean checkCanNavigate, TargetPredicate.EntityPredicate targetPredicate) LookAtEntityGoal
(MobEntity fox, Class<? extends LivingEntity> targetType, float range) LookAtEntityGoal
(PandaEntity panda, Class<? extends LivingEntity> targetType, float range) -
Uses of LivingEntity in net.minecraft.entity.player
Modifier and TypeMethodDescriptionprotected void
PlayerEntity.attackLivingEntity
(LivingEntity target) boolean
PlayerEntity.onKilledOther
(ServerWorld world, LivingEntity other) Called when this entity killsother
.protected void
PlayerEntity.takeShieldHit
(LivingEntity attacker) -
Uses of LivingEntity in net.minecraft.entity.projectile
Modifier and TypeMethodDescriptionProjectileEntity.ProjectileCreator.create
(ServerWorld world, LivingEntity shooter, ItemStack stack) static PersistentProjectileEntity
ProjectileUtil.createArrowProjectile
(LivingEntity entity, ItemStack stack, float damageModifier, @Nullable ItemStack bow) static Hand
ProjectileUtil.getHandPossiblyHolding
(LivingEntity entity, Item item) FireworkRocketEntity.getKnockback
(LivingEntity target, DamageSource source) ProjectileEntity.getKnockback
(LivingEntity target, DamageSource source) protected void
PersistentProjectileEntity.knockback
(LivingEntity target, DamageSource source) protected void
ArrowEntity.onHit
(LivingEntity target) protected void
PersistentProjectileEntity.onHit
(LivingEntity target) protected void
SpectralArrowEntity.onHit
(LivingEntity target) static <T extends ProjectileEntity>
TProjectileEntity.spawnWithVelocity
(ProjectileEntity.ProjectileCreator<T> creator, ServerWorld world, ItemStack projectileStack, LivingEntity shooter, double velocityX, double velocityY, double velocityZ, float power, float divergence) static <T extends ProjectileEntity>
TProjectileEntity.spawnWithVelocity
(ProjectileEntity.ProjectileCreator<T> creator, ServerWorld world, ItemStack projectileStack, LivingEntity shooter, float roll, float power, float divergence) ModifierConstructorDescriptionAbstractFireballEntity
(EntityType<? extends AbstractFireballEntity> type, LivingEntity owner, Vec3d velocity, World world) ArrowEntity
(World world, LivingEntity owner, ItemStack stack, @Nullable ItemStack shotFrom) DragonFireballEntity
(World world, LivingEntity owner, Vec3d velocity) ExplosiveProjectileEntity
(EntityType<? extends ExplosiveProjectileEntity> type, LivingEntity owner, Vec3d velocity, World world) FireballEntity
(World world, LivingEntity owner, Vec3d velocity, int explosionPower) FireworkRocketEntity
(World world, ItemStack stack, LivingEntity shooter) protected
PersistentProjectileEntity
(EntityType<? extends PersistentProjectileEntity> type, LivingEntity owner, World world, ItemStack stack, @Nullable ItemStack shotFrom) ShulkerBulletEntity
(World world, LivingEntity owner, Entity target, Direction.Axis axis) SmallFireballEntity
(World world, LivingEntity owner, Vec3d velocity) SpectralArrowEntity
(World world, LivingEntity owner, ItemStack stack, @Nullable ItemStack shotFrom) TridentEntity
(World world, LivingEntity owner, ItemStack stack) WitherSkullEntity
(World world, LivingEntity owner, Vec3d velocity) -
Uses of LivingEntity in net.minecraft.entity.projectile.thrown
Modifier and TypeFieldDescriptionstatic final Predicate
<LivingEntity> PotionEntity.AFFECTED_BY_WATER
Modifier and TypeMethodDescriptionPotionEntity.getKnockback
(LivingEntity target, DamageSource source) ModifierConstructorDescriptionEggEntity
(World world, LivingEntity owner, ItemStack stack) EnderPearlEntity
(World world, LivingEntity owner, ItemStack stack) ExperienceBottleEntity
(World world, LivingEntity owner, ItemStack stack) PotionEntity
(World world, LivingEntity owner, ItemStack stack) SnowballEntity
(World world, LivingEntity owner, ItemStack stack) ThrownItemEntity
(EntityType<? extends ThrownItemEntity> type, LivingEntity owner, World world, ItemStack stack) -
Uses of LivingEntity in net.minecraft.entity.raid
-
Uses of LivingEntity in net.minecraft.entity.vehicle
Modifier and TypeMethodDescriptionAbstractBoatEntity.getControllingPassenger()
Returns the passenger in control of this entity, ornull
if there is none.Modifier and TypeMethodDescriptionAbstractBoatEntity.updatePassengerForDismount
(LivingEntity passenger) Returns the position of the dismountedpassenger
.AbstractMinecartEntity.updatePassengerForDismount
(LivingEntity passenger) Returns the position of the dismountedpassenger
. -
Uses of LivingEntity in net.minecraft.inventory
Modifier and TypeMethodDescriptionstatic StackReference
StackReference.of
(LivingEntity entity, EquipmentSlot slot) Creates a stack reference backed by an equipment slot of a living entity with no filter, allowing direct manipulation of the equipment slot.static StackReference
StackReference.of
(LivingEntity entity, EquipmentSlot slot, Predicate<ItemStack> filter) Creates a stack reference backed by an equipment slot of a living entity and guarded by a condition for setting stacks into the inventory. -
Uses of LivingEntity in net.minecraft.item
Modifier and TypeMethodDescriptionprivate static Predicate
<LivingEntity> MaceItem.getKnockbackPredicate
(Entity attacker, Entity attacked) Modifier and TypeMethodDescriptionprivate ItemStack
ItemStack.applyRemainderAndCooldown
(LivingEntity user, ItemStack stack) private static Vector3f
CrossbowItem.calcVelocity
(LivingEntity shooter, Vec3d direction, float yaw) ArrowItem.createArrow
(World world, ItemStack stack, LivingEntity shooter, @Nullable ItemStack shotFrom) SpectralArrowItem.createArrow
(World world, ItemStack stack, LivingEntity shooter, @Nullable ItemStack shotFrom) protected ProjectileEntity
CrossbowItem.createArrowEntity
(World world, LivingEntity shooter, ItemStack weaponStack, ItemStack projectileStack, boolean critical) protected ProjectileEntity
RangedWeaponItem.createArrowEntity
(World world, LivingEntity shooter, ItemStack weaponStack, ItemStack projectileStack, boolean critical) void
ItemStack.damage
(int amount, LivingEntity entity, EquipmentSlot slot) Damages this item stack.ItemStack.damage
(int amount, ItemConvertible itemAfterBreaking, LivingEntity entity, EquipmentSlot slot) void
ItemStack.decrementUnlessCreative
(int amount, @Nullable LivingEntity entity) Decrements the count of items in this item stack, unlessentity
is a creative mode player.Item.finishUsing
(ItemStack stack, World world, LivingEntity user) Called when an entity finishes using the item, such as eating food or drinking a potion.ItemStack.finishUsing
(World world, LivingEntity user) SpyglassItem.finishUsing
(ItemStack stack, World world, LivingEntity user) Called when an entity finishes using the item, such as eating food or drinking a potion.Item.getDamageSource
(LivingEntity user) MaceItem.getDamageSource
(LivingEntity user) static ItemStack
RangedWeaponItem.getHeldProjectile
(LivingEntity entity, Predicate<ItemStack> predicate) private static double
MaceItem.getKnockback
(Entity attacker, LivingEntity attacked, Vec3d distance) int
BowItem.getMaxUseTime
(ItemStack stack, LivingEntity user) Returns the maximum use (right-click) time of this item, in ticks.int
BrushItem.getMaxUseTime
(ItemStack stack, LivingEntity user) Returns the maximum use (right-click) time of this item, in ticks.int
BundleItem.getMaxUseTime
(ItemStack stack, LivingEntity user) Returns the maximum use (right-click) time of this item, in ticks.int
CrossbowItem.getMaxUseTime
(ItemStack stack, LivingEntity user) Returns the maximum use (right-click) time of this item, in ticks.int
EnderEyeItem.getMaxUseTime
(ItemStack stack, LivingEntity user) Returns the maximum use (right-click) time of this item, in ticks.int
GoatHornItem.getMaxUseTime
(ItemStack stack, LivingEntity user) Returns the maximum use (right-click) time of this item, in ticks.int
Item.getMaxUseTime
(ItemStack stack, LivingEntity user) Returns the maximum use (right-click) time of this item, in ticks.int
ItemStack.getMaxUseTime
(LivingEntity user) int
ShieldItem.getMaxUseTime
(ItemStack stack, LivingEntity user) Returns the maximum use (right-click) time of this item, in ticks.int
SpyglassItem.getMaxUseTime
(ItemStack stack, LivingEntity user) Returns the maximum use (right-click) time of this item, in ticks.int
TridentItem.getMaxUseTime
(ItemStack stack, LivingEntity user) Returns the maximum use (right-click) time of this item, in ticks.protected static ItemStack
RangedWeaponItem.getProjectile
(ItemStack stack, ItemStack projectileStack, LivingEntity shooter, boolean multishot) private static float
CrossbowItem.getPullProgress
(int useTicks, ItemStack stack, LivingEntity user) static int
CrossbowItem.getPullTime
(ItemStack stack, LivingEntity user) RangedWeaponItem.load
(ItemStack stack, ItemStack projectileStack, LivingEntity shooter) private static boolean
CrossbowItem.loadProjectiles
(LivingEntity shooter, ItemStack crossbow) boolean
BowItem.onStoppedUsing
(ItemStack stack, World world, LivingEntity user, int remainingUseTicks) Called on both the client and the server when an entity stops using an item before reaching the maximum use time.boolean
CrossbowItem.onStoppedUsing
(ItemStack stack, World world, LivingEntity user, int remainingUseTicks) Called on both the client and the server when an entity stops using an item before reaching the maximum use time.boolean
Item.onStoppedUsing
(ItemStack stack, World world, LivingEntity user, int remainingUseTicks) Called on both the client and the server when an entity stops using an item before reaching the maximum use time.void
ItemStack.onStoppedUsing
(World world, LivingEntity user, int remainingUseTicks) boolean
SpyglassItem.onStoppedUsing
(ItemStack stack, World world, LivingEntity user, int remainingUseTicks) Called on both the client and the server when an entity stops using an item before reaching the maximum use time.boolean
TridentItem.onStoppedUsing
(ItemStack stack, World world, LivingEntity user, int remainingUseTicks) Called on both the client and the server when an entity stops using an item before reaching the maximum use time.private void
SpyglassItem.playStopUsingSound
(LivingEntity user) void
Item.postDamageEntity
(ItemStack stack, LivingEntity target, LivingEntity attacker) void
ItemStack.postDamageEntity
(LivingEntity target, LivingEntity user) void
MaceItem.postDamageEntity
(ItemStack stack, LivingEntity target, LivingEntity attacker) void
MiningToolItem.postDamageEntity
(ItemStack stack, LivingEntity target, LivingEntity attacker) void
SwordItem.postDamageEntity
(ItemStack stack, LivingEntity target, LivingEntity attacker) void
TridentItem.postDamageEntity
(ItemStack stack, LivingEntity target, LivingEntity attacker) boolean
Item.postHit
(ItemStack stack, LivingEntity target, LivingEntity attacker) Called on the server when the item is used to hit an entity.boolean
ItemStack.postHit
(LivingEntity target, LivingEntity user) boolean
MaceItem.postHit
(ItemStack stack, LivingEntity target, LivingEntity attacker) Called on the server when the item is used to hit an entity.boolean
MiningToolItem.postHit
(ItemStack stack, LivingEntity target, LivingEntity attacker) Called on the server when the item is used to hit an entity.boolean
SwordItem.postHit
(ItemStack stack, LivingEntity target, LivingEntity attacker) Called on the server when the item is used to hit an entity.boolean
TridentItem.postHit
(ItemStack stack, LivingEntity target, LivingEntity attacker) Called on the server when the item is used to hit an entity.boolean
Item.postMine
(ItemStack stack, World world, BlockState state, BlockPos pos, LivingEntity miner) Called on the server when the item is used to break a block.boolean
ShearsItem.postMine
(ItemStack stack, World world, BlockState state, BlockPos pos, LivingEntity miner) Called on the server when the item is used to break a block.protected void
BowItem.shoot
(LivingEntity shooter, ProjectileEntity projectile, int index, float speed, float divergence, float yaw, @Nullable LivingEntity target) protected void
CrossbowItem.shoot
(LivingEntity shooter, ProjectileEntity projectile, int index, float speed, float divergence, float yaw, @Nullable LivingEntity target) protected abstract void
RangedWeaponItem.shoot
(LivingEntity shooter, ProjectileEntity projectile, int index, float speed, float divergence, float yaw, @Nullable LivingEntity target) void
CrossbowItem.shootAll
(World world, LivingEntity shooter, Hand hand, ItemStack stack, float speed, float divergence, @Nullable LivingEntity target) protected void
RangedWeaponItem.shootAll
(ServerWorld world, LivingEntity shooter, Hand hand, ItemStack stack, List<ItemStack> projectiles, float speed, float divergence, boolean critical, @Nullable LivingEntity target) static boolean
MaceItem.shouldDealAdditionalDamage
(LivingEntity attacker) ItemStack.splitUnlessCreative
(int amount, @Nullable LivingEntity entity) void
BrushItem.usageTick
(World world, LivingEntity user, ItemStack stack, int remainingUseTicks) Called on both the server and the client every tick while an entity uses the item.void
BundleItem.usageTick
(World world, LivingEntity user, ItemStack stack, int remainingUseTicks) Called on both the server and the client every tick while an entity uses the item.void
CrossbowItem.usageTick
(World world, LivingEntity user, ItemStack stack, int remainingUseTicks) Called on both the server and the client every tick while an entity uses the item.void
Item.usageTick
(World world, LivingEntity user, ItemStack stack, int remainingUseTicks) Called on both the server and the client every tick while an entity uses the item.void
ItemStack.usageTick
(World world, LivingEntity user, int remainingUseTicks) DyeItem.useOnEntity
(ItemStack stack, PlayerEntity user, LivingEntity entity, Hand hand) Called on both the client and the server when a player uses the item on an entity.Item.useOnEntity
(ItemStack stack, PlayerEntity user, LivingEntity entity, Hand hand) Called on both the client and the server when a player uses the item on an entity.ItemStack.useOnEntity
(PlayerEntity user, LivingEntity entity, Hand hand) NameTagItem.useOnEntity
(ItemStack stack, PlayerEntity user, LivingEntity entity, Hand hand) Called on both the client and the server when a player uses the item on an entity.SaddleItem.useOnEntity
(ItemStack stack, PlayerEntity user, LivingEntity entity, Hand hand) Called on both the client and the server when a player uses the item on an entity. -
Uses of LivingEntity in net.minecraft.item.consume
Modifier and TypeMethodDescriptionboolean
ApplyEffectsConsumeEffect.onConsume
(World world, ItemStack stack, LivingEntity user) boolean
ClearAllEffectsConsumeEffect.onConsume
(World world, ItemStack stack, LivingEntity user) boolean
ConsumeEffect.onConsume
(World world, ItemStack stack, LivingEntity user) boolean
PlaySoundConsumeEffect.onConsume
(World world, ItemStack stack, LivingEntity user) boolean
RemoveEffectsConsumeEffect.onConsume
(World world, ItemStack stack, LivingEntity user) boolean
TeleportRandomlyConsumeEffect.onConsume
(World world, ItemStack stack, LivingEntity user) -
Uses of LivingEntity in net.minecraft.network.packet.s2c.play
-
Uses of LivingEntity in net.minecraft.predicate.entity
-
Uses of LivingEntity in net.minecraft.screen.slot
ModifierConstructorDescriptionArmorSlot
(Inventory inventory, LivingEntity entity, EquipmentSlot equipmentSlot, int index, int x, int y, @Nullable Identifier backgroundSprite) -
Uses of LivingEntity in net.minecraft.server
Modifier and TypeMethodDescriptionvoid
PlayerManager.sendStatusEffects
(LivingEntity entity, ServerPlayNetworkHandler networkHandler) -
Uses of LivingEntity in net.minecraft.server.command
Modifier and TypeMethodDescriptionprivate static LivingEntity
AttributeCommand.getLivingEntity
(Entity entity) private static LivingEntity
AttributeCommand.getLivingEntityWithAttribute
(Entity entity, RegistryEntry<EntityAttribute> attribute) -
Uses of LivingEntity in net.minecraft.server.network
Modifier and TypeMethodDescriptionDebugInfoSender.listMemories
(LivingEntity entity, long currentTime) static void
DebugInfoSender.sendBrainDebugData
(LivingEntity living) -
Uses of LivingEntity in net.minecraft.test
Modifier and TypeMethodDescription<E extends LivingEntity>
voidTestContext.expectEntityHoldingItem
(BlockPos pos, EntityType<E> entityType, Item item) Modifier and TypeMethodDescriptionTestContext.drown
(LivingEntity entity) TestContext.setHealthLow
(LivingEntity entity) Modifier and TypeMethodDescriptionTestContext.drown
(LivingEntity entity) void
TestContext.expectEntityHasEffect
(LivingEntity entity, RegistryEntry<StatusEffect> effect, int amplifier) TestContext.setHealthLow
(LivingEntity entity) -
Uses of LivingEntity in net.minecraft.world
Modifier and TypeMethodDescriptiondefault <T extends LivingEntity>
TEntityLookupView.getClosestEntity
(Class<? extends T> clazz, TargetPredicate targetPredicate, @Nullable LivingEntity entity, double x, double y, double z, Box box) default <T extends LivingEntity>
TEntityLookupView.getClosestEntity
(List<? extends T> entities, TargetPredicate targetPredicate, @Nullable LivingEntity entity, double x, double y, double z) default <T extends LivingEntity>
List<T> EntityLookupView.getTargets
(Class<T> clazz, TargetPredicate targetPredicate, LivingEntity entity, Box box) Modifier and TypeMethodDescriptiondefault <T extends LivingEntity>
TEntityLookupView.getClosestEntity
(Class<? extends T> clazz, TargetPredicate targetPredicate, @Nullable LivingEntity entity, double x, double y, double z, Box box) default <T extends LivingEntity>
TEntityLookupView.getClosestEntity
(List<? extends T> entities, TargetPredicate targetPredicate, @Nullable LivingEntity entity, double x, double y, double z) default @Nullable PlayerEntity
EntityLookupView.getClosestPlayer
(TargetPredicate targetPredicate, LivingEntity entity) default @Nullable PlayerEntity
EntityLookupView.getClosestPlayer
(TargetPredicate targetPredicate, LivingEntity entity, double x, double y, double z) default List
<PlayerEntity> EntityLookupView.getPlayers
(TargetPredicate targetPredicate, LivingEntity entity, Box box) default <T extends LivingEntity>
List<T> EntityLookupView.getTargets
(Class<T> clazz, TargetPredicate targetPredicate, LivingEntity entity, Box box) -
Uses of LivingEntity in net.minecraft.world.explosion
Modifier and TypeMethodDescriptionExplosion.getCausingEntity()
static @Nullable LivingEntity
Explosion.getCausingEntity
(@Nullable Entity entity) ExplosionImpl.getCausingEntity()