Uses of Class
net.minecraft.entity.Entity
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.
Contains utility method classes, various enums, serialization helpers, and
miscellaneous classes.
-
Uses of Entity in net.minecraft.advancement.criterion
Modifier and TypeMethodDescriptionvoid
EffectsChangedCriterion.trigger
(ServerPlayerEntity player, @Nullable Entity source) void
FallAfterExplosionCriterion.trigger
(ServerPlayerEntity player, Vec3d startPosition, @Nullable Entity cause) void
OnKilledCriterion.trigger
(ServerPlayerEntity player, Entity entity, DamageSource killingDamage) void
PlayerHurtEntityCriterion.trigger
(ServerPlayerEntity player, Entity entity, DamageSource damage, float dealt, float taken, boolean blocked) void
PlayerInteractedWithEntityCriterion.trigger
(ServerPlayerEntity player, ItemStack stack, Entity entity) void
SummonedEntityCriterion.trigger
(ServerPlayerEntity player, Entity entity) void
TargetHitCriterion.trigger
(ServerPlayerEntity player, Entity projectile, Vec3d hitPos, int signalStrength) void
ThrownItemPickedUpByEntityCriterion.trigger
(ServerPlayerEntity player, ItemStack stack, @Nullable Entity entity) Modifier and TypeMethodDescriptionvoid
ChanneledLightningCriterion.trigger
(ServerPlayerEntity player, Collection<? extends Entity> victims) void
KilledByArrowCriterion.trigger
(ServerPlayerEntity player, Collection<Entity> piercingKilledEntities, @Nullable ItemStack weapon) void
LightningStrikeCriterion.trigger
(ServerPlayerEntity player, LightningEntity lightning, List<Entity> bystanders) -
Uses of Entity in net.minecraft.block
Modifier and TypeMethodDescriptionprivate void
HoneyBlock.addCollisionEffects
(World world, Entity entity) private static void
HoneyBlock.addParticles
(Entity entity, int count) static void
HoneyBlock.addRegularParticles
(Entity entity) static void
HoneyBlock.addRichParticles
(Entity entity) (package private) static BlockState
ComposterBlock.addToComposter
(@Nullable Entity user, BlockState state, WorldAccess world, BlockPos pos, ItemStack stack) private void
private void
BedBlock.bounceEntity
(Entity entity) private boolean
TurtleEggBlock.breaksEgg
(ServerWorld world, Entity entity) static boolean
PowderSnowBlock.canWalkOnPowderSnow
(Entity entity) static void
static BlockState
ComposterBlock.compost
(Entity user, BlockState state, ServerWorld world, ItemStack stack, BlockPos pos) EndGatewayBlock.createTeleportTarget
(ServerWorld world, Entity entity, BlockPos pos) EndPortalBlock.createTeleportTarget
(ServerWorld world, Entity entity, BlockPos pos) NetherPortalBlock.createTeleportTarget
(ServerWorld world, Entity entity, BlockPos pos) Portal.createTeleportTarget
(ServerWorld world, Entity entity, BlockPos pos) static void
Block.dropStacks
(BlockState state, World world, BlockPos pos, @Nullable BlockEntity blockEntity, @Nullable Entity entity, ItemStack tool) (package private) static BlockState
ComposterBlock.emptyComposter
(@Nullable Entity user, BlockState state, WorldAccess world, BlockPos pos) static BlockState
ComposterBlock.emptyFullComposter
(Entity user, BlockState state, World world, BlockPos pos) static void
CampfireBlock.extinguish
(@Nullable Entity entity, WorldAccess world, BlockPos pos, BlockState state) AnvilBlock.getDamageSource
(Entity attacker) default DamageSource
LandingBlock.getDamageSource
(Entity attacker) PointedDripstoneBlock.getDamageSource
(Entity attacker) Block.getDroppedStacks
(BlockState state, ServerWorld world, BlockPos pos, @Nullable BlockEntity blockEntity, @Nullable Entity entity, ItemStack stack) private static TeleportTarget
NetherPortalBlock.getExitPortalTarget
(Entity entity, BlockPos pos, BlockLocating.Rectangle exitPortalRectangle, ServerWorld world, TeleportTarget.PostDimensionTransition postDimensionTransition) private static TeleportTarget
NetherPortalBlock.getExitPortalTarget
(ServerWorld world, BlockLocating.Rectangle exitPortalRectangle, Direction.Axis axis, Vec3d positionInPortal, Entity entity, TeleportTarget.PostDimensionTransition postDimensionTransition) private @Nullable TeleportTarget
NetherPortalBlock.getOrCreateExitPortalTarget
(ServerWorld world, Entity entity, BlockPos pos, BlockPos scaledPos, boolean inNether, WorldBorder worldBorder) int
NetherPortalBlock.getPortalDelay
(ServerWorld world, Entity entity) default int
Portal.getPortalDelay
(ServerWorld world, Entity entity) private static boolean
HoneyBlock.hasHoneyBlockEffects
(Entity entity) final boolean
AbstractBlock.AbstractBlockState.hasSolidTopSurface
(BlockView world, BlockPos pos, Entity entity) private static boolean
BigDripleafBlock.isEntityAbove
(BlockPos pos, Entity entity) protected boolean
AbstractCauldronBlock.isEntityTouchingFluid
(BlockState state, BlockPos pos, Entity entity) private boolean
final boolean
AbstractBlock.AbstractBlockState.isSolidSurface
(BlockView world, BlockPos pos, Entity entity, Direction direction) static ShapeContext
static ShapeContext
void
AbstractBlock.AbstractBlockState.onEntityCollision
(World world, BlockPos pos, Entity entity) protected void
AbstractBlock.onEntityCollision
(BlockState state, World world, BlockPos pos, Entity entity) Called when the entity's collision box intersects the block.protected void
AbstractFireBlock.onEntityCollision
(BlockState state, World world, BlockPos pos, Entity entity) Called when the entity's collision box intersects the block.protected void
AbstractPressurePlateBlock.onEntityCollision
(BlockState state, World world, BlockPos pos, Entity entity) Called when the entity's collision box intersects the block.protected void
BigDripleafBlock.onEntityCollision
(BlockState state, World world, BlockPos pos, Entity entity) Called when the entity's collision box intersects the block.protected void
BubbleColumnBlock.onEntityCollision
(BlockState state, World world, BlockPos pos, Entity entity) Called when the entity's collision box intersects the block.protected void
ButtonBlock.onEntityCollision
(BlockState state, World world, BlockPos pos, Entity entity) Called when the entity's collision box intersects the block.protected void
CactusBlock.onEntityCollision
(BlockState state, World world, BlockPos pos, Entity entity) Called when the entity's collision box intersects the block.protected void
CampfireBlock.onEntityCollision
(BlockState state, World world, BlockPos pos, Entity entity) Called when the entity's collision box intersects the block.protected void
CobwebBlock.onEntityCollision
(BlockState state, World world, BlockPos pos, Entity entity) Called when the entity's collision box intersects the block.protected void
CropBlock.onEntityCollision
(BlockState state, World world, BlockPos pos, Entity entity) Called when the entity's collision box intersects the block.protected void
DetectorRailBlock.onEntityCollision
(BlockState state, World world, BlockPos pos, Entity entity) Called when the entity's collision box intersects the block.protected void
EndGatewayBlock.onEntityCollision
(BlockState state, World world, BlockPos pos, Entity entity) Called when the entity's collision box intersects the block.protected void
EndPortalBlock.onEntityCollision
(BlockState state, World world, BlockPos pos, Entity entity) Called when the entity's collision box intersects the block.protected void
FrogspawnBlock.onEntityCollision
(BlockState state, World world, BlockPos pos, Entity entity) Called when the entity's collision box intersects the block.protected void
HoneyBlock.onEntityCollision
(BlockState state, World world, BlockPos pos, Entity entity) Called when the entity's collision box intersects the block.protected void
HopperBlock.onEntityCollision
(BlockState state, World world, BlockPos pos, Entity entity) Called when the entity's collision box intersects the block.protected void
LavaCauldronBlock.onEntityCollision
(BlockState state, World world, BlockPos pos, Entity entity) Called when the entity's collision box intersects the block.protected void
LeveledCauldronBlock.onEntityCollision
(BlockState state, World world, BlockPos pos, Entity entity) Called when the entity's collision box intersects the block.protected void
LilyPadBlock.onEntityCollision
(BlockState state, World world, BlockPos pos, Entity entity) Called when the entity's collision box intersects the block.protected void
NetherPortalBlock.onEntityCollision
(BlockState state, World world, BlockPos pos, Entity entity) Called when the entity's collision box intersects the block.void
PitcherCropBlock.onEntityCollision
(BlockState state, World world, BlockPos pos, Entity entity) Called when the entity's collision box intersects the block.protected void
PowderSnowBlock.onEntityCollision
(BlockState state, World world, BlockPos pos, Entity entity) Called when the entity's collision box intersects the block.protected void
SweetBerryBushBlock.onEntityCollision
(BlockState state, World world, BlockPos pos, Entity entity) Called when the entity's collision box intersects the block.protected void
TripwireBlock.onEntityCollision
(BlockState state, World world, BlockPos pos, Entity entity) Called when the entity's collision box intersects the block.protected void
WitherRoseBlock.onEntityCollision
(BlockState state, World world, BlockPos pos, Entity entity) Called when the entity's collision box intersects the block.void
BedBlock.onEntityLand
(BlockView world, Entity entity) Called after the entity lands on the block.void
Block.onEntityLand
(BlockView world, Entity entity) Called after the entity lands on the block.void
SlimeBlock.onEntityLand
(BlockView world, Entity entity) Called after the entity lands on the block.void
BedBlock.onLandedUpon
(World world, BlockState state, BlockPos pos, Entity entity, float fallDistance) Called when the entity lands on the block.void
Block.onLandedUpon
(World world, BlockState state, BlockPos pos, Entity entity, float fallDistance) Called when the entity lands on the block.void
FarmlandBlock.onLandedUpon
(World world, BlockState state, BlockPos pos, Entity entity, float fallDistance) Called when the entity lands on the block.void
HayBlock.onLandedUpon
(World world, BlockState state, BlockPos pos, Entity entity, float fallDistance) Called when the entity lands on the block.void
HoneyBlock.onLandedUpon
(World world, BlockState state, BlockPos pos, Entity entity, float fallDistance) Called when the entity lands on the block.void
PointedDripstoneBlock.onLandedUpon
(World world, BlockState state, BlockPos pos, Entity entity, float fallDistance) Called when the entity lands on the block.void
PowderSnowBlock.onLandedUpon
(World world, BlockState state, BlockPos pos, Entity entity, float fallDistance) Called when the entity lands on the block.void
SlimeBlock.onLandedUpon
(World world, BlockState state, BlockPos pos, Entity entity, float fallDistance) Called when the entity lands on the block.void
TurtleEggBlock.onLandedUpon
(World world, BlockState state, BlockPos pos, Entity entity, float fallDistance) Called when the entity lands on the block.void
Block.onSteppedOn
(World world, BlockPos pos, BlockState state, Entity entity) Called when an entity steps on this block.void
MagmaBlock.onSteppedOn
(World world, BlockPos pos, BlockState state, Entity entity) Called when an entity steps on this block.void
RedstoneOreBlock.onSteppedOn
(World world, BlockPos pos, BlockState state, Entity entity) Called when an entity steps on this block.void
SculkSensorBlock.onSteppedOn
(World world, BlockPos pos, BlockState state, Entity entity) Called when an entity steps on this block.void
SculkShriekerBlock.onSteppedOn
(World world, BlockPos pos, BlockState state, Entity entity) Called when an entity steps on this block.void
SlimeBlock.onSteppedOn
(World world, BlockPos pos, BlockState state, Entity entity) Called when an entity steps on this block.void
TurtleEggBlock.onSteppedOn
(World world, BlockPos pos, BlockState state, Entity entity) Called when an entity steps on this block.static ActionResult
CaveVines.pickBerries
(@Nullable Entity picker, BlockState state, World world, BlockPos pos) private void
private void
DoorBlock.playOpenCloseSound
(@Nullable Entity entity, World world, BlockPos pos, boolean open) boolean
void
SculkSensorBlock.setActive
(@Nullable Entity sourceEntity, World world, BlockPos pos, BlockState state, int power, int frequency) static void
LecternBlock.setHasBook
(@Nullable Entity user, World world, BlockPos pos, BlockState state, boolean hasBook) void
DoorBlock.setOpen
(@Nullable Entity entity, World world, BlockState state, BlockPos pos, boolean open) static void
private static void
CarvedPumpkinBlock.spawnEntity
(World world, BlockPattern.Result patternResult, Entity entity, BlockPos pos) private static int
TargetBlock.trigger
(WorldAccess world, BlockState state, BlockHitResult hitResult, Entity entity) private void
HoneyBlock.triggerAdvancement
(Entity entity, BlockPos pos) private void
TurtleEggBlock.tryBreakEgg
(World world, BlockState state, BlockPos pos, Entity entity, int inverseChance) static void
SculkSensorBlock.tryResonate
(@Nullable Entity sourceEntity, World world, BlockPos pos, int frequency) private void
AbstractPressurePlateBlock.updatePlateState
(@Nullable Entity entity, World world, BlockPos pos, BlockState state, int output) private void
HoneyBlock.updateSlidingVelocity
(Entity entity) Modifier and TypeMethodDescriptionprivate <T extends AbstractMinecartEntity>
List<T> DetectorRailBlock.getCarts
(World world, BlockPos pos, Class<T> entityClass, Predicate<Entity> entityPredicate) protected static int
AbstractPressurePlateBlock.getEntityCount
(World world, Box box, Class<? extends Entity> entityClass) private void
TripwireBlock.updatePowered
(World world, BlockPos pos, List<? extends Entity> entities) ModifierConstructorDescriptionprotected
EntityShapeContext
(boolean descending, double minY, ItemStack heldItem, Predicate<FluidState> walkOnFluidPredicate, @Nullable Entity entity) protected
EntityShapeContext
(Entity entity, boolean collidesWithFluid) Deprecated. -
Uses of Entity in net.minecraft.block.entity
Modifier and TypeMethodDescriptionBeehiveBlockEntity.BeeData.loadEntity
(World world, BlockPos pos) Modifier and TypeMethodDescriptionBeehiveBlockEntity.tryReleaseBee
(BlockState state, BeehiveBlockEntity.BeeState beeState) Modifier and TypeMethodDescriptionvoid
SculkSensorBlockEntity.VibrationCallback.accept
(ServerWorld world, BlockPos pos, RegistryEntry<GameEvent> event, @Nullable Entity sourceEntity, @Nullable Entity entity, float distance) Accepts a game event after delay.void
SculkShriekerBlockEntity.VibrationCallback.accept
(ServerWorld world, BlockPos pos, RegistryEntry<GameEvent> event, @Nullable Entity sourceEntity, @Nullable Entity entity, float distance) Accepts a game event after delay.private static boolean
PistonBlockEntity.canMoveEntity
(Box box, Entity entity, BlockPos pos) static @Nullable ServerPlayerEntity
SculkShriekerBlockEntity.findResponsiblePlayerFromEntity
(@Nullable Entity entity) private static void
PistonBlockEntity.moveEntity
(Direction direction, Entity entity, double distance, Direction movementDirection) static BeehiveBlockEntity.BeeData
static void
HopperBlockEntity.onEntityCollided
(World world, BlockPos pos, BlockState state, Entity entity, HopperBlockEntity blockEntity) private static void
private void
SculkShriekerBlockEntity.shriek
(ServerWorld world, @Nullable Entity entity) private static void
ConduitBlockEntity.spawnNautilusParticles
(World world, BlockPos pos, List<BlockPos> activatingBlocks, @Nullable Entity entity, int ticks) void
BeehiveBlockEntity.tryEnterHive
(Entity entity) Modifier and TypeMethodDescriptionprivate static boolean
BeehiveBlockEntity.releaseBee
(World world, BlockPos pos, BlockState state, BeehiveBlockEntity.BeeData bee, @Nullable List<Entity> entities, BeehiveBlockEntity.BeeState beeState, @Nullable BlockPos flowerPos) -
Uses of Entity in net.minecraft.block.enums
Modifier and TypeMethodDescriptionTrialSpawnerState.getRandomEntity
(List<PlayerEntity> players, Set<UUID> entityUuids, TrialSpawnerLogic logic, BlockPos pos, ServerWorld world) Modifier and TypeMethodDescriptionTrialSpawnerState.getPosAbove
(Entity entity, ServerWorld world) -
Uses of Entity in net.minecraft.block.spawner
Modifier and TypeMethodDescriptionprivate static <T extends Entity>
MobSpawnerEntryTrialSpawnerConfigs.createEntry
(EntityType<T> entityType) private static <T extends Entity>
MobSpawnerEntryTrialSpawnerConfigs.createEntry
(EntityType<T> entityType, Consumer<NbtCompound> nbtConsumer) private static <T extends Entity>
MobSpawnerEntryTrialSpawnerConfigs.createEntry
(EntityType<T> entityType, Consumer<NbtCompound> nbtConsumer, @Nullable RegistryKey<LootTable> equipmentTable) private static <T extends Entity>
MobSpawnerEntryTrialSpawnerConfigs.createEntry
(EntityType<T> entityType, RegistryKey<LootTable> equipmentTable) EntityDetector.Selector.getEntities
(ServerWorld world, TypeFilter<Entity, T> typeFilter, Box box, Predicate<? super T> predicate) Modifier and TypeMethodDescriptionMobSpawnerLogic.getRenderedEntity
(World world, BlockPos pos) TrialSpawnerData.setDisplayEntity
(TrialSpawnerLogic logic, World world, TrialSpawnerState state) Modifier and TypeMethodDescriptionEntityDetector.Selector.getEntities
(ServerWorld world, TypeFilter<Entity, T> typeFilter, Box box, Predicate<? super T> predicate) -
Uses of Entity in net.minecraft.client
Modifier and TypeMethodDescriptionboolean
MinecraftClient.hasOutline
(Entity entity) Checks if the providedentity
should display an outline around its model.void
MinecraftClient.setCameraEntity
(Entity entity) -
Uses of Entity in net.minecraft.client.gui.hud
Modifier and TypeMethodDescriptionprivate void
InGameHud.renderVignetteOverlay
(DrawContext context, @Nullable Entity entity) private void
InGameHud.updateVignetteDarkness
(Entity entity) -
Uses of Entity in net.minecraft.client.item
Modifier and TypeMethodDescriptionprivate boolean
CompassAnglePredicateProvider.canPointTo
(Entity entity, @Nullable GlobalPos pos) private float
CompassAnglePredicateProvider.getAngle
(ItemStack stack, ClientWorld world, int seed, Entity entity) private float
CompassAnglePredicateProvider.getAngleTo
(Entity entity, long time, BlockPos pos) private double
CompassAnglePredicateProvider.getAngleTo
(Entity entity, BlockPos pos) private double
CompassAnglePredicateProvider.getBodyYaw
(Entity entity) private @Nullable ClientWorld
CompassAnglePredicateProvider.getClientWorld
(Entity entity, @Nullable ClientWorld world) CompassAnglePredicateProvider.CompassTarget.getPos
(ClientWorld world, ItemStack stack, Entity entity) -
Uses of Entity 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.Modifier and TypeMethodDescriptionClientPlayNetworkHandler.createEntity
(EntitySpawnS2CPacket packet) Modifier and TypeMethodDescriptionvoid
ClientPlayerEntity.addCritParticles
(Entity target) void
ClientPlayerEntity.addEnchantedHitParticles
(Entity target) void
ClientPlayerInteractionManager.attackEntity
(PlayerEntity player, Entity target) private boolean
ClientPlayerEntity.canVehicleSprint
(Entity vehicle) ClientPlayerInteractionManager.interactEntity
(PlayerEntity player, Entity entity, Hand hand) ClientPlayerInteractionManager.interactEntityAtLocation
(PlayerEntity player, Entity entity, EntityHitResult hitResult, Hand hand) private void
ClientPlayNetworkHandler.playSpawnSound
(Entity entity) private static boolean
ClientPlayNetworkHandler.setPosition
(PlayerPosition pos, Set<PositionFlag> flags, Entity entity, boolean bool) boolean
ClientPlayerEntity.startRiding
(Entity entity, boolean force) Starts ridingentity
. -
Uses of Entity in net.minecraft.client.particle
Modifier and TypeFieldDescriptionprivate final Entity
EmitterParticle.entity
private final Entity
ItemPickupParticle.interactingEntity
private final Entity
ItemPickupParticle.itemEntity
Modifier and TypeMethodDescriptionvoid
ParticleManager.addEmitter
(Entity entity, ParticleEffect parameters) void
ParticleManager.addEmitter
(Entity entity, ParticleEffect parameters, int maxAge) private Entity
ModifierConstructorDescriptionEmitterParticle
(ClientWorld world, Entity entity, ParticleEffect parameters) EmitterParticle
(ClientWorld world, Entity entity, ParticleEffect parameters, int maxEmitterAge) private
EmitterParticle
(ClientWorld world, Entity entity, ParticleEffect parameters, int maxEmitterAge, Vec3d velocity) ItemPickupParticle
(EntityRenderDispatcher dispatcher, BufferBuilderStorage bufferStorage, ClientWorld world, Entity itemEntity, Entity interactingEntity) private
ItemPickupParticle
(EntityRenderDispatcher dispatcher, BufferBuilderStorage bufferStorage, ClientWorld world, Entity itemEntity, Entity interactingEntity, Vec3d velocity) -
Uses of Entity in net.minecraft.client.render
Modifier and TypeMethodDescriptionprivate void
WorldRenderer.drawBlockOutline
(MatrixStack matrices, VertexConsumer vertexConsumer, Entity entity, double cameraX, double cameraY, double cameraZ, BlockPos pos, BlockState state, int color) private HitResult
GameRenderer.findCrosshairTarget
(Entity camera, double blockInteractionRange, double entityInteractionRange, float tickDelta) private static @Nullable BackgroundRenderer.StatusEffectFogModifier
BackgroundRenderer.getFogModifier
(Entity entity, float tickDelta) void
GameRenderer.onCameraEntitySet
(@Nullable Entity entity) private void
WorldRenderer.renderEntity
(Entity entity, double cameraX, double cameraY, double cameraZ, float tickDelta, MatrixStack matrices, VertexConsumerProvider vertexConsumers) void
Camera.update
(BlockView area, Entity focusedEntity, boolean thirdPerson, boolean inverseView, float tickDelta) Modifier and TypeMethodDescriptionprivate boolean
WorldRenderer.getEntitiesToRender
(Camera camera, Frustum frustum, List<Entity> output) private void
WorldRenderer.renderEntities
(MatrixStack matrices, VertexConsumerProvider.Immediate immediate, Camera camera, RenderTickCounter tickCounter, List<Entity> entities) -
Uses of Entity in net.minecraft.client.render.block.entity
Modifier and TypeMethodDescriptionstatic void
MobSpawnerBlockEntityRenderer.render
(float tickDelta, MatrixStack matrices, VertexConsumerProvider vertexConsumers, int light, Entity entity, EntityRenderDispatcher entityRenderDispatcher, double lastRotation, double rotation) -
Uses of Entity in net.minecraft.client.render.debug
Modifier and TypeMethodDescriptionDebugRenderer.getTargetedEntity
(@Nullable Entity entity, int maxDistance) Modifier and TypeMethodDescriptionprivate double
SupportingBlockDebugRenderer.getAdditionalDilation
(Entity entity) DebugRenderer.getTargetedEntity
(@Nullable Entity entity, int maxDistance) private void
SupportingBlockDebugRenderer.renderBlockHighlights
(MatrixStack matrices, VertexConsumerProvider vertexConsumers, double cameraX, double cameraY, double cameraZ, Entity entity, DoubleSupplier extraDilation, float red, float green, float blue) -
Uses of Entity in net.minecraft.client.render.entity
Modifier and TypeClassDescriptionclass
EmptyEntityRenderer<T extends Entity>
A renderer that does not render anything.class
EntityRenderer<T extends Entity,
S extends EntityRenderState> interface
EntityRendererFactory<T extends Entity>
class
FlyingItemEntityRenderer<T extends Entity & FlyingItemEntity>
Modifier and TypeMethodDescription<E extends Entity>
intEntityRenderDispatcher.getLight
(E entity, float tickDelta) <T extends Entity>
EntityRenderer<? super T, ?> EntityRenderDispatcher.getRenderer
(T entity) private static <T extends Entity>
voidEntityRenderers.register
(EntityType<? extends T> type, EntityRendererFactory<T> factory) <E extends Entity>
voidEntityRenderDispatcher.render
(E entity, double x, double y, double z, float tickDelta, MatrixStack matrices, VertexConsumerProvider vertexConsumers, int light) private <E extends Entity,
S extends EntityRenderState>
voidEntityRenderDispatcher.render
(E entity, double x, double y, double z, float tickDelta, MatrixStack matrices, VertexConsumerProvider vertexConsumers, int light, EntityRenderer<? super E, S> renderer) <E extends Entity>
booleanEntityRenderDispatcher.shouldRender
(E entity, Frustum frustum, double x, double y, double z) Modifier and TypeMethodDescriptionGuardianEntityRenderer.getBeamTarget
(GuardianEntity guardian) EntityRenderDispatcher.getIntegratedServerEntity
(Entity entity) Modifier and TypeMethodDescriptionvoid
EntityRenderDispatcher.getIntegratedServerEntity
(Entity entity) double
EntityRenderDispatcher.getSquaredDistanceToCamera
(Entity entity) private static void
EntityRenderDispatcher.renderHitbox
(MatrixStack matrices, VertexConsumer vertices, Entity entity, float tickDelta, float red, float green, float blue) private static void
EntityRenderDispatcher.renderServerSideHitbox
(MatrixStack matrices, Entity entity, VertexConsumerProvider vertexConsumers) -
Uses of Entity in net.minecraft.client.sound
ModifierConstructorDescriptionEntityTrackingSoundInstance
(SoundEvent sound, SoundCategory category, float volume, float pitch, Entity entity, long seed) -
Uses of Entity in net.minecraft.client.world
Modifier and TypeFieldDescriptionprivate final ClientEntityManager
<Entity> ClientWorld.entityManager
Modifier and TypeMethodDescriptionClientWorld.getEntityById
(int id) Returns the entity using the entity ID, ornull
if none was found.Modifier and TypeMethodDescriptionClientWorld.getEntities()
protected EntityLookup
<Entity> ClientWorld.getEntityLookup()
Modifier and TypeMethodDescriptionvoid
void
void
ClientWorld.createExplosion
(@Nullable Entity entity, @Nullable DamageSource damageSource, @Nullable ExplosionBehavior behavior, double x, double y, double z, float power, boolean createFire, World.ExplosionSourceType explosionSourceType, ParticleEffect smallParticle, ParticleEffect largeParticle, RegistryEntry<SoundEvent> soundEvent) Creates an explosion.void
boolean
void
ClientWorld.playSoundFromEntity
(Entity entity, SoundEvent sound, SoundCategory category, float volume, float pitch) void
ClientWorld.playSoundFromEntity
(@Nullable PlayerEntity source, Entity entity, RegistryEntry<SoundEvent> sound, SoundCategory category, float volume, float pitch, long seed) boolean
ClientWorld.shouldUpdatePostDeath
(Entity entity) void
ClientWorld.ClientEntityHandler.startTicking
(Entity entity) void
ClientWorld.ClientEntityHandler.startTracking
(Entity entity) void
ClientWorld.ClientEntityHandler.stopTicking
(Entity entity) void
ClientWorld.ClientEntityHandler.stopTracking
(Entity entity) void
ClientWorld.tickEntity
(Entity entity) private void
ClientWorld.tickPassenger
(Entity entity, Entity passenger) void
ClientWorld.ClientEntityHandler.updateLoadStatus
(Entity entity) -
Uses of Entity in net.minecraft.command
Modifier and TypeFieldDescriptionstatic final BiConsumer
<Vec3d, List<? extends Entity>> EntitySelector.ARBITRARY
private final TypeFilter
<Entity, ?> EntitySelector.entityFilter
static final BiConsumer
<Vec3d, List<? extends Entity>> EntitySelectorReader.FURTHEST
static final BiConsumer
<Vec3d, List<? extends Entity>> EntitySelectorReader.NEAREST
private static final TypeFilter
<Entity, ?> EntitySelector.PASSTHROUGH_FILTER
EntitySelector.predicates
EntitySelectorReader.predicates
static final BiConsumer
<Vec3d, List<? extends Entity>> EntitySelectorReader.RANDOM
private final BiConsumer
<Vec3d, List<? extends Entity>> EntitySelector.sorter
private BiConsumer
<Vec3d, List<? extends Entity>> EntitySelectorReader.sorter
Modifier and TypeMethodDescriptionEntitySelector.getEntities
(ServerCommandSource source) EntitySelector.getPositionPredicate
(Vec3d pos, @Nullable Box box, @Nullable FeatureSet enabledFeatures) BiConsumer
<Vec3d, List<? extends Entity>> EntitySelectorReader.getSorter()
EntitySelectorReader.rotationPredicate
(FloatRangeArgument angleRange, ToDoubleFunction<Entity> entityToAngle) Modifier and TypeMethodDescriptionvoid
EntitySelectorReader.addPredicate
(Predicate<Entity> predicate) private void
EntitySelector.appendEntitiesFromWorld
(List<Entity> entities, ServerWorld world, @Nullable Box box, Predicate<Entity> predicate) private void
EntitySelector.appendEntitiesFromWorld
(List<Entity> entities, ServerWorld world, @Nullable Box box, Predicate<Entity> predicate) static Text
EntitySelectorReader.rotationPredicate
(FloatRangeArgument angleRange, ToDoubleFunction<Entity> entityToAngle) void
EntitySelectorReader.setSorter
(BiConsumer<Vec3d, List<? extends Entity>> sorter) ModifierConstructorDescriptionEntitySelector
(int count, boolean includesNonPlayers, boolean localWorldOnly, List<Predicate<Entity>> predicates, NumberRange.DoubleRange distance, Function<Vec3d, Vec3d> positionOffset, @Nullable Box box, BiConsumer<Vec3d, List<? extends Entity>> sorter, boolean senderOnly, @Nullable String playerName, @Nullable UUID uuid, @Nullable EntityType<?> type, boolean usesAt) EntitySelector
(int count, boolean includesNonPlayers, boolean localWorldOnly, List<Predicate<Entity>> predicates, NumberRange.DoubleRange distance, Function<Vec3d, Vec3d> positionOffset, @Nullable Box box, BiConsumer<Vec3d, List<? extends Entity>> sorter, boolean senderOnly, @Nullable String playerName, @Nullable UUID uuid, @Nullable EntityType<?> type, boolean usesAt) -
Uses of Entity in net.minecraft.command.argument
Modifier and TypeFieldDescriptionprivate final BiFunction
<Vec3d, Entity, Vec3d> EntityAnchorArgumentType.EntityAnchor.offset
Modifier and TypeMethodDescriptionstatic Entity
EntityArgumentType.getEntity
(com.mojang.brigadier.context.CommandContext<ServerCommandSource> context, String name) Modifier and TypeMethodDescriptionstatic Collection
<? extends Entity> EntityArgumentType.getEntities
(com.mojang.brigadier.context.CommandContext<ServerCommandSource> context, String name) static Collection
<? extends Entity> EntityArgumentType.getOptionalEntities
(com.mojang.brigadier.context.CommandContext<ServerCommandSource> context, String name) Modifier and TypeMethodDescriptionEntityAnchorArgumentType.EntityAnchor.positionAt
(Entity entity) ModifierConstructorDescriptionprivate
EntityAnchor
(String id, BiFunction<Vec3d, Entity, Vec3d> offset) -
Uses of Entity in net.minecraft.component.type
-
Uses of Entity in net.minecraft.enchantment
Modifier and TypeMethodDescriptionstatic void
Enchantment.applyTargetedEffect
(TargetedEnchantmentEffect<EnchantmentEntityEffect> effect, ServerWorld world, int level, EnchantmentEffectContext context, Entity user, DamageSource damageSource) static LootContext
Enchantment.createEnchantedDamageLootContext
(ServerWorld world, int level, Entity entity, DamageSource damageSource) private static LootContext
Enchantment.createEnchantedEntityLootContext
(ServerWorld world, int level, Entity entity, Vec3d pos) private static LootContext
Enchantment.createEnchantedLocationLootContext
(ServerWorld world, int level, Entity entity, boolean enchantmentActive) private static LootContext
Enchantment.createHitBlockLootContext
(ServerWorld world, int level, Entity entity, Vec3d pos, BlockState state) static float
EnchantmentHelper.getArmorEffectiveness
(ServerWorld world, ItemStack stack, Entity user, DamageSource damageSource, float baseArmorEffectiveness) static float
EnchantmentHelper.getDamage
(ServerWorld world, ItemStack stack, Entity target, DamageSource damageSource, float baseDamage) static int
EnchantmentHelper.getFishingLuckBonus
(ServerWorld world, ItemStack stack, Entity user) static float
EnchantmentHelper.getFishingTimeReduction
(ServerWorld world, ItemStack stack, Entity user) static int
EnchantmentHelper.getMobExperience
(ServerWorld world, @Nullable Entity attacker, Entity mob, int baseMobExperience) static int
EnchantmentHelper.getProjectileCount
(ServerWorld world, ItemStack stack, Entity user, int baseProjectileCount) static float
EnchantmentHelper.getProjectileSpread
(ServerWorld world, ItemStack stack, Entity user, float baseProjectileSpread) static float
EnchantmentHelper.getSmashDamagePerFallenBlock
(ServerWorld world, ItemStack stack, Entity target, DamageSource damageSource, float baseSmashDamagePerFallenBlock) static int
EnchantmentHelper.getTridentReturnAcceleration
(ServerWorld world, ItemStack stack, Entity user) boolean
Enchantment.hasDamageImmunityTo
(ServerWorld world, int level, Entity user, DamageSource damageSource) void
Enchantment.modifyArmorEffectiveness
(ServerWorld world, int level, ItemStack stack, Entity user, DamageSource damageSource, MutableFloat armorEffectiveness) void
Enchantment.modifyDamage
(ServerWorld world, int level, ItemStack stack, Entity user, DamageSource damageSource, MutableFloat damage) void
Enchantment.modifyDamageProtection
(ServerWorld world, int level, ItemStack stack, Entity user, DamageSource damageSource, MutableFloat damageProtection) void
Enchantment.modifyFishingLuckBonus
(ServerWorld world, int level, ItemStack stack, Entity user, MutableFloat fishingLuckBonus) void
Enchantment.modifyFishingTimeReduction
(ServerWorld world, int level, ItemStack stack, Entity user, MutableFloat fishingTimeReduction) void
Enchantment.modifyKnockback
(ServerWorld world, int level, ItemStack stack, Entity user, DamageSource damageSource, MutableFloat knockback) static float
EnchantmentHelper.modifyKnockback
(ServerWorld world, ItemStack stack, Entity target, DamageSource damageSource, float baseKnockback) void
Enchantment.modifyMobExperience
(ServerWorld world, int level, ItemStack stack, Entity user, MutableFloat mobExperience) void
Enchantment.modifyProjectileCount
(ServerWorld world, int level, ItemStack stack, Entity user, MutableFloat projectileCount) void
Enchantment.modifyProjectileSpread
(ServerWorld world, int level, ItemStack stack, Entity user, MutableFloat projectileSpread) void
Enchantment.modifySmashDamagePerFallenBlock
(ServerWorld world, int level, ItemStack stack, Entity user, DamageSource damageSource, MutableFloat smashDamagePerFallenBlock) void
Enchantment.modifyTridentReturnAcceleration
(ServerWorld world, int level, ItemStack stack, Entity user, MutableFloat tridentReturnAcceleration) private void
Enchantment.modifyValue
(ComponentType<List<EnchantmentEffectEntry<EnchantmentValueEffect>>> type, ServerWorld world, int level, ItemStack stack, Entity user, DamageSource damageSource, MutableFloat value) private void
Enchantment.modifyValue
(ComponentType<List<EnchantmentEffectEntry<EnchantmentValueEffect>>> type, ServerWorld world, int level, ItemStack stack, Entity user, MutableFloat value) void
Enchantment.onHitBlock
(ServerWorld world, int level, EnchantmentEffectContext context, Entity enchantedEntity, Vec3d pos, BlockState state) static void
EnchantmentHelper.onHitBlock
(ServerWorld world, ItemStack stack, @Nullable LivingEntity user, Entity enchantedEntity, @Nullable EquipmentSlot slot, Vec3d pos, BlockState state, Consumer<Item> onBreak) void
Enchantment.onProjectileSpawned
(ServerWorld world, int level, EnchantmentEffectContext context, Entity user) void
Enchantment.onTargetDamaged
(ServerWorld world, int level, EnchantmentEffectContext context, EnchantmentEffectTarget target, Entity user, DamageSource damageSource) static void
EnchantmentHelper.onTargetDamaged
(ServerWorld world, Entity target, DamageSource damageSource) static void
EnchantmentHelper.onTargetDamaged
(ServerWorld world, Entity target, DamageSource damageSource, @Nullable ItemStack weapon) static void
EnchantmentHelper.onTargetDamaged
(ServerWorld world, Entity target, DamageSource damageSource, @Nullable ItemStack weapon, Consumer<Item> breakCallback) void
Enchantment.onTick
(ServerWorld world, int level, EnchantmentEffectContext context, Entity user) -
Uses of Entity in net.minecraft.enchantment.effect
Modifier and TypeMethodDescriptionvoid
AllOfEnchantmentEffects.EntityEffects.apply
(ServerWorld world, int level, EnchantmentEffectContext context, Entity user, Vec3d pos) void
AllOfEnchantmentEffects.LocationBasedEffects.apply
(ServerWorld world, int level, EnchantmentEffectContext context, Entity user, Vec3d pos, boolean newlyApplied) void
AttributeEnchantmentEffect.apply
(ServerWorld world, int level, EnchantmentEffectContext context, Entity user, Vec3d pos, boolean newlyApplied) void
EnchantmentEntityEffect.apply
(ServerWorld world, int level, EnchantmentEffectContext context, Entity user, Vec3d pos) default void
EnchantmentEntityEffect.apply
(ServerWorld world, int level, EnchantmentEffectContext context, Entity user, Vec3d pos, boolean newlyApplied) void
EnchantmentLocationBasedEffect.apply
(ServerWorld world, int level, EnchantmentEffectContext context, Entity user, Vec3d pos, boolean newlyApplied) void
AllOfEnchantmentEffects.LocationBasedEffects.remove
(EnchantmentEffectContext context, Entity user, Vec3d pos, int level) void
AttributeEnchantmentEffect.remove
(EnchantmentEffectContext context, Entity user, Vec3d pos, int level) default void
EnchantmentLocationBasedEffect.remove
(EnchantmentEffectContext context, Entity user, Vec3d pos, int level) -
Uses of Entity in net.minecraft.enchantment.effect.entity
Modifier and TypeMethodDescriptionvoid
ApplyMobEffectEnchantmentEffect.apply
(ServerWorld world, int level, EnchantmentEffectContext context, Entity user, Vec3d pos) void
ChangeItemDamageEnchantmentEffect.apply
(ServerWorld world, int level, EnchantmentEffectContext context, Entity user, Vec3d pos) void
DamageEntityEnchantmentEffect.apply
(ServerWorld world, int level, EnchantmentEffectContext context, Entity user, Vec3d pos) void
ExplodeEnchantmentEffect.apply
(ServerWorld world, int level, EnchantmentEffectContext context, Entity user, Vec3d pos) void
IgniteEnchantmentEffect.apply
(ServerWorld world, int level, EnchantmentEffectContext context, Entity user, Vec3d pos) void
PlaySoundEnchantmentEffect.apply
(ServerWorld world, int level, EnchantmentEffectContext context, Entity user, Vec3d pos) void
ReplaceBlockEnchantmentEffect.apply
(ServerWorld world, int level, EnchantmentEffectContext context, Entity user, Vec3d pos) void
ReplaceDiskEnchantmentEffect.apply
(ServerWorld world, int level, EnchantmentEffectContext context, Entity user, Vec3d pos) void
RunFunctionEnchantmentEffect.apply
(ServerWorld world, int level, EnchantmentEffectContext context, Entity user, Vec3d pos) void
SetBlockPropertiesEnchantmentEffect.apply
(ServerWorld world, int level, EnchantmentEffectContext context, Entity user, Vec3d pos) void
SpawnParticlesEnchantmentEffect.apply
(ServerWorld world, int level, EnchantmentEffectContext context, Entity user, Vec3d pos) void
SummonEntityEnchantmentEffect.apply
(ServerWorld world, int level, EnchantmentEffectContext context, Entity user, Vec3d pos) private @Nullable DamageSource
ExplodeEnchantmentEffect.getDamageSource
(Entity user, Vec3d pos) -
Uses of Entity in net.minecraft.entity
Modifier and TypeClassDescriptionclass
EntityType<T extends Entity>
static class
EntityType.Builder<T extends Entity>
static interface
EntityType.EntityFactory<T extends Entity>
static interface
SpawnRestriction.SpawnPredicate<T extends Entity>
Modifier and TypeClassDescriptionclass
class
class
class
class
class
class
Represents an entity which has a health value and can receive damage.class
class
class
Modifier and TypeFieldDescriptionLeashable.LeashData.leashHolder
ItemEntity.thrower
Entity.vehicle
Modifier and TypeFieldDescriptionAreaEffectCloudEntity.affectedEntities
private ImmutableList
<Entity> Entity.passengerList
LightningEntity.struckEntities
Modifier and TypeMethodDescriptionLeashable.applyLeashElasticity
(E entity, Entity leashHolder, float distance) Leashable.attachLeash
(E entity, Entity leashHolder, boolean sendPacket) static <T extends Entity>
booleanSpawnRestriction.canSpawn
(EntityType<T> type, ServerWorldAccess world, SpawnReason spawnReason, BlockPos pos, Random random) EntityType.copier
(World world, ItemStack stack, @Nullable PlayerEntity player) static <T extends Entity>
EntityType.Builder<T> EntityType.Builder.create
(EntityType.EntityFactory<T> factory, SpawnGroup spawnGroup) static <T extends Entity>
EntityType.Builder<T> EntityType.Builder.create
(SpawnGroup spawnGroup) EntityType.customNameCopier
(Consumer<T> chained, ItemStack stack) Leashable.detachLeash
(E entity, boolean sendPacket, boolean dropItem) Leashable.getLeashHolder
(E entity) EntityType.nbtCopier
(Consumer<T> chained, World world, ItemStack stack, @Nullable PlayerEntity player) private static <T extends Entity>
EntityType<T> EntityType.register
(String id, EntityType.Builder<T> type) private static <T extends Entity>
EntityType<T> EntityType.register
(RegistryKey<EntityType<?>> key, EntityType.Builder<T> type) Leashable.resolveLeashData
(E entity, Leashable.LeashData leashData) Leashable.tickLeash
(ServerWorld world, E entity) Modifier and TypeMethodDescriptionEntity.getControllingVehicle()
Returns the entity this entity rides and controls, ornull
if there is none.Entity.getFirstPassenger()
Returns the first passenger of the passenger list, ornull
if there is no passengers.Leashable.getLeashHolder()
Leashable.getLeashHolder
(E entity) ItemEntity.getOwner()
Ownable.getOwner()
Entity.getRootVehicle()
Returns the lowest entity this entity is riding.Entity.getVehicle()
Returns the entity this entity rides, ornull
if there is none.EntityType.loadEntityWithPassengers
(NbtCompound nbt, World world, SpawnReason reason, Function<Entity, Entity> entityProcessor) private Entity
OminousItemSpawnerEntity.spawnProjectile
(ServerWorld world, ProjectileItem item, ItemStack stack) private Entity
Entity.teleportCrossDimension
(ServerWorld world, TeleportTarget teleportTarget) private Entity
Entity.teleportSameDimension
(ServerWorld world, TeleportTarget teleportTarget) Entity.teleportTo
(TeleportTarget teleportTarget) Teleports this entity to another location, potentially in another world.FallingBlockEntity.teleportTo
(TeleportTarget teleportTarget) Teleports this entity to another location, potentially in another world.ItemEntity.teleportTo
(TeleportTarget teleportTarget) Teleports this entity to another location, potentially in another world.TntEntity.teleportTo
(TeleportTarget teleportTarget) Teleports this entity to another location, potentially in another world.Modifier and TypeMethodDescriptionEntityType.getBaseClass()
EntityType.getEntityFromNbt
(NbtCompound nbt, World world, SpawnReason reason) Entity.getPassengerList()
Returns the list of passengers of this entity.Entity.getPassengersDeep()
Returns an iterable of all passengers.LightningEntity.getStruckEntities()
EntityType.loadEntityFromNbt
(NbtCompound nbt, World world, SpawnReason reason) EntityType.streamFromNbt
(List<? extends NbtElement> entityNbtList, World world, SpawnReason reason) Entity.streamIntoPassengers()
Returns a recursive stream of all passengers.Entity.streamPassengersAndSelf()
Returns a stream consisting of this entity and its passengers in which this entity's passengers are iterated before this entity.Entity.streamSelfAndPassengers()
Returns a stream consisting of this entity and its passengers recursively.Modifier and TypeMethodDescriptionvoid
protected void
Entity.addPassenger
(Entity passenger) Addspassenger
as a passenger.protected void
MarkerEntity.addPassenger
(Entity passenger) Addspassenger
as a passenger.protected void
OminousItemSpawnerEntity.addPassenger
(Entity passenger) Addspassenger
as a passenger.boolean
LivingEntity.addStatusEffect
(StatusEffectInstance effect, @Nullable Entity source) Adds a status effect to this entity.static Vec3d
Entity.adjustMovementForCollisions
(@Nullable Entity entity, Vec3d movement, Box entityBoundingBox, World world, List<VoxelShape> collisions) Leashable.applyLeashElasticity
(E entity, Entity leashHolder, float distance) default void
Leashable.applyLeashElasticity
(Entity leashHolder, float distance) Leashable.attachLeash
(E entity, Entity leashHolder, boolean sendPacket) default void
Leashable.attachLeash
(Entity leashHolder, boolean sendPacket) default boolean
Leashable.beforeLeashTick
(Entity leashHolder, float distance) Called before the default leash-ticking logic.protected boolean
Entity.canAddPassenger
(Entity passenger) Returns whetherentity
can ride this entity.protected boolean
MarkerEntity.canAddPassenger
(Entity passenger) Returns whetherentity
can ride this entity.protected boolean
OminousItemSpawnerEntity.canAddPassenger
(Entity passenger) Returns whetherentity
can ride this entity.boolean
boolean
LivingEntity.canSee
(Entity entity, RaycastContext.ShapeType shapeType, RaycastContext.FluidHandling fluidHandling, DoubleSupplier entityY) protected boolean
Entity.canStartRiding
(Entity entity) Returns whether this entity can rideentity
.boolean
Entity.collidesWith
(Entity other) Returns whether this entity cannot occupy the same space withother
.void
Copies serializable data and nether portal data fromoriginal
.void
Copies serializable data and nether portal data fromoriginal
.void
Copies serializable data and nether portal data fromoriginal
.void
Entity.copyPositionAndRotation
(Entity entity) Sets the entity's position and rotation the same asentity
.void
ProjectileDeflection.deflect
(ProjectileEntity projectile, @Nullable Entity hitEntity, Random random) float
Entity.distanceTo
(Entity entity) Returns the distance between this entity andentity
.protected void
LivingEntity.dropXp
(ServerWorld world, @Nullable Entity attacker) Drops experience when this entity is killed.void
Entity.emitGameEvent
(RegistryEntry<GameEvent> event, @Nullable Entity entity) Emits a game event originating from another entity at this entity's position.private static List
<VoxelShape> Entity.findCollisionsForMovement
(@Nullable Entity entity, World world, List<VoxelShape> regularCollisions, Box movingEntityBoundingBox) double
LivingEntity.getAttackDistanceScalingFactor
(@Nullable Entity entity) protected float
LivingEntity.getKnockbackAgainst
(Entity target, DamageSource damageSource) protected Vec3d
Entity.getPassengerAttachmentPos
(Entity passenger, EntityDimensions dimensions, float scaleFactor) protected static Vec3d
Entity.getPassengerAttachmentPos
(Entity vehicle, Entity passenger, EntityAttachments attachments) Entity.getPassengerRidingPos
(Entity passenger) LivingEntity.getPassengerRidingPos
(Entity passenger) private TeleportTarget
Entity.getPassengerTeleportTarget
(TeleportTarget teleportTarget, Entity passenger) Entity.getVehicleAttachmentPos
(Entity vehicle) final int
LivingEntity.getXpToDrop
(ServerWorld world, @Nullable Entity attacker) boolean
Entity.handleAttack
(Entity attacker) Handles a player attacking the entity.boolean
Entity.hasPassenger
(Entity passenger) Returns whetherpassenger
is a passenger of this entity.boolean
Entity.hasPassengerDeep
(Entity passenger) Returns whetherpassenger
is riding this entity or any of its passengers.boolean
Entity.isConnectedThroughVehicle
(Entity entity) Returns whether this entity and another entity share the same root vehicle.boolean
Returns whether the distance between this entity andentity
is belowradius
.boolean
Returns whether both the horizontal and vertical distances between this entity andentity
are below the passed values.protected boolean
Entity.isInSameTeam
(Entity other) boolean
Returns whether this entity is part ofentity
.final boolean
Entity.isTeammate
(@Nullable Entity other) Returns whether this entity andother
are in the same team.static void
EntityType.loadFromEntityNbt
(World world, @Nullable PlayerEntity player, @Nullable Entity entity, NbtComponent nbt) void
LivingEntity.onAttacking
(Entity target) private void
LivingEntity.onDismounted
(Entity vehicle) void
Entity.onExplodedBy
(@Nullable Entity entity) void
InteractionObserver.onInteractionWith
(EntityInteraction interaction, Entity entity) void
Entity.onPassengerLookAround
(Entity passenger) default void
Leashable.onShortLeashTick
(Entity entity) protected void
LivingEntity.onStatusEffectApplied
(StatusEffectInstance effect, @Nullable Entity source) protected void
LivingEntity.onStatusEffectUpgraded
(StatusEffectInstance effect, boolean reapplyEffect, @Nullable Entity source) protected void
void
Entity.pushAwayFrom
(Entity entity) void
LivingEntity.pushAwayFrom
(Entity entity) protected void
Entity.removePassenger
(Entity passenger) Removespassenger
from the passengers.void
LivingEntity.sendPickup
(Entity item, int count) void
Leashable.LeashData.setLeashHolder
(Entity leashHolder) void
LivingEntity.setStatusEffect
(StatusEffectInstance effect, @Nullable Entity source) Sets a status effect in this entity.void
ItemEntity.setThrower
(Entity thrower) Sets the thrower of this item entity tothrower
.double
Entity.squaredDistanceTo
(Entity entity) Returns the squared distance between this entity andentity
.boolean
Entity.startRiding
(Entity entity) Starts ridingentity
.boolean
Entity.startRiding
(Entity entity, boolean force) Starts ridingentity
.boolean
LivingEntity.tryAttack
(ServerWorld world, Entity target) void
Entity.updateKilledAdvancementCriterion
(Entity entityKilled, int score, DamageSource damageSource) final void
Entity.updatePassengerPosition
(Entity passenger) protected void
Entity.updatePassengerPosition
(Entity passenger, Entity.PositionUpdater positionUpdater) Modifier and TypeMethodDescriptionboolean
Entity.hasPassenger
(Predicate<Entity> predicate) Returns whether there is a passenger of this entity matchingpredicate
.EntityType.loadEntityWithPassengers
(NbtCompound nbt, World world, SpawnReason reason, Function<Entity, Entity> entityProcessor) EntityType.loadEntityWithPassengers
(NbtCompound nbt, World world, SpawnReason reason, Function<Entity, Entity> entityProcessor) -
Uses of Entity in net.minecraft.entity.ai
Modifier and TypeFieldDescriptionWardenAngerManager.suspectPredicate
WardenAngerManager.suspects
protected final Object2IntMap
<Entity> WardenAngerManager.suspectsToAngerLevel
Modifier and TypeMethodDescriptionint
int
WardenAngerManager.getAngerFor
(@Nullable Entity entity) int
WardenAngerManager.increaseAngerAt
(Entity entity, int amount) void
WardenAngerManager.removeSuspect
(Entity entity) Modifier and TypeMethodDescriptionstatic com.mojang.serialization.Codec
<WardenAngerManager> WardenAngerManager.createCodec
(Predicate<Entity> suspectPredicate) void
WardenAngerManager.tick
(ServerWorld world, Predicate<Entity> suspectPredicate) -
Uses of Entity in net.minecraft.entity.ai.brain
Modifier and TypeFieldDescriptionstatic final MemoryModuleType
<Entity> MemoryModuleType.RIDE_TARGET
ModifierConstructorDescriptionEntityLookTarget
(Entity entity, boolean useEyeHeight) WalkTarget
(Entity entity, float speed, int completionRange) -
Uses of Entity in net.minecraft.entity.ai.brain.task
Modifier and TypeMethodDescriptionprivate static boolean
RidingTask.canRideTarget
(LivingEntity entity, Entity vehicle, int range) FleeTask.findClosestWater
(BlockView world, Entity entity) static void
TargetUtil.walkTowards
(LivingEntity entity, Entity target, float speed, int completionRange) Modifier and TypeMethodDescriptionstatic <E extends LivingEntity>
Task<E> RidingTask.create
(int range, BiPredicate<E, Entity> alternativeRideCondition) static SingleTickTask
<PathAwareEntity> GoToRememberedPositionTask.createEntityBased
(MemoryModuleType<? extends Entity> entityModule, float speed, int range, boolean requiresWalkTarget) -
Uses of Entity in net.minecraft.entity.ai.control
-
Uses of Entity in net.minecraft.entity.ai.goal
Modifier and TypeMethodDescriptionprotected static ServerWorld
Goal.getServerWorld
(Entity entity) EscapeDangerGoal.locateClosestWater
(BlockView world, Entity entity, int rangeX) -
Uses of Entity in net.minecraft.entity.ai.pathing
Modifier and TypeMethodDescriptionBirdNavigation.findPathTo
(Entity entity, int distance) EntityNavigation.findPathTo
(Entity entity, int distance) MobNavigation.findPathTo
(Entity entity, int distance) SpiderNavigation.findPathTo
(Entity entity, int distance) Path.getNodePosition
(Entity entity) Path.getNodePosition
(Entity entity, int index) boolean
EntityNavigation.startMovingTo
(Entity entity, double speed) boolean
SpiderNavigation.startMovingTo
(Entity entity, double speed) -
Uses of Entity in net.minecraft.entity.boss
Modifier and TypeMethodDescriptionboolean
WitherEntity.addStatusEffect
(StatusEffectInstance effect, @Nullable Entity source) Adds a status effect to this entity.protected boolean
WitherEntity.canStartRiding
(Entity entity) Returns whether this entity can rideentity
. -
Uses of Entity in net.minecraft.entity.boss.dragon
Modifier and TypeMethodDescriptionboolean
EnderDragonEntity.addStatusEffect
(StatusEffectInstance effect, @Nullable Entity source) Adds a status effect to this entity.protected boolean
EnderDragonEntity.canStartRiding
(Entity entity) Returns whether this entity can rideentity
.boolean
Returns whether this entity is part ofentity
.Modifier and TypeMethodDescriptionprivate void
EnderDragonEntity.damageLivingEntities
(ServerWorld world, List<Entity> entities) private void
EnderDragonEntity.launchLivingEntities
(ServerWorld world, List<Entity> entities) -
Uses of Entity in net.minecraft.entity.damage
Modifier and TypeMethodDescriptionDamageSources.arrow
(PersistentProjectileEntity source, @Nullable Entity attacker) private DamageSource
DamageSources.create
(RegistryKey<DamageType> key, @Nullable Entity attacker) private DamageSource
DamageSources.create
(RegistryKey<DamageType> key, @Nullable Entity source, @Nullable Entity attacker) DamageSources.fallingAnvil
(Entity attacker) DamageSources.fallingBlock
(Entity attacker) DamageSources.fallingStalactite
(Entity attacker) DamageSources.fireball
(AbstractFireballEntity source, @Nullable Entity attacker) DamageSources.fireworks
(FireworkRocketEntity source, @Nullable Entity attacker) private Text
DamageTracker.getAttackedFallDeathMessage
(Entity attacker, Text attackerDisplayName, String itemDeathTranslationKey, String deathTranslationKey) DamageTracker.getDisplayName
(@Nullable Entity entity) private Text
DamageTracker.getFallDeathMessage
(DamageRecord damageRecord, @Nullable Entity attacker) DamageSources.indirectMagic
(Entity source, @Nullable Entity attacker) DamageSources.mobProjectile
(Entity source, @Nullable LivingEntity attacker) DamageSources.spit
(Entity source, @Nullable LivingEntity attacker) DamageSources.windCharge
(Entity source, @Nullable LivingEntity attacker) DamageSources.witherSkull
(WitherSkullEntity source, Entity attacker) ModifierConstructorDescriptionDamageSource
(RegistryEntry<DamageType> type, @Nullable Entity attacker) DamageSource
(RegistryEntry<DamageType> type, @Nullable Entity source, @Nullable Entity attacker) private
DamageSource
(RegistryEntry<DamageType> type, @Nullable Entity source, @Nullable Entity attacker, @Nullable Vec3d position) -
Uses of Entity in net.minecraft.entity.decoration
Modifier and TypeClassDescriptionclass
class
class
class
static class
static class
static class
class
class
class
class
class
Modifier and TypeFieldDescriptionAbstractDecorationEntity.PREDICATE
ArmorStandEntity.RIDEABLE_MINECART_PREDICATE
Modifier and TypeMethodDescription(package private) void
(package private) void
DisplayEntity.InterpolationTarget.applyInterpolated
(Entity entity) private void
ItemFrameEntity.dropHeldStack
(ServerWorld world, @Nullable Entity entity, boolean dropSelf) boolean
ArmorStandEntity.handleAttack
(Entity attacker) Handles a player attacking the entity.boolean
BlockAttachedEntity.handleAttack
(Entity attacker) Handles a player attacking the entity.boolean
InteractionEntity.handleAttack
(Entity attacker) Handles a player attacking the entity.abstract void
BlockAttachedEntity.onBreak
(ServerWorld world, @Nullable Entity breaker) void
ItemFrameEntity.onBreak
(ServerWorld world, @Nullable Entity breaker) void
LeashKnotEntity.onBreak
(ServerWorld world, @Nullable Entity breaker) protected void
-
Uses of Entity in net.minecraft.entity.decoration.painting
Modifier and TypeMethodDescriptionvoid
PaintingEntity.onBreak
(ServerWorld world, @Nullable Entity breaker) -
Uses of Entity in net.minecraft.entity.effect
Modifier and TypeMethodDescriptionstatic List
<ServerPlayerEntity> StatusEffectUtil.addEffectToPlayersWithinDistance
(ServerWorld world, @Nullable Entity entity, Vec3d origin, double range, StatusEffectInstance statusEffectInstance, int duration) void
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) -
Uses of Entity in net.minecraft.entity.mob
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
class
Modifier and TypeFieldDescriptionRavagerEntity.CAN_KNOCK_BACK_WITH_ROAR
RavagerEntity.CAN_KNOCK_BACK_WITH_ROAR_NO_MOB_GRIEFING
Modifier and TypeMethodDescriptionprivate Entity
PiglinEntity.getTopMostPassenger
(Entity entity, int maxLevel) Returns the passenger entity atmaxLevel
in a stacked riding (riding on an entity that is riding on another entity, etc).Modifier and TypeMethodDescriptionvoid
WardenEntity.VibrationCallback.accept
(ServerWorld world, BlockPos pos, RegistryEntry<GameEvent> event, @Nullable Entity sourceEntity, @Nullable Entity entity, float distance) Accepts a game event after delay.static void
WardenEntity.addDarknessToClosePlayers
(ServerWorld world, Vec3d pos, @Nullable Entity entity, int range) protected void
TransientCreakingEntity.addPassenger
(Entity passenger) Addspassenger
as a passenger.boolean
PathAwareEntity.beforeLeashTick
(Entity leashHolder, float distance) Called before the default leash-ticking logic.protected boolean
TransientCreakingEntity.canAddPassenger
(Entity passenger) Returns whetherentity
can ride this entity.private static boolean
PiglinBrain.canRide
(PiglinEntity piglin, Entity ridden) boolean
boolean
protected boolean
WardenEntity.canStartRiding
(Entity entity) Returns whether this entity can rideentity
.void
Copies serializable data and nether portal data fromoriginal
.protected Vec3d
SlimeEntity.getPassengerAttachmentPos
(Entity passenger, EntityDimensions dimensions, float scaleFactor) private Entity
PiglinEntity.getTopMostPassenger
(Entity entity, int maxLevel) Returns the passenger entity atmaxLevel
in a stacked riding (riding on an entity that is riding on another entity, etc).CaveSpiderEntity.getVehicleAttachmentPos
(Entity vehicle) SpiderEntity.getVehicleAttachmentPos
(Entity vehicle) void
WardenEntity.increaseAngerAt
(@Nullable Entity entity) void
WardenEntity.increaseAngerAt
(@Nullable Entity entity, int amount, boolean listening) protected boolean
EvokerEntity.isInSameTeam
(Entity other) protected boolean
IllagerEntity.isInSameTeam
(Entity other) boolean
WardenEntity.isValidTarget
(@Nullable Entity entity) private void
void
MobEntity.lookAtEntity
(Entity targetEntity, float maxYawChange, float maxPitchChange) void
PathAwareEntity.onShortLeashTick
(Entity entity) protected void
void
ShulkerEntity.pushAwayFrom
(Entity entity) void
SlimeEntity.pushAwayFrom
(Entity entity) void
WardenEntity.removeSuspect
(Entity entity) boolean
MobEntity.startRiding
(Entity entity, boolean force) Starts ridingentity
.boolean
PiglinEntity.startRiding
(Entity entity, boolean force) Starts ridingentity
.boolean
ShulkerEntity.startRiding
(Entity entity, boolean force) Starts ridingentity
.(package private) boolean
EndermanEntity.teleportTo
(Entity entity) boolean
CaveSpiderEntity.tryAttack
(ServerWorld world, Entity target) boolean
CreakingEntity.tryAttack
(ServerWorld world, Entity target) boolean
CreeperEntity.tryAttack
(ServerWorld world, Entity target) boolean
HoglinEntity.tryAttack
(ServerWorld world, Entity target) boolean
HuskEntity.tryAttack
(ServerWorld world, Entity target) boolean
MobEntity.tryAttack
(ServerWorld world, Entity target) boolean
RavagerEntity.tryAttack
(ServerWorld world, Entity target) boolean
WardenEntity.tryAttack
(ServerWorld world, Entity target) boolean
WitherSkeletonEntity.tryAttack
(ServerWorld world, Entity target) boolean
ZoglinEntity.tryAttack
(ServerWorld world, Entity target) boolean
ZombieEntity.tryAttack
(ServerWorld world, Entity target) -
Uses of Entity in net.minecraft.entity.passive
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 TypeFieldDescriptionFoxEntity.CHICKEN_AND_RABBIT_FILTER
FoxEntity.JUST_ATTACKED_SOMETHING_FILTER
FoxEntity.NOTICEABLE_PLAYER_FILTER
Modifier and TypeMethodDescriptionMerchantEntity.teleportTo
(TeleportTarget teleportTarget) Teleports this entity to another location, potentially in another world.Modifier and TypeMethodDescriptionvoid
AllayEntity.VibrationCallback.accept
(ServerWorld world, BlockPos pos, RegistryEntry<GameEvent> event, @Nullable Entity sourceEntity, @Nullable Entity entity, float distance) Accepts a game event after delay.boolean
AbstractHorseEntity.beforeLeashTick
(Entity leashHolder, float distance) Called before the default leash-ticking logic.boolean
CamelEntity.beforeLeashTick
(Entity leashHolder, float distance) Called before the default leash-ticking logic.boolean
TameableEntity.beforeLeashTick
(Entity leashHolder, float distance) Called before the default leash-ticking logic.protected boolean
CamelEntity.canAddPassenger
(Entity passenger) Returns whetherentity
can ride this entity.protected boolean
StriderEntity.canAddPassenger
(Entity passenger) Returns whetherentity
can ride this entity.protected boolean
DolphinEntity.canStartRiding
(Entity entity) Returns whether this entity can rideentity
.protected Vec3d
AbstractHorseEntity.getPassengerAttachmentPos
(Entity passenger, EntityDimensions dimensions, float scaleFactor) protected Vec3d
CamelEntity.getPassengerAttachmentPos
(Entity passenger, EntityDimensions dimensions, float scaleFactor) protected Vec3d
LlamaEntity.getPassengerAttachmentPos
(Entity passenger, EntityDimensions dimensions, float scaleFactor) protected Vec3d
StriderEntity.getPassengerAttachmentPos
(Entity passenger, EntityDimensions dimensions, float scaleFactor) static boolean
ParrotEntity.imitateNearbyMob
(World world, Entity parrot) protected boolean
TameableEntity.isInSameTeam
(Entity other) private void
VillagerEntity.notifyDeath
(Entity killer) void
VillagerEntity.onInteractionWith
(EntityInteraction interaction, Entity entity) protected void
protected void
protected void
void
FrogEntity.setFrogTarget
(Entity entity) boolean
BeeEntity.tryAttack
(ServerWorld world, Entity target) boolean
IronGolemEntity.tryAttack
(ServerWorld world, Entity target) boolean
PandaEntity.tryAttack
(ServerWorld world, Entity target) protected void
AbstractHorseEntity.updatePassengerPosition
(Entity passenger, Entity.PositionUpdater positionUpdater) protected void
ChickenEntity.updatePassengerPosition
(Entity passenger, Entity.PositionUpdater positionUpdater) -
Uses of Entity in net.minecraft.entity.player
Modifier and TypeMethodDescriptionvoid
PlayerEntity.addCritParticles
(Entity target) void
PlayerEntity.addEnchantedHitParticles
(Entity target) void
boolean
PlayerEntity.canInteractWithEntity
(Entity entity, double additionalRange) Returns whether the player can interact withentity
.private void
PlayerEntity.collideWithEntity
(Entity entity) static PlayerPosition
PlayerPosition.fromEntity
(Entity entity) static PlayerPosition
PlayerPosition.fromEntityLerpTarget
(Entity entity) protected float
PlayerEntity.getDamageAgainst
(Entity target, float baseDamage, DamageSource damageSource) -
Uses of Entity in net.minecraft.entity.projectile
Modifier and TypeClassDescriptionclass
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
Modifier and TypeFieldDescriptionFishingBobberEntity.hookedEntity
ProjectileEntity.lastDeflectedEntity
ProjectileEntity.owner
ShulkerBulletEntity.target
Modifier and TypeMethodDescriptionProjectileEntity.getEffectCause()
Returns the cause entity of any effect applied by this projectile.FishingBobberEntity.getHookedEntity()
ProjectileEntity.getOwner()
Modifier and TypeMethodDescriptionprotected boolean
protected boolean
protected boolean
protected boolean
protected boolean
protected boolean
boolean
AbstractWindChargeEntity.collidesWith
(Entity other) Returns whether this entity cannot occupy the same space withother
.void
Copies serializable data and nether portal data fromoriginal
.boolean
ProjectileEntity.deflect
(ProjectileDeflection deflection, @Nullable Entity deflector, @Nullable Entity owner, boolean fromAttack) boolean
WindChargeEntity.deflect
(ProjectileDeflection deflection, @Nullable Entity deflector, @Nullable Entity owner, boolean fromAttack) static HitResult
ProjectileUtil.getCollision
(Entity entity, Predicate<Entity> predicate) static HitResult
ProjectileUtil.getCollision
(Entity entity, Predicate<Entity> predicate, double range) static HitResult
ProjectileUtil.getCollision
(Entity entity, Predicate<Entity> predicate, RaycastContext.ShapeType raycastShapeType) private static HitResult
ProjectileUtil.getCollision
(Vec3d pos, Entity entity, Predicate<Entity> predicate, Vec3d velocity, World world, float margin, RaycastContext.ShapeType raycastShapeType) static @Nullable EntityHitResult
ProjectileUtil.getEntityCollision
(World world, Entity entity, Vec3d min, Vec3d max, Box box, Predicate<Entity> predicate) static @Nullable EntityHitResult
ProjectileUtil.getEntityCollision
(World world, Entity entity, Vec3d min, Vec3d max, Box box, Predicate<Entity> predicate, float margin) protected boolean
protected void
ExplosiveProjectileEntity.onDeflected
(@Nullable Entity deflector, boolean fromAttack) protected void
ProjectileEntity.onDeflected
(@Nullable Entity deflector, boolean fromAttack) protected void
FishingBobberEntity.pullHookedEntity
(Entity entity) static @Nullable EntityHitResult
ProjectileUtil.raycast
(Entity entity, Vec3d min, Vec3d max, Box box, Predicate<Entity> predicate, double maxDistance) void
void
void
static void
ProjectileUtil.setRotationFromVelocity
(Entity entity, float delta) void
ProjectileEntity.setVelocity
(Entity shooter, float pitch, float yaw, float roll, float speed, float divergence) Sets velocity and updates rotation accordingly.private void
FishingBobberEntity.updateHookedEntityId
(@Nullable Entity entity) Modifier and TypeMethodDescriptionstatic HitResult
ProjectileUtil.getCollision
(Entity entity, Predicate<Entity> predicate) static HitResult
ProjectileUtil.getCollision
(Entity entity, Predicate<Entity> predicate, double range) static HitResult
ProjectileUtil.getCollision
(Entity entity, Predicate<Entity> predicate, RaycastContext.ShapeType raycastShapeType) private static HitResult
ProjectileUtil.getCollision
(Vec3d pos, Entity entity, Predicate<Entity> predicate, Vec3d velocity, World world, float margin, RaycastContext.ShapeType raycastShapeType) static @Nullable EntityHitResult
ProjectileUtil.getEntityCollision
(World world, Entity entity, Vec3d min, Vec3d max, Box box, Predicate<Entity> predicate) static @Nullable EntityHitResult
ProjectileUtil.getEntityCollision
(World world, Entity entity, Vec3d min, Vec3d max, Box box, Predicate<Entity> predicate, float margin) static @Nullable EntityHitResult
ProjectileUtil.raycast
(Entity entity, Vec3d min, Vec3d max, Box box, Predicate<Entity> predicate, double maxDistance) ModifierConstructorDescriptionAbstractWindChargeEntity
(EntityType<? extends AbstractWindChargeEntity> type, World world, Entity owner, double x, double y, double z) FireworkRocketEntity
(World world, @Nullable Entity entity, double x, double y, double z, ItemStack stack) FireworkRocketEntity
(World world, ItemStack stack, Entity entity, double x, double y, double z, boolean shotAtAngle) ShulkerBulletEntity
(World world, LivingEntity owner, Entity target, Direction.Axis axis) -
Uses of Entity in net.minecraft.entity.projectile.thrown
Modifier and TypeClassDescriptionclass
class
class
class
class
class
class
Modifier and TypeMethodDescriptionEnderPearlEntity.teleportTo
(TeleportTarget teleportTarget) Teleports this entity to another location, potentially in another world.Modifier and TypeMethodDescriptionprivate void
PotionEntity.applySplashPotion
(ServerWorld world, Iterable<StatusEffectInstance> effects, @Nullable Entity entity) private static boolean
EnderPearlEntity.canTeleportEntityTo
(Entity entity, World world) void
-
Uses of Entity in net.minecraft.entity.raid
-
Uses of Entity in net.minecraft.entity.vehicle
Modifier and TypeClassDescriptionclass
class
class
class
class
class
class
class
class
class
class
class
class
class
class
class
Modifier and TypeMethodDescriptionvoid
AbstractBoatEntity.applyLeashElasticity
(Entity leashHolder, float distance) protected boolean
AbstractBoatEntity.canAddPassenger
(Entity passenger) Returns whetherentity
can ride this entity.static boolean
AbstractBoatEntity.canCollide
(Entity entity, Entity other) protected void
AbstractBoatEntity.clampPassengerYaw
(Entity passenger) boolean
AbstractBoatEntity.collidesWith
(Entity other) Returns whether this entity cannot occupy the same space withother
.boolean
AbstractMinecartEntity.collidesWith
(Entity other) Returns whether this entity cannot occupy the same space withother
.protected Vec3d
AbstractBoatEntity.getPassengerAttachmentPos
(Entity passenger, EntityDimensions dimensions, float scaleFactor) protected Vec3d
AbstractMinecartEntity.getPassengerAttachmentPos
(Entity passenger, EntityDimensions dimensions, float scaleFactor) boolean
AbstractBoatEntity.isSmallerThanBoat
(Entity entity) default void
VehicleInventory.onBroken
(DamageSource source, ServerWorld world, Entity vehicle) void
AbstractBoatEntity.onPassengerLookAround
(Entity passenger) void
AbstractBoatEntity.pushAwayFrom
(Entity entity) void
AbstractMinecartEntity.pushAwayFrom
(Entity entity) protected void
AbstractBoatEntity.updatePassengerPosition
(Entity passenger, Entity.PositionUpdater positionUpdater) protected void
MinecartEntity.updatePassengerPosition
(Entity passenger, Entity.PositionUpdater positionUpdater) -
Uses of Entity in net.minecraft.item
Modifier and TypeMethodDescriptionItemStack.getHolder()
Returns the entity that holds the stack, ornull
if inapplicable.Modifier and TypeMethodDescriptionfloat
Item.getBonusAttackDamage
(Entity target, float baseAttackDamage, DamageSource damageSource) float
MaceItem.getBonusAttackDamage
(Entity target, float baseAttackDamage, DamageSource damageSource) private static double
MaceItem.getKnockback
(Entity attacker, LivingEntity attacked, Vec3d distance) private static Predicate
<LivingEntity> MaceItem.getKnockbackPredicate
(Entity attacker, Entity attacked) void
CompassItem.inventoryTick
(ItemStack stack, World world, Entity entity, int slot, boolean selected) Called on both the client and the server every tick if the item is in the player's inventory.void
FilledMapItem.inventoryTick
(ItemStack stack, World world, Entity entity, int slot, boolean selected) Called on both the client and the server every tick if the item is in the player's inventory.void
Item.inventoryTick
(ItemStack stack, World world, Entity entity, int slot, boolean selected) Called on both the client and the server every tick if the item is in the player's inventory.void
ItemStack.inventoryTick
(World world, Entity entity, int slot, boolean selected) private static void
MaceItem.knockbackNearbyEntities
(World world, Entity attacker, Entity attacked) private static void
BundleItem.playDropContentsSound
(World world, Entity entity) private static void
BundleItem.playInsertFailSound
(Entity entity) private static void
BundleItem.playInsertSound
(Entity entity) private static void
BundleItem.playRemoveOneSound
(Entity entity) void
Sets the stack's holder toholder
.void
FilledMapItem.updateColors
(World world, Entity entity, MapState state) -
Uses of Entity in net.minecraft.loot.condition
Modifier and TypeMethodDescriptionprotected boolean
EntityScoresLootCondition.entityScoreIsInRange
(LootContext context, Entity entity, Scoreboard scoreboard, String objectiveName, BoundedIntUnaryOperator range) -
Uses of Entity in net.minecraft.loot.context
Modifier and TypeFieldDescriptionstatic final ContextParameter
<Entity> LootContextParameters.ATTACKING_ENTITY
static final ContextParameter
<Entity> LootContextParameters.DIRECT_ATTACKING_ENTITY
private final ContextParameter
<? extends Entity> LootContext.EntityTarget.parameter
static final ContextParameter
<Entity> LootContextParameters.THIS_ENTITY
Modifier and TypeMethodDescriptionContextParameter
<? extends Entity> LootContext.EntityTarget.getParameter()
ModifierConstructorDescriptionprivate
EntityTarget
(String type, ContextParameter<? extends Entity> parameter) -
Uses of Entity in net.minecraft.network.message
Modifier and TypeMethodDescriptionstatic MessageType.Parameters
MessageType.params
(RegistryKey<MessageType> typeKey, Entity entity) -
Uses of Entity in net.minecraft.network.packet.c2s.play
Modifier and TypeMethodDescriptionPlayerInteractEntityC2SPacket.getEntity
(ServerWorld world) SpectatorTeleportC2SPacket.getTarget
(ServerWorld world) Modifier and TypeMethodDescriptionPlayerInteractEntityC2SPacket.interactAt
(Entity entity, boolean playerSneaking, Hand hand, Vec3d pos) ModifierConstructorDescriptionClientCommandC2SPacket
(Entity entity, ClientCommandC2SPacket.Mode mode) ClientCommandC2SPacket
(Entity entity, ClientCommandC2SPacket.Mode mode, int mountJumpHeight) VehicleMoveC2SPacket
(Entity entity) -
Uses of Entity in net.minecraft.network.packet.s2c.play
Modifier and TypeMethodDescriptionModifierConstructorDescriptionEntityAnimationS2CPacket
(Entity entity, int animationId) EntityAttachS2CPacket
(Entity attachedEntity, @Nullable Entity holdingEntity) EntityDamageS2CPacket
(Entity entity, DamageSource damageSource) EntityPassengersSetS2CPacket
(Entity entity) EntitySetHeadYawS2CPacket
(Entity entity, byte headYaw) EntitySpawnS2CPacket
(Entity entity, int entityData, BlockPos pos) EntitySpawnS2CPacket
(Entity entity, EntityTrackerEntry entityTrackerEntry) EntitySpawnS2CPacket
(Entity entity, EntityTrackerEntry entityTrackerEntry, int entityData) EntityStatusS2CPacket
(Entity entity, byte status) EntityVelocityUpdateS2CPacket
(Entity entity) LookAtS2CPacket
(EntityAnchorArgumentType.EntityAnchor selfAnchor, Entity entity, EntityAnchorArgumentType.EntityAnchor targetAnchor) PlaySoundFromEntityS2CPacket
(RegistryEntry<SoundEvent> sound, SoundCategory category, Entity entity, float volume, float pitch, long seed) SetCameraEntityS2CPacket
(Entity entity) VehicleMoveS2CPacket
(Entity entity) -
Uses of Entity in net.minecraft.predicate
Modifier and TypeMethodDescriptionstatic NbtCompound
NbtPredicate.entityToNbt
(Entity entity) boolean
-
Uses of Entity in net.minecraft.predicate.entity
Modifier and TypeFieldDescriptionEntityPredicates.CAN_COLLIDE
EntityPredicates.CAN_HIT
EntityPredicates.EXCEPT_CREATIVE_OR_SPECTATOR
EntityPredicates.EXCEPT_SPECTATOR
EntityPredicates.NOT_MOUNTED
Tests if an entity is not mounted.EntityPredicates.VALID_ENTITY
Tests if an entity is valid.EntityPredicates.VALID_INVENTORIES
Tests if an entity has a valid inventory.EntityPredicates.VALID_LIVING_ENTITY
Tests if a living entity is valid.(package private) final Function
<Entity, Optional<RegistryEntry<V>>> EntitySubPredicateTypes.DynamicVariantType.variantGetter
EntitySubPredicateTypes.VariantType.variantGetter
Modifier and TypeMethodDescriptionEntityPredicates.canBePushedBy
(Entity entity) EntityPredicates.maxDistance
(double x, double y, double z, double max) Modifier and TypeMethodDescriptionEntityPredicates.canBePushedBy
(Entity entity) static LootContext
EntityPredicate.createAdvancementEntityLootContext
(ServerPlayerEntity player, Entity target) boolean
private static boolean
SlotsPredicate.matches
(Entity entity, ItemPredicate itemPredicate, IntList slotIds) boolean
boolean
boolean
boolean
EntityPredicate.test
(ServerPlayerEntity player, @Nullable Entity entity) boolean
boolean
EntitySubPredicate.test
(Entity entity, ServerWorld world, @Nullable Vec3d pos) boolean
EntitySubPredicateTypes.DynamicVariantType.DynamicPredicate.test
(Entity entity, ServerWorld world, @Nullable Vec3d pos) boolean
EntitySubPredicateTypes.VariantType.VariantPredicate.test
(Entity entity, ServerWorld world, @Nullable Vec3d pos) boolean
FishingHookPredicate.test
(Entity entity, ServerWorld world, @Nullable Vec3d pos) boolean
LightningBoltPredicate.test
(Entity entity, ServerWorld world, @Nullable Vec3d pos) boolean
PlayerPredicate.test
(Entity entity, ServerWorld world, @Nullable Vec3d pos) boolean
RaiderPredicate.test
(Entity entity, ServerWorld world, @Nullable Vec3d pos) boolean
SheepPredicate.test
(Entity entity, ServerWorld world, @Nullable Vec3d pos) boolean
SlimePredicate.test
(Entity entity, ServerWorld world, @Nullable Vec3d pos) Modifier and TypeMethodDescriptionstatic <V> EntitySubPredicateTypes.DynamicVariantType
<V> EntitySubPredicateTypes.DynamicVariantType.create
(RegistryKey<? extends Registry<V>> registryRef, Function<Entity, Optional<RegistryEntry<V>>> variantGetter) static <V> EntitySubPredicateTypes.VariantType
<V> EntitySubPredicateTypes.VariantType.create
(com.mojang.serialization.Codec<V> codec, Function<Entity, Optional<V>> variantGetter) static <V> EntitySubPredicateTypes.VariantType
<V> EntitySubPredicateTypes.VariantType.create
(Registry<V> registry, Function<Entity, Optional<V>> variantGetter) ModifierConstructorDescriptionDynamicVariantType
(RegistryKey<? extends Registry<V>> registryRef, Function<Entity, Optional<RegistryEntry<V>>> variantGetter) VariantType
(com.mojang.serialization.Codec<V> variantCodec, Function<Entity, Optional<V>> variantGetter) -
Uses of Entity in net.minecraft.scoreboard
-
Uses of Entity in net.minecraft.server.command
Modifier and TypeFieldDescriptionprivate final Entity
LookTarget.LookAtEntity.entity
The field for theentity
record component.ServerCommandSource.entity
Modifier and TypeMethodDescriptionLookTarget.LookAtEntity.entity()
Returns the value of theentity
record component.ServerCommandSource.getEntity()
Gets the entity from this command source or returns null if this command source is not an entity.ServerCommandSource.getEntityOrThrow()
Gets the entity from this command source or throws a command syntax exception if this command source is not an entity.static Entity
SummonCommand.summon
(ServerCommandSource source, RegistryEntry.Reference<EntityType<?>> entityType, Vec3d pos, NbtCompound nbt, boolean initialize) Modifier and TypeMethodDescriptionprivate static int
DamageCommand.execute
(ServerCommandSource source, Entity target, float amount, DamageSource damageSource) private static int
SpectateCommand.execute
(ServerCommandSource source, @Nullable Entity entity, ServerPlayerEntity player) private static void
TeamMsgCommand.execute
(ServerCommandSource source, Entity entity, Team team, List<ServerPlayerEntity> recipients, SignedMessage message) private static int
TeleportCommand.execute
(ServerCommandSource source, Collection<? extends Entity> targets, Entity destination) private static int
AttributeCommand.executeBaseValueGet
(ServerCommandSource source, Entity target, RegistryEntry<EntityAttribute> attribute, double multiplier) private static int
AttributeCommand.executeBaseValueSet
(ServerCommandSource source, Entity target, RegistryEntry<EntityAttribute> attribute, double value) private static int
ItemCommand.executeBlockCopyEntity
(ServerCommandSource source, Entity sourceEntity, int sourceSlot, BlockPos pos, int slot) private static int
ItemCommand.executeBlockCopyEntity
(ServerCommandSource source, Entity sourceEntity, int sourceSlot, BlockPos pos, int slot, RegistryEntry<LootFunction> lootFunction) private static int
RideCommand.executeDismount
(ServerCommandSource source, Entity rider) private static int
ItemCommand.executeEntityCopyEntity
(ServerCommandSource source, Entity sourceEntity, int sourceSlot, Collection<? extends Entity> targets, int slot) private static int
ItemCommand.executeEntityCopyEntity
(ServerCommandSource source, Entity sourceEntity, int sourceSlot, Collection<? extends Entity> targets, int slot, RegistryEntry<LootFunction> lootFunction) private static int
LootCommand.executeKill
(com.mojang.brigadier.context.CommandContext<ServerCommandSource> context, Entity entity, LootCommand.Target constructor) private static int
AttributeCommand.executeModifierAdd
(ServerCommandSource source, Entity target, RegistryEntry<EntityAttribute> attribute, Identifier id, double value, EntityAttributeModifier.Operation operation) private static int
AttributeCommand.executeModifierRemove
(ServerCommandSource source, Entity target, RegistryEntry<EntityAttribute> attribute, Identifier id) private static int
AttributeCommand.executeModifierValueGet
(ServerCommandSource source, Entity target, RegistryEntry<EntityAttribute> attribute, Identifier id, double multiplier) private static int
RideCommand.executeMount
(ServerCommandSource source, Entity rider, Entity vehicle) private static int
AttributeCommand.executeValueGet
(ServerCommandSource source, Entity target, RegistryEntry<EntityAttribute> attribute, double multiplier) private static EntityAttributeInstance
AttributeCommand.getAttributeInstance
(Entity entity, RegistryEntry<EntityAttribute> attribute) private static LivingEntity
AttributeCommand.getLivingEntity
(Entity entity) private static LivingEntity
AttributeCommand.getLivingEntityWithAttribute
(Entity entity, RegistryEntry<EntityAttribute> attribute) private static ItemStack
ItemCommand.getStackInSlot
(Entity entity, int slotId) void
LookTarget.look
(ServerCommandSource source, Entity entity) void
LookTarget.LookAtEntity.look
(ServerCommandSource source, Entity entity) void
LookTarget.LookAtPosition.look
(ServerCommandSource source, Entity entity) private static void
LootCommand.replace
(Entity entity, List<ItemStack> stacks, int slot, int stackCount, List<ItemStack> addedStacks) private static int
RotateCommand.rotateFacingLookTarget
(ServerCommandSource source, Entity entity, LookTarget lookTarget) private static int
RotateCommand.rotateToPos
(ServerCommandSource source, Entity entity, PosArgument pos) private static void
TeleportCommand.teleport
(ServerCommandSource source, Entity target, ServerWorld world, double x, double y, double z, Set<PositionFlag> movementFlags, float yaw, float pitch, @Nullable LookTarget facingLocation) ServerCommandSource.withEntity
(Entity entity) ServerCommandSource.withLookingAt
(Entity entity, EntityAnchorArgumentType.EntityAnchor anchor) Modifier and TypeMethodDescriptionprivate static int
ExecuteCommand.countMatchingItems
(Iterable<? extends Entity> entities, SlotRange slotRange, Predicate<ItemStack> predicate) private static com.mojang.brigadier.RedirectModifier
<ServerCommandSource> ExecuteCommand.createEntityModifier
(Function<Entity, Optional<Entity>> function) private static com.mojang.brigadier.RedirectModifier
<ServerCommandSource> ExecuteCommand.createEntityModifier
(Function<Entity, Optional<Entity>> function) private static com.mojang.brigadier.RedirectModifier
<ServerCommandSource> ExecuteCommand.createMultiEntityModifier
(Function<Entity, Stream<Entity>> function) private static com.mojang.brigadier.RedirectModifier
<ServerCommandSource> ExecuteCommand.createMultiEntityModifier
(Function<Entity, Stream<Entity>> function) private static int
EnchantCommand.execute
(ServerCommandSource source, Collection<? extends Entity> targets, RegistryEntry<Enchantment> enchantment, int level) private static int
KillCommand.execute
(ServerCommandSource source, Collection<? extends Entity> targets) private static int
SpreadPlayersCommand.execute
(ServerCommandSource source, Vec2f center, float spreadDistance, float maxRange, int maxY, boolean respectTeams, Collection<? extends Entity> players) private static int
TeleportCommand.execute
(ServerCommandSource source, Collection<? extends Entity> targets, Entity destination) private static int
TeleportCommand.execute
(ServerCommandSource source, Collection<? extends Entity> targets, ServerWorld world, PosArgument location, @Nullable PosArgument rotation, @Nullable LookTarget facingLocation) private static int
TagCommand.executeAdd
(ServerCommandSource source, Collection<? extends Entity> targets, String tag) private static int
EffectCommand.executeClear
(ServerCommandSource source, Collection<? extends Entity> targets) private static int
EffectCommand.executeClear
(ServerCommandSource source, Collection<? extends Entity> targets, RegistryEntry<StatusEffect> statusEffect) private static int
ItemCommand.executeEntityCopyBlock
(ServerCommandSource source, BlockPos sourcePos, int sourceSlot, Collection<? extends Entity> targets, int slot) private static int
ItemCommand.executeEntityCopyBlock
(ServerCommandSource source, BlockPos sourcePos, int sourceSlot, Collection<? extends Entity> targets, int slot, RegistryEntry<LootFunction> lootFunction) private static int
ItemCommand.executeEntityCopyEntity
(ServerCommandSource source, Entity sourceEntity, int sourceSlot, Collection<? extends Entity> targets, int slot) private static int
ItemCommand.executeEntityCopyEntity
(ServerCommandSource source, Entity sourceEntity, int sourceSlot, Collection<? extends Entity> targets, int slot, RegistryEntry<LootFunction> lootFunction) private static int
ItemCommand.executeEntityModify
(ServerCommandSource source, Collection<? extends Entity> targets, int slot, RegistryEntry<LootFunction> lootFunction) private static int
ItemCommand.executeEntityReplace
(ServerCommandSource source, Collection<? extends Entity> targets, int slot, ItemStack stack) private static int
EffectCommand.executeGive
(ServerCommandSource source, Collection<? extends Entity> targets, RegistryEntry<StatusEffect> statusEffect, @Nullable Integer seconds, int amplifier, boolean showParticles) private static int
TagCommand.executeList
(ServerCommandSource source, Collection<? extends Entity> targets) private static int
TagCommand.executeRemove
(ServerCommandSource source, Collection<? extends Entity> targets, String tag) private static int
LootCommand.executeReplace
(Collection<? extends Entity> targets, int slot, int stackCount, List<ItemStack> stacks, LootCommand.FeedbackMessage messageSender) private static double
SpreadPlayersCommand.getMinDistance
(Collection<? extends Entity> entities, ServerWorld world, SpreadPlayersCommand.Pile[] piles, int maxY, boolean respectTeams) private static int
SpreadPlayersCommand.getPileCountRespectingTeams
(Collection<? extends Entity> entities) private static Collection
<String> TagCommand.getTags
(Collection<? extends Entity> entities) ModifierConstructorDescriptionLookAtEntity
(Entity entity, EntityAnchorArgumentType.EntityAnchor entityAnchor) ServerCommandSource
(CommandOutput output, Vec3d pos, Vec2f rot, ServerWorld world, int level, String name, Text displayName, MinecraftServer server, @Nullable Entity entity) protected
ServerCommandSource
(CommandOutput output, Vec3d pos, Vec2f rot, ServerWorld world, int level, String name, Text displayName, MinecraftServer server, @Nullable Entity entity, boolean silent, ReturnValueConsumer resultStorer, EntityAnchorArgumentType.EntityAnchor entityAnchor, SignedCommandArguments signedArguments, FutureQueue messageChainTaskQueue) -
Uses of Entity in net.minecraft.server.network
Modifier and TypeFieldDescriptionServerPlayerEntity.cameraEntity
private final Entity
EntityTrackerEntry.entity
ServerPlayNetworkHandler.topmostRiddenEntity
Modifier and TypeMethodDescriptionEntityTrackerEntry.streamChangedPassengers
(List<Entity> passengers, List<Entity> lastPassengers) Modifier and TypeMethodDescriptionvoid
ServerPlayerEntity.addCritParticles
(Entity target) void
ServerPlayerEntity.addEnchantedHitParticles
(Entity target) void
protected float
ServerPlayerEntity.getDamageAgainst
(Entity target, float baseDamage, DamageSource damageSource) private int
ServerPlayNetworkHandler.getMaxAllowedFloatingTicks
(Entity vehicle) private boolean
ServerPlayNetworkHandler.isEntityOnAir
(Entity entity) void
ServerPlayerEntity.lookAtEntity
(EntityAnchorArgumentType.EntityAnchor anchorPoint, Entity targetEntity, EntityAnchorArgumentType.EntityAnchor targetAnchor) void
ServerPlayerEntity.onExplodedBy
(@Nullable Entity entity) protected void
ServerPlayerEntity.onStatusEffectApplied
(StatusEffectInstance effect, @Nullable Entity source) protected void
ServerPlayerEntity.onStatusEffectUpgraded
(StatusEffectInstance effect, boolean reapplyEffect, @Nullable Entity source) ServerPlayNetworkHandler.Interaction.run
(ServerPlayerEntity player, Entity entity, Hand hand) void
ServerPlayerEntity.sendPickup
(Entity item, int count) void
ServerPlayerEntity.setCameraEntity
(@Nullable Entity entity) boolean
ServerPlayerEntity.startRiding
(Entity entity, boolean force) Starts ridingentity
.void
ServerPlayerEntity.updateKilledAdvancementCriterion
(Entity entityKilled, int score, DamageSource damageSource) Modifier and TypeMethodDescriptionEntityTrackerEntry.streamChangedPassengers
(List<Entity> passengers, List<Entity> lastPassengers) ModifierConstructorDescriptionEntityTrackerEntry
(ServerWorld world, Entity entity, int tickInterval, boolean alwaysUpdateVelocity, Consumer<Packet<?>> receiver) -
Uses of Entity in net.minecraft.server.world
Modifier and TypeFieldDescription(package private) final Entity
ServerChunkLoadingManager.EntityTracker.entity
Modifier and TypeFieldDescriptionprivate final ServerEntityManager
<Entity> ServerWorld.entityManager
Modifier and TypeMethodDescription<T extends Entity>
voidServerWorld.collectEntitiesByType
(TypeFilter<Entity, T> filter, Predicate<? super T> predicate, List<? super T> result) <T extends Entity>
voidServerWorld.collectEntitiesByType
(TypeFilter<Entity, T> filter, Predicate<? super T> predicate, List<? super T> result, int limit) Collects entities of the given type, up tolimit
.ServerWorld.getEntitiesByType
(TypeFilter<Entity, T> filter, Predicate<? super T> predicate) Computes a list of entities of the given type.Modifier and TypeMethodDescriptionServerWorld.getDragonPart
(int id) Deprecated.Returns the entity using the UUID, ornull
if none was found.ServerWorld.getEntityById
(int id) Returns the entity using the entity ID, ornull
if none was found.Modifier and TypeMethodDescriptionprotected EntityLookup
<Entity> ServerWorld.getEntityLookup()
ServerWorld.iterateEntities()
Modifier and TypeMethodDescriptionprivate boolean
void
void
ServerWorld.createExplosion
(@Nullable Entity entity, @Nullable DamageSource damageSource, @Nullable ExplosionBehavior behavior, double x, double y, double z, float power, boolean createFire, World.ExplosionSourceType explosionSourceType, ParticleEffect smallParticle, ParticleEffect largeParticle, RegistryEntry<SoundEvent> soundEvent) Creates an explosion.void
private static double
ServerChunkLoadingManager.getSquaredDistance
(ChunkPos pos, Entity entity) void
ServerWorld.handleInteraction
(EntityInteraction interaction, Entity entity, InteractionObserver observer) protected void
ServerChunkLoadingManager.loadEntity
(Entity entity) void
ServerChunkManager.loadEntity
(Entity entity) void
ServerWorld.onDimensionChanged
(Entity entity) Called on the destination world when an entity changed the dimension.void
ServerWorld.playSoundFromEntity
(@Nullable PlayerEntity source, Entity entity, RegistryEntry<SoundEvent> sound, SoundCategory category, float volume, float pitch, long seed) void
ServerWorld.sendEntityDamage
(Entity entity, DamageSource damageSource) void
ServerWorld.sendEntityStatus
(Entity entity, byte status) Sends the entity status to nearby players.protected void
ServerChunkLoadingManager.sendToNearbyPlayers
(Entity entity, Packet<?> packet) void
ServerChunkManager.sendToNearbyPlayers
(Entity entity, Packet<?> packet) void
ServerChunkLoadingManager.sendToOtherNearbyPlayers
(Entity entity, Packet<?> packet) void
ServerChunkManager.sendToOtherNearbyPlayers
(Entity entity, Packet<?> packet) boolean
ServerWorld.spawnEntity
(Entity entity) Spawns an entity.boolean
ServerWorld.spawnNewEntityAndPassengers
(Entity entity) Checks whether any of the entity and its passengers already exist in the world, and if not, spawns the entity with its passengers.void
ServerWorld.ServerEntityHandler.startTicking
(Entity entity) void
ServerWorld.ServerEntityHandler.startTracking
(Entity entity) void
ServerWorld.ServerEntityHandler.stopTicking
(Entity entity) void
ServerWorld.ServerEntityHandler.stopTracking
(Entity entity) void
ServerWorld.tickEntity
(Entity entity) private void
ServerWorld.tickPassenger
(Entity vehicle, Entity passenger) boolean
ServerWorld.tryLoadEntity
(Entity entity) protected void
ServerChunkLoadingManager.unloadEntity
(Entity entity) void
ServerChunkManager.unloadEntity
(Entity entity) void
ServerWorld.ServerEntityHandler.updateLoadStatus
(Entity entity) Modifier and TypeMethodDescriptionvoid
ServerWorld.addEntities
(Stream<Entity> entities) <T extends Entity>
voidServerWorld.collectEntitiesByType
(TypeFilter<Entity, T> filter, Predicate<? super T> predicate, List<? super T> result) <T extends Entity>
voidServerWorld.collectEntitiesByType
(TypeFilter<Entity, T> filter, Predicate<? super T> predicate, List<? super T> result, int limit) Collects entities of the given type, up tolimit
.private static void
ServerWorld.dumpEntities
(Writer writer, Iterable<Entity> entities) ServerWorld.getEntitiesByType
(TypeFilter<Entity, T> filter, Predicate<? super T> predicate) Computes a list of entities of the given type.void
ServerWorld.loadEntities
(Stream<Entity> entities) ModifierConstructorDescriptionEntityTracker
(Entity entity, int maxDistance, int tickInterval, boolean alwaysUpdateVelocity) -
Uses of Entity in net.minecraft.structure
Modifier and TypeMethodDescriptionStructureTemplate.getEntity
(ServerWorldAccess world, NbtCompound nbt) -
Uses of Entity in net.minecraft.test
Modifier and TypeMethodDescription<E extends Entity>
ETestContext.expectEntity
(EntityType<E> type, int x, int y, int z, double margin) <E extends Entity,
T>
voidTestContext.expectEntity
(BlockPos pos, EntityType<E> type, Predicate<E> predicate) <E extends Entity>
ETestContext.expectEntityAtOrigin
(EntityType<E> type) <E extends Entity,
T>
voidTestContext.expectEntityWithData
(BlockPos pos, EntityType<E> type, Function<? super E, T> entityDataGetter, T data) <E extends Entity,
T>
voidTestContext.expectEntityWithDataEnd
(BlockPos pos, EntityType<E> type, Function<E, T> entityDataGetter, T data) <E extends Entity & InventoryOwner>
voidTestContext.expectEntityWithItem
(BlockPos pos, EntityType<E> entityType, Item item) TestContext.getEntities
(EntityType<T> type) TestContext.getEntitiesAround
(EntityType<E> type, int x, int y, int z, double margin) TestContext.getEntitiesAround
(EntityType<E> type, Vec3d pos, double margin) TestContext.getEntitiesAround
(EntityType<T> type, BlockPos pos, double radius) <E extends Entity>
ETestContext.spawnEntity
(EntityType<E> type, float x, float y, float z) <E extends Entity>
ETestContext.spawnEntity
(EntityType<E> type, int x, int y, int z) <E extends Entity>
ETestContext.spawnEntity
(EntityType<E> type, BlockPos pos) <E extends Entity>
ETestContext.spawnEntity
(EntityType<E> type, Vec3d pos) <E extends Entity>
voidTestContext.testEntity
(E entity, Predicate<E> predicate, String testName) <E extends Entity,
T>
voidTestContext.testEntityProperty
(E entity, Function<E, T> propertyGetter, String propertyName, T expectedValue) Modifier and TypeMethodDescriptionvoid
TestContext.damage
(Entity entity, DamageSource damageSource, float amount) void
TestContext.expectEntityAt
(Entity entity, int x, int y, int z) void
TestContext.expectEntityAt
(Entity entity, BlockPos pos) void
TestContext.expectEntityIn
(Entity entity, Box box, String message) StructureTestUtil.findTargetedStructureBlock
(BlockPos pos, Entity entity, ServerWorld world) void
TestContext.killEntity
(Entity entity) void
TestContext.throwPositionedException
(String message, Entity entity) -
Uses of Entity in net.minecraft.text
Modifier and TypeMethodDescriptionNbtTextContent.parse
(@Nullable ServerCommandSource source, @Nullable Entity sender, int depth) Parses this content into a basic mutable text without custom style or siblings.ScoreTextContent.parse
(@Nullable ServerCommandSource source, @Nullable Entity sender, int depth) Parses this content into a basic mutable text without custom style or siblings.SelectorTextContent.parse
(@Nullable ServerCommandSource source, @Nullable Entity sender, int depth) Parses this content into a basic mutable text without custom style or siblings.default MutableText
TextContent.parse
(@Nullable ServerCommandSource source, @Nullable Entity sender, int depth) Parses this content into a basic mutable text without custom style or siblings.static Optional
<MutableText> Texts.parse
(@Nullable ServerCommandSource source, Optional<Text> text, @Nullable Entity sender, int depth) static MutableText
TranslatableTextContent.parse
(@Nullable ServerCommandSource source, @Nullable Entity sender, int depth) Parses this content into a basic mutable text without custom style or siblings.private static Style
Texts.parseStyle
(@Nullable ServerCommandSource source, Style style, @Nullable Entity sender, int depth) -
Uses of Entity in net.minecraft.util
-
Uses of Entity in net.minecraft.util.hit
ModifierConstructorDescriptionEntityHitResult
(Entity entity) EntityHitResult
(Entity entity, Vec3d pos) -
Uses of Entity in net.minecraft.util.math
Modifier and TypeMethodDescriptionstatic Direction[]
Direction.getEntityFacingOrder
(Entity entity) static Direction
Direction.getLookDirectionForAxis
(Entity entity, Direction.Axis axis) -
Uses of Entity in net.minecraft.village
Modifier and TypeMethodDescriptionCreates a trade offer.Creates a trade offer.Creates a trade offer.Creates a trade offer.Creates a trade offer.Creates a trade offer.Creates a trade offer.Creates a trade offer.Creates a trade offer.Creates a trade offer.Creates a trade offer.Creates a trade offer.Creates a trade offer. -
Uses of Entity in net.minecraft.village.raid
-
Uses of Entity in net.minecraft.world
Modifier and TypeFieldDescriptionprivate Int2ObjectMap
<Entity> EntityList.entities
private @Nullable Int2ObjectMap
<Entity> EntityList.iterating
private Int2ObjectMap
<Entity> EntityList.temp
Modifier and TypeMethodDescription<T extends Entity>
voidWorld.collectEntitiesByType
(TypeFilter<Entity, T> filter, Box box, Predicate<? super T> predicate, List<? super T> result) <T extends Entity>
voidWorld.collectEntitiesByType
(TypeFilter<Entity, T> filter, Box box, Predicate<? super T> predicate, List<? super T> result, int limit) Collects entities of the given type inbox
, up tolimit
.EntityView.getEntitiesByClass
(Class<T> entityClass, Box box, Predicate<? super T> predicate) Computes a list of entities within some box whose runtime Java class is the same as or is a subclass of the given class.ChunkRegion.getEntitiesByType
(TypeFilter<Entity, T> filter, Box box, Predicate<? super T> predicate) EntityView.getEntitiesByType
(TypeFilter<Entity, T> filter, Box box, Predicate<? super T> predicate) World.getEntitiesByType
(TypeFilter<Entity, T> filter, Box box, Predicate<? super T> predicate) EntityView.getNonSpectatingEntities
(Class<T> entityClass, Box box) <T extends Entity>
voidWorld.tickEntity
(Consumer<T> tickConsumer, T entity) Modifier and TypeMethodDescriptionWorld.getEntityById
(int id) Returns the entity using the entity ID, ornull
if none was found.Modifier and TypeMethodDescriptionprotected abstract EntityLookup
<Entity> World.getEntityLookup()
ChunkRegion.getOtherEntities
(@Nullable Entity except, Box box, @Nullable Predicate<? super Entity> predicate) Computes a list of entities within some box, excluding the given entity, that satisfy the given predicate.EntityView.getOtherEntities
(@Nullable Entity except, Box box) Computes a list of entities within some box, excluding the given entity, that are not spectators.Computes a list of entities within some box, excluding the given entity, that satisfy the given predicate.Computes a list of entities within some box, excluding the given entity, that satisfy the given predicate.Modifier and TypeMethodDescriptionvoid
private static void
TeleportTarget.addPortalChunkTicket
(Entity entity) boolean
ChunkRegion.breakBlock
(BlockPos pos, boolean drop, @Nullable Entity breakingEntity, int maxUpdateDepth) Removes the block and replaces it with the fluid occupying the block (such as water inside kelp), or air if it does not exist.default boolean
ModifiableWorld.breakBlock
(BlockPos pos, boolean drop, @Nullable Entity breakingEntity) Removes the block and replaces it with the fluid occupying the block (such as water inside kelp), or air if it does not exist.boolean
ModifiableWorld.breakBlock
(BlockPos pos, boolean drop, @Nullable Entity breakingEntity, int maxUpdateDepth) Removes the block and replaces it with the fluid occupying the block (such as water inside kelp), or air if it does not exist.boolean
World.breakBlock
(BlockPos pos, boolean drop, @Nullable Entity breakingEntity, int maxUpdateDepth) Removes the block and replaces it with the fluid occupying the block (such as water inside kelp), or air if it does not exist.default boolean
CollisionView.canCollide
(@Nullable Entity entity, Box box) void
World.createExplosion
(@Nullable Entity entity, double x, double y, double z, float power, boolean createFire, World.ExplosionSourceType explosionSourceType) Creates an explosion.void
World.createExplosion
(@Nullable Entity entity, double x, double y, double z, float power, World.ExplosionSourceType explosionSourceType) Creates an explosion without creating fire.void
World.createExplosion
(@Nullable Entity entity, @Nullable DamageSource damageSource, @Nullable ExplosionBehavior behavior, double x, double y, double z, float power, boolean createFire, World.ExplosionSourceType explosionSourceType) abstract void
World.createExplosion
(@Nullable Entity entity, @Nullable DamageSource damageSource, @Nullable ExplosionBehavior behavior, double x, double y, double z, float power, boolean createFire, World.ExplosionSourceType explosionSourceType, ParticleEffect smallParticle, ParticleEffect largeParticle, RegistryEntry<SoundEvent> soundEvent) Creates an explosion.void
World.createExplosion
(@Nullable Entity entity, @Nullable DamageSource damageSource, @Nullable ExplosionBehavior behavior, Vec3d pos, float power, boolean createFire, World.ExplosionSourceType explosionSourceType) Creates an explosion.default boolean
CollisionView.doesNotIntersectEntities
(@Nullable Entity except, VoxelShape shape) Returnstrue
ifshape
does not intersect with non-spectator entities exceptexcept
.default boolean
CollisionView.doesNotIntersectEntities
(Entity entity) default boolean
EntityView.doesNotIntersectEntities
(@Nullable Entity except, VoxelShape shape) Returnstrue
ifshape
does not intersect with non-spectator entities exceptexcept
.default boolean
RegistryWorldView.doesNotIntersectEntities
(@Nullable Entity except, VoxelShape shape) Returnstrue
ifshape
does not intersect with non-spectator entities exceptexcept
.default void
WorldAccess.emitGameEvent
(@Nullable Entity entity, RegistryEntry<GameEvent> event, BlockPos pos) default void
WorldAccess.emitGameEvent
(@Nullable Entity entity, RegistryEntry<GameEvent> event, Vec3d pos) CollisionView.findClosestCollision
(@Nullable Entity entity, VoxelShape shape, Vec3d target, double x, double y, double z) CollisionView.findSupportingBlockPos
(Entity entity, Box box) default Iterable
<VoxelShape> CollisionView.getBlockCollisions
(@Nullable Entity entity, Box box) default Iterable
<VoxelShape> CollisionView.getBlockOrFluidCollisions
(@Nullable Entity entity, Box box) default @Nullable PlayerEntity
EntityView.getClosestPlayer
(Entity entity, double maxDistance) default Iterable
<VoxelShape> CollisionView.getCollisions
(@Nullable Entity entity, Box box) CollisionView.getEntityCollisions
(@Nullable Entity entity, Box box) default List
<VoxelShape> EntityView.getEntityCollisions
(@Nullable Entity entity, Box box) default List
<VoxelShape> RegistryWorldView.getEntityCollisions
(@Nullable Entity entity, Box box) ChunkRegion.getOtherEntities
(@Nullable Entity except, Box box, @Nullable Predicate<? super Entity> predicate) Computes a list of entities within some box, excluding the given entity, that satisfy the given predicate.EntityView.getOtherEntities
(@Nullable Entity except, Box box) Computes a list of entities within some box, excluding the given entity, that are not spectators.Computes a list of entities within some box, excluding the given entity, that satisfy the given predicate.Computes a list of entities within some box, excluding the given entity, that satisfy the given predicate.private @Nullable VoxelShape
CollisionView.getWorldBorderCollisions
(Entity entity, Box box) private static Vec3d
TeleportTarget.getWorldSpawnPos
(ServerWorld world, Entity entity) boolean
default boolean
CollisionView.isBlockSpaceEmpty
(@Nullable Entity entity, Box box) boolean
World.isDirectionSolid
(BlockPos pos, Entity entity, Direction direction) default boolean
CollisionView.isSpaceEmpty
(@Nullable Entity entity, Box box) default boolean
CollisionView.isSpaceEmpty
(@Nullable Entity entity, Box box, boolean checkFluid) default boolean
CollisionView.isSpaceEmpty
(Entity entity) boolean
World.isTopSolid
(BlockPos pos, Entity entity) static TeleportTarget
TeleportTarget.missingSpawnBlock
(ServerWorld world, Entity entity, TeleportTarget.PostDimensionTransition postDimensionTransition) void
TeleportTarget.PostDimensionTransition.onTransition
(Entity entity) void
World.playSound
(@Nullable Entity source, BlockPos pos, SoundEvent sound, SoundCategory category, float volume, float pitch) void
World.playSoundFromEntity
(Entity entity, SoundEvent sound, SoundCategory category, float volume, float pitch) abstract void
World.playSoundFromEntity
(@Nullable PlayerEntity source, Entity entity, RegistryEntry<SoundEvent> sound, SoundCategory category, float volume, float pitch, long seed) void
World.playSoundFromEntity
(@Nullable PlayerEntity source, Entity entity, SoundEvent sound, SoundCategory category, float volume, float pitch) void
void
World.sendEntityDamage
(Entity entity, DamageSource damageSource) void
World.sendEntityStatus
(Entity entity, byte status) Sends the entity status to nearby players.private static void
TeleportTarget.sendTravelThroughPortalPacket
(Entity entity) boolean
World.shouldUpdatePostDeath
(Entity entity) boolean
ChunkRegion.spawnEntity
(Entity entity) Spawns an entity.default boolean
ModifiableWorld.spawnEntity
(Entity entity) Spawns an entity.default void
ServerWorldAccess.spawnEntityAndPassengers
(Entity entity) Spawns an entity and all its passengers (recursively) into the world.Modifier and TypeMethodDescription<T extends Entity>
voidWorld.collectEntitiesByType
(TypeFilter<Entity, T> filter, Box box, Predicate<? super T> predicate, List<? super T> result) <T extends Entity>
voidWorld.collectEntitiesByType
(TypeFilter<Entity, T> filter, Box box, Predicate<? super T> predicate, List<? super T> result, int limit) Collects entities of the given type inbox
, up tolimit
.void
Runs anaction
on every entity in this storage.ChunkRegion.getClosestPlayer
(double x, double y, double z, double maxDistance, Predicate<Entity> targetPredicate) default @Nullable PlayerEntity
EntityView.getClosestPlayer
(double x, double y, double z, double maxDistance, @Nullable Predicate<Entity> targetPredicate) ChunkRegion.getEntitiesByType
(TypeFilter<Entity, T> filter, Box box, Predicate<? super T> predicate) EntityView.getEntitiesByType
(TypeFilter<Entity, T> filter, Box box, Predicate<? super T> predicate) World.getEntitiesByType
(TypeFilter<Entity, T> filter, Box box, Predicate<? super T> predicate) ChunkRegion.getOtherEntities
(@Nullable Entity except, Box box, @Nullable Predicate<? super Entity> predicate) Computes a list of entities within some box, excluding the given entity, that satisfy the given predicate.Computes a list of entities within some box, excluding the given entity, that satisfy the given predicate.Computes a list of entities within some box, excluding the given entity, that satisfy the given predicate.static SpawnHelper.Info
SpawnHelper.setupSpawn
(int spawningChunkCount, Iterable<Entity> entities, SpawnHelper.ChunkSource chunkSource, SpawnDensityCapper densityCapper) ModifierConstructorDescriptionBlockCollisionSpliterator
(CollisionView world, @Nullable Entity entity, Box box, boolean forEntity, BiFunction<BlockPos.Mutable, VoxelShape, T> resultFunction) RaycastContext
(Vec3d start, Vec3d end, RaycastContext.ShapeType shapeType, RaycastContext.FluidHandling fluidHandling, Entity entity) TeleportTarget
(ServerWorld world, Entity entity, TeleportTarget.PostDimensionTransition postDimensionTransition) -
Uses of Entity in net.minecraft.world.border
Modifier and TypeMethodDescriptionboolean
WorldBorder.canCollide
(Entity entity, Box box) double
WorldBorder.getDistanceInsideBorder
(Entity entity) -
Uses of Entity in net.minecraft.world.chunk
Modifier and TypeMethodDescriptionabstract void
void
void
Deprecated.void
ChunkCache.getEntityCollisions
(@Nullable Entity entity, Box box) -
Uses of Entity in net.minecraft.world.dimension
Modifier and TypeMethodDescriptionPortalManager.createTeleportTarget
(ServerWorld world, Entity entity) static Vec3d
NetherPortal.findOpenPosition
(Vec3d fallback, ServerWorld world, Entity entity, EntityDimensions dimensions) boolean
PortalManager.tick
(ServerWorld world, Entity entity, boolean canUsePortals) -
Uses of Entity in net.minecraft.world.event
Modifier and TypeFieldDescriptionGameEvent.Emitter.sourceEntity
The field for thesourceEntity
record component.Modifier and TypeMethodDescriptionGameEvent.Emitter.sourceEntity()
Returns the value of thesourceEntity
record component.Modifier and TypeMethodDescriptionvoid
Vibrations.Callback.accept
(ServerWorld world, BlockPos pos, RegistryEntry<GameEvent> event, @Nullable Entity sourceEntity, @Nullable Entity entity, float distance) Accepts a game event after delay.static GameEvent.Emitter
static GameEvent.Emitter
GameEvent.Emitter.of
(@Nullable Entity sourceEntity, @Nullable BlockState affectedState) ModifierConstructorDescriptionEmitter
(@Nullable Entity entity, @Nullable BlockState blockState) EntityPositionSource
(Entity entity, float yOffset) ModifierConstructorDescriptionprivate
EntityPositionSource
(com.mojang.datafixers.util.Either<Entity, com.mojang.datafixers.util.Either<UUID, Integer>> source, float yOffset) -
Uses of Entity in net.minecraft.world.event.listener
Modifier and TypeMethodDescriptionVibration.entity()
Returns the value of theentity
record component.Modifier and TypeMethodDescriptionVibration.getEntity
(ServerWorld world) Vibration.getOwner
(ServerWorld world) -
Uses of Entity in net.minecraft.world.explosion
Modifier and TypeFieldDescriptionprivate final Entity
EntityExplosionBehavior.entity
ExplosionImpl.entity
Modifier and TypeMethodDescriptionfloat
ExplosionBehavior.calculateDamage
(Explosion explosion, Entity entity, float amount) static float
ExplosionImpl.calculateReceivedDamage
(Vec3d pos, Entity entity) static DamageSource
Explosion.createDamageSource
(World world, @Nullable Entity source) static @Nullable LivingEntity
Explosion.getCausingEntity
(@Nullable Entity entity) float
AdvancedExplosionBehavior.getKnockbackModifier
(Entity entity) float
ExplosionBehavior.getKnockbackModifier
(Entity entity) private ExplosionBehavior
ExplosionImpl.makeBehavior
(@Nullable Entity entity) boolean
AdvancedExplosionBehavior.shouldDamage
(Explosion explosion, Entity entity) boolean
ExplosionBehavior.shouldDamage
(Explosion explosion, Entity entity) ModifierConstructorDescriptionEntityExplosionBehavior
(Entity entity) ExplosionImpl
(ServerWorld world, @Nullable Entity entity, @Nullable DamageSource damageSource, @Nullable ExplosionBehavior behavior, Vec3d pos, float power, boolean createFire, Explosion.DestructionType destructionType) -
Uses of Entity in net.minecraft.world.storage
Modifier and TypeMethodDescriptionprivate static ChunkDataList
<Entity> EntityChunkDataAccess.emptyDataList
(ChunkPos pos) EntityChunkDataAccess.readChunkData
(ChunkPos pos) Modifier and TypeMethodDescriptionvoid
EntityChunkDataAccess.writeChunkData
(ChunkDataList<Entity> dataList) -
Uses of Entity in net.minecraft.world.tick