Package net.minecraft.entity
Class Entity
- java.lang.Object
-
- net.minecraftforge.common.capabilities.CapabilityProvider<Entity>
-
- net.minecraft.entity.Entity
-
- All Implemented Interfaces:
ICommandSource,INameable,ICapabilityProvider,ICapabilitySerializable<CompoundNBT>,IForgeEntity,INBTSerializable<CompoundNBT>
- Direct Known Subclasses:
AbstractMinecartEntity,AreaEffectCloudEntity,BoatEntity,EnderCrystalEntity,EvokerFangsEntity,ExperienceOrbEntity,EyeOfEnderEntity,FallingBlockEntity,HangingEntity,ItemEntity,LightningBoltEntity,LivingEntity,PartEntity,ProjectileEntity,TNTEntity
public abstract class Entity extends CapabilityProvider<Entity> implements INameable, ICommandSource, IForgeEntity
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interfaceEntity.IMoveCallback
-
Field Summary
Fields Modifier and Type Field Description private AxisAlignedBBbbprivate BlockPosblockPositionbooleanblocksBuildingprotected intboardingCooldownprivate booleancanUpdateprivate java.util.Collection<ItemEntity>captureDropsprivate static DataParameter<java.lang.Integer>DATA_AIR_SUPPLY_IDprivate static DataParameter<java.util.Optional<ITextComponent>>DATA_CUSTOM_NAMEprivate static DataParameter<java.lang.Boolean>DATA_CUSTOM_NAME_VISIBLEprivate static DataParameter<java.lang.Boolean>DATA_NO_GRAVITYprotected static DataParameter<Pose>DATA_POSEprotected static DataParameter<java.lang.Byte>DATA_SHARED_FLAGS_IDprivate static DataParameter<java.lang.Boolean>DATA_SILENTprivate Vector3ddeltaMovementprivate EntitySizedimensionsprivate static java.util.List<ItemStack>EMPTY_LISTprotected static java.util.concurrent.atomic.AtomicIntegerENTITY_COUNTERprotected EntityDataManagerentityDataprivate floateyeHeightfloatfallDistanceprotected booleanfirstTickprotected it.unimi.dsi.fastutil.objects.Object2DoubleMap<ITag<Fluid>>fluidHeightprotected ITag<Fluid>fluidOnEyesprivate booleanforceChunkAdditionbooleanforcedLoadingprotected booleanglowingbooleanhasImpulsebooleanhorizontalCollisionbooleanhurtMarkedprivate intidbooleaninChunkprivate static AxisAlignedBBINITIAL_AABBprivate booleaninvulnerableintinvulnerableTimeprivate booleanisAddedToWorldInternal use for keeping track of entities that are tracked by a world, to allow guarantees that entity position changes will force a chunk load, avoiding potential issues with entity desyncing and bad chunk data.protected booleanisInsidePortalWorldlevelprotected static org.apache.logging.log4j.LoggerLOGGERfloatmaxUpStepfloatmoveDistprivate booleanmovedSinceLastChunkCheckprivate floatnextFlapprivate floatnextStepbooleannoCullingbooleannoPhysicsprotected booleanonGroundprivate Vector3dpacketCoordinatesprivate java.util.List<Entity>passengersprivate CompoundNBTpersistentDataprivate double[]pistonDeltasprivate longpistonDeltasGameTimeprivate intportalCooldownprotected BlockPosportalEntrancePosprotected intportalTimeprivate Vector3dpositionfloatpushthroughprotected java.util.Randomrandomprivate intremainingFireTicksbooleanremovedDeprecated.protected java.lang.StringstringUUIDprotected Vector3dstuckSpeedMultiplierprivate java.util.Set<java.lang.String>tagsinttickCountprivate EntityType<?>typeDeprecated.protected java.util.UUIDuuidprivate EntityvehiclebooleanverticalCollisionprivate static doubleviewScalefloatwalkDistfloatwalkDistOprotected booleanwasEyeInWaterprotected booleanwasTouchingWaterintxChunkdoublexodoublexOldfloatxRotfloatxRotOintyChunkdoubleyodoubleyOldfloatyRotfloatyRotOintzChunkdoublezodoublezOld-
Fields inherited from interface net.minecraft.command.ICommandSource
NULL
-
-
Constructor Summary
Constructors Constructor Description Entity(EntityType<?> p_i48580_1_, World p_i48580_2_)
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Deprecated Methods Modifier and Type Method Description voidabsMoveTo(double p_242281_1_, double p_242281_3_, double p_242281_5_)voidabsMoveTo(double p_70080_1_, double p_70080_3_, double p_70080_5_, float p_70080_7_, float p_70080_8_)booleanacceptsFailure()booleanacceptsSuccess()protected abstract voidaddAdditionalSaveData(CompoundNBT p_213281_1_)protected voidaddPassenger(Entity p_184200_1_)booleanaddTag(java.lang.String p_184211_1_)voidanimateHurt()private doubleapplyPistonMovementRestriction(Direction.Axis p_213304_1_, double p_213304_2_)voidawardKillScore(Entity p_191956_1_, int p_191956_2_, DamageSource p_191956_3_)voidbaseTick()BlockPosblockPosition()booleanbroadcastToPlayer(ServerPlayerEntity p_174827_1_)protected Vector3dcalculateUpVector(float p_213320_1_, float p_213320_2_)protected Vector3dcalculateViewVector(float p_174806_1_, float p_174806_2_)protected booleancanAddPassenger(Entity p_184219_1_)booleancanBeCollidedWith()booleancanChangeDimensions()booleancanCollideWith(Entity p_241849_1_)protected booleancanEnterPose(Pose p_213298_1_)protected booleancanRide(Entity p_184228_1_)booleancanSpawnSprintParticle()booleancanTrample(BlockState state, BlockPos pos, float fallDistance)Checks if thisEntitycan trample aBlock.booleancanUpdate()voidcanUpdate(boolean value)java.util.Collection<ItemEntity>captureDrops()java.util.Collection<ItemEntity>captureDrops(java.util.Collection<ItemEntity> value)booleancauseFallDamage(float p_225503_1_, float p_225503_2_)EntitychangeDimension(ServerWorld p_241206_1_)EntitychangeDimension(ServerWorld p_241206_1_, ITeleporter teleporter)booleancheckAndResetForcedChunkAdditionFlag()booleancheckAndResetUpdateChunkPos()voidcheckDespawn()protected voidcheckFallDamage(double p_184231_1_, boolean p_184231_3_, BlockState p_184231_4_, BlockPos p_184231_5_)protected voidcheckInsideBlocks()voidclearFire()booleancloserThan(Entity p_233562_1_, double p_233562_2_)private Vector3dcollide(Vector3d p_213306_1_)static Vector3dcollideBoundingBox(Vector3d p_213313_0_, AxisAlignedBB p_213313_1_, IWorldReader p_213313_2_, ISelectionContext p_213313_3_, ReuseableStream<VoxelShape> p_213313_4_)static Vector3dcollideBoundingBoxHeuristically(Entity p_223307_0_, Vector3d p_223307_1_, AxisAlignedBB p_223307_2_, World p_223307_3_, ISelectionContext p_223307_4_, ReuseableStream<VoxelShape> p_223307_5_)static Vector3dcollideBoundingBoxLegacy(Vector3d p_223310_0_, AxisAlignedBB p_223310_1_, ReuseableStream<VoxelShape> p_223310_2_)voidcopyPosition(Entity p_82149_1_)CommandSourcecreateCommandSourceStack()protected HoverEventcreateHoverEvent()protected abstract voiddefineSynchedData()booleandisplayFireAnimation()floatdistanceTo(Entity p_70032_1_)doubledistanceToSqr(double p_70092_1_, double p_70092_3_, double p_70092_5_)doubledistanceToSqr(Entity p_70068_1_)doubledistanceToSqr(Vector3d p_195048_1_)voiddoEnchantDamageEffects(LivingEntity p_174815_1_, Entity p_174815_2_)protected voiddoWaterSplashEffect()voidejectPassengers()booleanequals(java.lang.Object p_equals_1_)voidfillCrashReportCategory(CrashReportCategory p_85029_1_)private voidfillIndirectPassengers(boolean p_200604_1_, java.util.Set<Entity> p_200604_2_)protected PortalInfofindDimensionEntryPoint(ServerWorld p_241829_1_)booleanfireImmune()abstract IPacket<?>getAddEntityPacket()intgetAirSupply()java.lang.Iterable<ItemStack>getAllSlots()java.lang.Iterable<ItemStack>getArmorSlots()floatgetBbHeight()floatgetBbWidth()floatgetBlockExplosionResistance(Explosion p_180428_1_, IBlockReader p_180428_2_, BlockPos p_180428_3_, BlockState p_180428_4_, FluidState p_180428_5_, float p_180428_6_)protected floatgetBlockJumpFactor()protected BlockPosgetBlockPosBelowThatAffectsMyMovement()protected floatgetBlockSpeedFactor()protected BlockStategetBlockStateOn()AxisAlignedBBgetBoundingBox()AxisAlignedBBgetBoundingBoxForCulling()protected AxisAlignedBBgetBoundingBoxForPose(Pose p_213321_1_)floatgetBrightness()protected static Vector3dgetCollisionHorizontalEscapeVector(double p_233559_0_, double p_233559_2_, float p_233559_4_)WorldgetCommandSenderWorld()EntitygetControllingPassenger()ITextComponentgetCustomName()Vector3dgetDeltaMovement()intgetDimensionChangingDelay()EntitySizegetDimensions(Pose p_213305_1_)Deprecated.Can be overridden but callIForgeEntity.getDimensionsForge(Pose)instead.DirectiongetDirection()Vector3dgetDismountLocationForPassenger(LivingEntity p_230268_1_)ITextComponentgetDisplayName()java.lang.StringgetEncodeId()EntityDataManagergetEntityData()protected java.util.Optional<TeleportationRepositioner.Result>getExitPortal(ServerWorld p_241830_1_, BlockPos p_241830_2_, boolean p_241830_3_)floatgetEyeHeight()floatgetEyeHeight(Pose p_213307_1_)protected floatgetEyeHeight(Pose p_213316_1_, EntitySize p_213316_2_)Deprecated.Can be overridden but callIForgeEntity.getEyeHeightForge(Pose, EntitySize)instead.floatgetEyeHeightAccess(Pose pose, EntitySize size)Accessor method forgetEyeHeight(Pose, EntitySize)Vector3dgetEyePosition(float p_174824_1_)doublegetEyeY()protected intgetFireImmuneTicks()doublegetFluidHeight(ITag<Fluid> p_233571_1_)doublegetFluidJumpThreshold()Vector3dgetForward()java.lang.Iterable<ItemStack>getHandSlots()static doublegetHorizontalDistanceSqr(Vector3d p_213296_0_)intgetId()java.util.Collection<Entity>getIndirectPassengers()private static Vector3dgetInputVector(Vector3d p_213299_0_, float p_213299_1_, float p_213299_2_)Vector3dgetLeashOffset()Vector3dgetLightProbePosition(float p_241842_1_)Vector3dgetLookAngle()intgetMaxAirSupply()intgetMaxFallDistance()DirectiongetMotionDirection()doublegetMyRidingOffset()ITextComponentgetName()protected BlockPosgetOnPos()Vector3dgetPacketCoordinates()java.util.List<Entity>getPassengers()doublegetPassengersRidingOffset()protected intgetPermissionLevel()CompoundNBTgetPersistentData()Returns a NBTTagCompound that can be used to store custom data for this entity.floatgetPickRadius()PushReactiongetPistonPushReaction()intgetPortalWaitTime()PosegetPose()Vector3dgetPosition(float p_242282_1_)doublegetRandomX(double p_226282_1_)doublegetRandomY()doublegetRandomZ(double p_226287_1_)protected Vector3dgetRelativePortalPosition(Direction.Axis p_241839_1_, TeleportationRepositioner.Result p_241839_2_)intgetRemainingFireTicks()EntitygetRootVehicle()Vector3dgetRopeHoldPosition(float p_241843_1_)Vector2fgetRotationVector()java.lang.StringgetScoreboardName()java.util.stream.Stream<Entity>getSelfAndPassengers()MinecraftServergetServer()protected booleangetSharedFlag(int p_70083_1_)SoundCategorygetSoundSource()java.lang.StringgetStringUUID()protected SoundEventgetSwimHighSpeedSplashSound()protected SoundEventgetSwimSound()protected SoundEventgetSwimSplashSound()java.util.Set<java.lang.String>getTags()TeamgetTeam()intgetTeamColor()EntityType<?>getType()protected ITextComponentgetTypeName()Vector3dgetUpVector(float p_213286_1_)java.util.UUIDgetUUID()EntitygetVehicle()static doublegetViewScale()Vector3dgetViewVector(float p_70676_1_)floatgetViewXRot(float p_195050_1_)floatgetViewYRot(float p_195046_1_)doublegetX()doublegetX(double p_226275_1_)doublegetY()doublegetY(double p_226283_1_)floatgetYHeadRot()doublegetZ()doublegetZ(double p_226285_1_)voidhandleEntityEvent(byte p_70103_1_)voidhandleInsidePortal(BlockPos p_181015_1_)protected voidhandleNetherPortal()booleanhasCustomName()inthashCode()booleanhasIndirectPassenger(Entity p_184215_1_)booleanhasOnePlayerPassenger()booleanhasPassenger(java.lang.Class<? extends Entity> p_205708_1_)booleanhasPassenger(Entity p_184196_1_)booleanhasPermissions(int p_211513_1_)booleanhurt(DamageSource p_70097_1_, float p_70097_2_)booleanignoreExplosion()ActionResultTypeinteract(PlayerEntity p_184230_1_, Hand p_184230_2_)ActionResultTypeinteractAt(PlayerEntity p_184199_1_, Vector3d p_184199_2_, Hand p_184199_3_)booleanis(Entity p_70028_1_)booleanisAddedToWorld()Gets whether this entity has been added to a world (for tracking).booleanisAlive()booleanisAlliedTo(Entity p_184191_1_)booleanisAlliedTo(Team p_184194_1_)booleanisAttackable()booleanisColliding(BlockPos p_242278_1_, BlockState p_242278_2_)booleanisControlledByLocalInstance()booleanisCrouching()booleanisCustomNameVisible()booleanisDescending()booleanisDiscrete()booleanisEyeInFluid(ITag<Fluid> p_208600_1_)booleanisFree(double p_70038_1_, double p_70038_3_, double p_70038_5_)private booleanisFree(AxisAlignedBB p_174809_1_)booleanisGlowing()booleanisIgnoringBlockTriggers()private booleanisInBubbleColumn()booleanisInLava()private booleanisInRain()booleanisInvisible()booleanisInvisibleTo(PlayerEntity p_98034_1_)booleanisInvulnerable()booleanisInvulnerableTo(DamageSource p_180431_1_)booleanisInWall()booleanisInWater()booleanisInWaterOrBubble()booleanisInWaterOrRain()booleanisInWaterRainOrBubble()protected booleanisMovementNoisy()booleanisNoGravity()booleanisOnFire()booleanisOnGround()booleanisOnPortalCooldown()booleanisPassenger()booleanisPassengerOfSameVehicle(Entity p_184223_1_)booleanisPickable()booleanisPushable()booleanisPushedByFluid()booleanisShiftKeyDown()booleanisSilent()booleanisSpectator()booleanisSprinting()booleanisSteppingCarefully()booleanisSuppressingBounce()booleanisSwimming()booleanisUnderWater()booleanisVehicle()booleanisVisuallyCrawling()booleanisVisuallySwimming()voidkill()voidkilled(ServerWorld p_241847_1_, LivingEntity p_241847_2_)protected voidlavaHurt()voidlerpHeadTo(float p_208000_1_, int p_208000_2_)voidlerpMotion(double p_70016_1_, double p_70016_3_, double p_70016_5_)voidlerpTo(double p_180426_1_, double p_180426_3_, double p_180426_5_, float p_180426_7_, float p_180426_8_, int p_180426_9_, boolean p_180426_10_)protected Vector3dlimitPistonMovement(Vector3d p_213308_1_)voidload(CompoundNBT p_70020_1_)voidlookAt(EntityAnchorArgument.Type p_200602_1_, Vector3d p_200602_2_)protected booleanmakeFlySound()voidmakeStuckInBlock(BlockState p_213295_1_, Vector3d p_213295_2_)protected voidmarkHurt()protected Vector3dmaybeBackOffFromEdge(Vector3d p_225514_1_, MoverType p_225514_2_)floatmirror(Mirror p_184217_1_)voidmove(MoverType p_213315_1_, Vector3d p_213315_2_)voidmoveRelative(float p_213309_1_, Vector3d p_213309_2_)voidmoveTo(double p_225653_1_, double p_225653_3_, double p_225653_5_)voidmoveTo(double p_70012_1_, double p_70012_3_, double p_70012_5_, float p_70012_7_, float p_70012_8_)voidmoveTo(BlockPos p_174828_1_, float p_174828_2_, float p_174828_3_)voidmoveTo(Vector3d p_233576_1_)protected voidmoveTowardsClosestSpace(double p_213282_1_, double p_213282_3_, double p_213282_5_)protected ListNBTnewDoubleList(double... p_70087_1_)protected ListNBTnewFloatList(float... p_70049_1_)protected floatnextStep()voidonAboveBubbleCol(boolean p_203002_1_)voidonAddedToWorld()Called after the entity has been added to the world's ticking list.protected voidonInsideBlock(BlockState p_191955_1_)voidonInsideBubbleColumn(boolean p_203004_1_)booleanonlyOpCanSetNbt()voidonPassengerTurned(Entity p_184190_1_)voidonRemovedFromWorld()Called after the entity has been removed to the world's ticking list.voidonSyncedDataUpdated(DataParameter<?> p_184206_1_)protected voidoutOfWorld()RayTraceResultpick(double p_213324_1_, float p_213324_3_, boolean p_213324_4_)voidplayerTouch(PlayerEntity p_70100_1_)protected floatplayFlySound(float p_191954_1_)voidplaySound(SoundEvent p_184185_1_, float p_184185_2_, float p_184185_3_)protected voidplayStepSound(BlockPos p_180429_1_, BlockState p_180429_2_)protected voidplaySwimSound(float p_203006_1_)Vector3dposition()voidpositionRider(Entity p_184232_1_)private voidpositionRider(Entity p_226266_1_, Entity.IMoveCallback p_226266_2_)protected voidprocessPortalCooldown()voidpush(double p_70024_1_, double p_70024_3_, double p_70024_5_)voidpush(Entity p_70108_1_)protected abstract voidreadAdditionalSaveData(CompoundNBT p_70037_1_)protected voidreapplyPosition()voidrefreshDimensions()voidremove()voidremove(boolean keepData)private static ITextComponentremoveAction(ITextComponent p_233573_0_)protected voidremoveAfterChangingDimensions()protected voidremovePassenger(Entity p_184225_1_)booleanremoveTag(java.lang.String p_184197_1_)voidremoveVehicle()protected booleanrepositionEntityAfterLoad()protected voidresetPos()voidrestoreFrom(Entity p_180432_1_)voidrevive()Revives an entity that has been removed from a world.booleanrideableUnderWater()Deprecated.voidrideTick()floatrotate(Rotation p_184229_1_)booleansave(CompoundNBT p_70039_1_)booleansaveAsPassenger(CompoundNBT p_184198_1_)CompoundNBTsaveWithoutId(CompoundNBT p_189511_1_)voidsendMessage(ITextComponent p_145747_1_, java.util.UUID p_145747_2_)voidsetAirSupply(int p_70050_1_)voidsetBoundingBox(AxisAlignedBB p_174826_1_)voidsetCustomName(ITextComponent p_200203_1_)voidsetCustomNameVisible(boolean p_174805_1_)voidsetDeltaMovement(double p_213293_1_, double p_213293_3_, double p_213293_5_)voidsetDeltaMovement(Vector3d p_213317_1_)voidsetGlowing(boolean p_184195_1_)voidsetId(int p_145769_1_)voidsetInvisible(boolean p_82142_1_)voidsetInvulnerable(boolean p_184224_1_)voidsetItemSlot(EquipmentSlotType p_184201_1_, ItemStack p_184201_2_)voidsetLevel(World p_70029_1_)voidsetLocationFromBoundingbox()voidsetNoGravity(boolean p_189654_1_)voidsetOnGround(boolean p_230245_1_)voidsetPacketCoordinates(double p_213312_1_, double p_213312_3_, double p_213312_5_)voidsetPacketCoordinates(Vector3d p_242277_1_)voidsetPortalCooldown()voidsetPos(double p_70107_1_, double p_70107_3_, double p_70107_5_)voidsetPosAndOldPos(double p_226286_1_, double p_226286_3_, double p_226286_5_)voidsetPose(Pose p_213301_1_)voidsetPosRaw(double p_226288_1_, double p_226288_3_, double p_226288_5_)voidsetRemainingFireTicks(int p_241209_1_)protected voidsetRot(float p_70101_1_, float p_70101_2_)voidsetSecondsOnFire(int p_70015_1_)protected voidsetSharedFlag(int p_70052_1_, boolean p_70052_2_)voidsetShiftKeyDown(boolean p_226284_1_)voidsetSilent(boolean p_174810_1_)booleansetSlot(int p_174820_1_, ItemStack p_174820_2_)voidsetSprinting(boolean p_70031_1_)voidsetSwimming(boolean p_204711_1_)voidsetUUID(java.util.UUID p_184221_1_)static voidsetViewScale(double p_184227_0_)voidsetYBodyRot(float p_181013_1_)voidsetYHeadRot(float p_70034_1_)booleanshouldBlockExplode(Explosion p_174816_1_, IBlockReader p_174816_2_, BlockPos p_174816_3_, BlockState p_174816_4_, float p_174816_5_)booleanshouldInformAdmins()booleanshouldRender(double p_145770_1_, double p_145770_3_, double p_145770_5_)booleanshouldRenderAtSqrDistance(double p_70112_1_)booleanshouldShowName()booleanshowVehicleHealth()booleanskipAttackInteraction(Entity p_85031_1_)ItemEntityspawnAtLocation(ItemStack p_199701_1_)ItemEntityspawnAtLocation(ItemStack p_70099_1_, float p_70099_2_)ItemEntityspawnAtLocation(IItemProvider p_199703_1_)ItemEntityspawnAtLocation(IItemProvider p_199702_1_, int p_199702_2_)protected voidspawnSprintParticle()booleanstartRiding(Entity p_184220_1_)booleanstartRiding(Entity p_184205_1_, boolean p_184205_2_)voidstartSeenByPlayer(ServerPlayerEntity p_184178_1_)voidstopRiding()voidstopSeenByPlayer(ServerPlayerEntity p_184203_1_)voidteleportTo(double p_70634_1_, double p_70634_3_, double p_70634_5_)voidteleportToWithTicket(double p_223102_1_, double p_223102_3_, double p_223102_5_)voidthunderHit(ServerWorld p_241841_1_, LightningBoltEntity p_241841_2_)voidtick()java.lang.StringtoString()voidturn(double p_195049_1_, double p_195049_3_)voidunRide()booleanupdateFluidHeightAndDoFluidPushing(ITag<Fluid> p_210500_1_, double p_210500_2_)private voidupdateFluidOnEyes()protected booleanupdateInWaterStateAndDoFluidPushing()(package private) voidupdateInWaterStateAndDoWaterCurrentPushing()voidupdateSwimming()-
Methods inherited from class net.minecraftforge.common.capabilities.CapabilityProvider
areCapsCompatible, areCapsCompatible, deserializeCaps, gatherCapabilities, gatherCapabilities, gatherCapabilities, getCapabilities, getCapability, invalidateCaps, reviveCaps, serializeCaps
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface net.minecraftforge.common.capabilities.ICapabilityProvider
getCapability, getCapability
-
Methods inherited from interface net.minecraftforge.common.extensions.IForgeEntity
canBeRiddenInWater, canRiderInteract, deserializeNBT, getClassification, getDimensionsForge, getEntity, getEyeHeightForge, getParts, getPickedResult, isMultipartEntity, serializeNBT, shouldRiderSit
-
-
-
-
Field Detail
-
LOGGER
protected static final org.apache.logging.log4j.Logger LOGGER
-
ENTITY_COUNTER
protected static final java.util.concurrent.atomic.AtomicInteger ENTITY_COUNTER
-
EMPTY_LIST
private static final java.util.List<ItemStack> EMPTY_LIST
-
INITIAL_AABB
private static final AxisAlignedBB INITIAL_AABB
-
viewScale
private static double viewScale
-
type
@Deprecated private final EntityType<?> type
Deprecated.
-
id
private int id
-
blocksBuilding
public boolean blocksBuilding
-
passengers
private final java.util.List<Entity> passengers
-
boardingCooldown
protected int boardingCooldown
-
vehicle
@Nullable private Entity vehicle
-
forcedLoading
public boolean forcedLoading
-
level
public World level
-
xo
public double xo
-
yo
public double yo
-
zo
public double zo
-
position
private Vector3d position
-
blockPosition
private BlockPos blockPosition
-
deltaMovement
private Vector3d deltaMovement
-
yRot
public float yRot
-
xRot
public float xRot
-
yRotO
public float yRotO
-
xRotO
public float xRotO
-
bb
private AxisAlignedBB bb
-
onGround
protected boolean onGround
-
horizontalCollision
public boolean horizontalCollision
-
verticalCollision
public boolean verticalCollision
-
hurtMarked
public boolean hurtMarked
-
stuckSpeedMultiplier
protected Vector3d stuckSpeedMultiplier
-
removed
@Deprecated public boolean removed
Deprecated.
-
walkDistO
public float walkDistO
-
walkDist
public float walkDist
-
moveDist
public float moveDist
-
fallDistance
public float fallDistance
-
nextStep
private float nextStep
-
nextFlap
private float nextFlap
-
xOld
public double xOld
-
yOld
public double yOld
-
zOld
public double zOld
-
maxUpStep
public float maxUpStep
-
noPhysics
public boolean noPhysics
-
pushthrough
public float pushthrough
-
random
protected final java.util.Random random
-
tickCount
public int tickCount
-
remainingFireTicks
private int remainingFireTicks
-
wasTouchingWater
protected boolean wasTouchingWater
-
wasEyeInWater
protected boolean wasEyeInWater
-
invulnerableTime
public int invulnerableTime
-
firstTick
protected boolean firstTick
-
entityData
protected final EntityDataManager entityData
-
DATA_SHARED_FLAGS_ID
protected static final DataParameter<java.lang.Byte> DATA_SHARED_FLAGS_ID
-
DATA_AIR_SUPPLY_ID
private static final DataParameter<java.lang.Integer> DATA_AIR_SUPPLY_ID
-
DATA_CUSTOM_NAME
private static final DataParameter<java.util.Optional<ITextComponent>> DATA_CUSTOM_NAME
-
DATA_CUSTOM_NAME_VISIBLE
private static final DataParameter<java.lang.Boolean> DATA_CUSTOM_NAME_VISIBLE
-
DATA_SILENT
private static final DataParameter<java.lang.Boolean> DATA_SILENT
-
DATA_NO_GRAVITY
private static final DataParameter<java.lang.Boolean> DATA_NO_GRAVITY
-
DATA_POSE
protected static final DataParameter<Pose> DATA_POSE
-
inChunk
public boolean inChunk
-
xChunk
public int xChunk
-
yChunk
public int yChunk
-
zChunk
public int zChunk
-
movedSinceLastChunkCheck
private boolean movedSinceLastChunkCheck
-
packetCoordinates
private Vector3d packetCoordinates
-
noCulling
public boolean noCulling
-
hasImpulse
public boolean hasImpulse
-
portalCooldown
private int portalCooldown
-
isInsidePortal
protected boolean isInsidePortal
-
portalTime
protected int portalTime
-
portalEntrancePos
protected BlockPos portalEntrancePos
-
invulnerable
private boolean invulnerable
-
uuid
protected java.util.UUID uuid
-
stringUUID
protected java.lang.String stringUUID
-
glowing
protected boolean glowing
-
tags
private final java.util.Set<java.lang.String> tags
-
forceChunkAddition
private boolean forceChunkAddition
-
pistonDeltas
private final double[] pistonDeltas
-
pistonDeltasGameTime
private long pistonDeltasGameTime
-
dimensions
private EntitySize dimensions
-
eyeHeight
private float eyeHeight
-
canUpdate
private boolean canUpdate
-
captureDrops
private java.util.Collection<ItemEntity> captureDrops
-
persistentData
private CompoundNBT persistentData
-
isAddedToWorld
private boolean isAddedToWorld
Internal use for keeping track of entities that are tracked by a world, to allow guarantees that entity position changes will force a chunk load, avoiding potential issues with entity desyncing and bad chunk data.
-
-
Constructor Detail
-
Entity
public Entity(EntityType<?> p_i48580_1_, World p_i48580_2_)
-
-
Method Detail
-
isColliding
public boolean isColliding(BlockPos p_242278_1_, BlockState p_242278_2_)
-
getTeamColor
public int getTeamColor()
-
isSpectator
public boolean isSpectator()
-
unRide
public final void unRide()
-
setPacketCoordinates
public void setPacketCoordinates(double p_213312_1_, double p_213312_3_, double p_213312_5_)
-
setPacketCoordinates
public void setPacketCoordinates(Vector3d p_242277_1_)
-
getPacketCoordinates
public Vector3d getPacketCoordinates()
-
getType
public EntityType<?> getType()
-
getId
public int getId()
-
setId
public void setId(int p_145769_1_)
-
getTags
public java.util.Set<java.lang.String> getTags()
-
addTag
public boolean addTag(java.lang.String p_184211_1_)
-
removeTag
public boolean removeTag(java.lang.String p_184197_1_)
-
kill
public void kill()
-
defineSynchedData
protected abstract void defineSynchedData()
-
getEntityData
public EntityDataManager getEntityData()
-
equals
public boolean equals(java.lang.Object p_equals_1_)
- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
resetPos
protected void resetPos()
-
remove
public void remove()
-
remove
public void remove(boolean keepData)
-
setPose
public void setPose(Pose p_213301_1_)
-
getPose
public Pose getPose()
-
closerThan
public boolean closerThan(Entity p_233562_1_, double p_233562_2_)
-
setRot
protected void setRot(float p_70101_1_, float p_70101_2_)
-
setPos
public void setPos(double p_70107_1_, double p_70107_3_, double p_70107_5_)
-
reapplyPosition
protected void reapplyPosition()
-
turn
public void turn(double p_195049_1_, double p_195049_3_)
-
tick
public void tick()
-
baseTick
public void baseTick()
-
setPortalCooldown
public void setPortalCooldown()
-
isOnPortalCooldown
public boolean isOnPortalCooldown()
-
processPortalCooldown
protected void processPortalCooldown()
-
getPortalWaitTime
public int getPortalWaitTime()
-
lavaHurt
protected void lavaHurt()
-
setSecondsOnFire
public void setSecondsOnFire(int p_70015_1_)
-
setRemainingFireTicks
public void setRemainingFireTicks(int p_241209_1_)
-
getRemainingFireTicks
public int getRemainingFireTicks()
-
clearFire
public void clearFire()
-
outOfWorld
protected void outOfWorld()
-
isFree
public boolean isFree(double p_70038_1_, double p_70038_3_, double p_70038_5_)
-
isFree
private boolean isFree(AxisAlignedBB p_174809_1_)
-
setOnGround
public void setOnGround(boolean p_230245_1_)
-
isOnGround
public boolean isOnGround()
-
getOnPos
protected BlockPos getOnPos()
-
getBlockJumpFactor
protected float getBlockJumpFactor()
-
getBlockSpeedFactor
protected float getBlockSpeedFactor()
-
getBlockPosBelowThatAffectsMyMovement
protected BlockPos getBlockPosBelowThatAffectsMyMovement()
-
maybeBackOffFromEdge
protected Vector3d maybeBackOffFromEdge(Vector3d p_225514_1_, MoverType p_225514_2_)
-
applyPistonMovementRestriction
private double applyPistonMovementRestriction(Direction.Axis p_213304_1_, double p_213304_2_)
-
getHorizontalDistanceSqr
public static double getHorizontalDistanceSqr(Vector3d p_213296_0_)
-
collideBoundingBoxHeuristically
public static Vector3d collideBoundingBoxHeuristically(@Nullable Entity p_223307_0_, Vector3d p_223307_1_, AxisAlignedBB p_223307_2_, World p_223307_3_, ISelectionContext p_223307_4_, ReuseableStream<VoxelShape> p_223307_5_)
-
collideBoundingBoxLegacy
public static Vector3d collideBoundingBoxLegacy(Vector3d p_223310_0_, AxisAlignedBB p_223310_1_, ReuseableStream<VoxelShape> p_223310_2_)
-
collideBoundingBox
public static Vector3d collideBoundingBox(Vector3d p_213313_0_, AxisAlignedBB p_213313_1_, IWorldReader p_213313_2_, ISelectionContext p_213313_3_, ReuseableStream<VoxelShape> p_213313_4_)
-
nextStep
protected float nextStep()
-
setLocationFromBoundingbox
public void setLocationFromBoundingbox()
-
getSwimSound
protected SoundEvent getSwimSound()
-
getSwimSplashSound
protected SoundEvent getSwimSplashSound()
-
getSwimHighSpeedSplashSound
protected SoundEvent getSwimHighSpeedSplashSound()
-
checkInsideBlocks
protected void checkInsideBlocks()
-
onInsideBlock
protected void onInsideBlock(BlockState p_191955_1_)
-
playStepSound
protected void playStepSound(BlockPos p_180429_1_, BlockState p_180429_2_)
-
playSwimSound
protected void playSwimSound(float p_203006_1_)
-
playFlySound
protected float playFlySound(float p_191954_1_)
-
makeFlySound
protected boolean makeFlySound()
-
playSound
public void playSound(SoundEvent p_184185_1_, float p_184185_2_, float p_184185_3_)
-
isSilent
public boolean isSilent()
-
setSilent
public void setSilent(boolean p_174810_1_)
-
isNoGravity
public boolean isNoGravity()
-
setNoGravity
public void setNoGravity(boolean p_189654_1_)
-
isMovementNoisy
protected boolean isMovementNoisy()
-
checkFallDamage
protected void checkFallDamage(double p_184231_1_, boolean p_184231_3_, BlockState p_184231_4_, BlockPos p_184231_5_)
-
fireImmune
public boolean fireImmune()
-
causeFallDamage
public boolean causeFallDamage(float p_225503_1_, float p_225503_2_)
-
isInWater
public boolean isInWater()
-
isInRain
private boolean isInRain()
-
isInBubbleColumn
private boolean isInBubbleColumn()
-
isInWaterOrRain
public boolean isInWaterOrRain()
-
isInWaterRainOrBubble
public boolean isInWaterRainOrBubble()
-
isInWaterOrBubble
public boolean isInWaterOrBubble()
-
isUnderWater
public boolean isUnderWater()
-
updateSwimming
public void updateSwimming()
-
updateInWaterStateAndDoFluidPushing
protected boolean updateInWaterStateAndDoFluidPushing()
-
updateInWaterStateAndDoWaterCurrentPushing
void updateInWaterStateAndDoWaterCurrentPushing()
-
updateFluidOnEyes
private void updateFluidOnEyes()
-
doWaterSplashEffect
protected void doWaterSplashEffect()
-
getBlockStateOn
protected BlockState getBlockStateOn()
-
canSpawnSprintParticle
public boolean canSpawnSprintParticle()
-
spawnSprintParticle
protected void spawnSprintParticle()
-
isInLava
public boolean isInLava()
-
moveRelative
public void moveRelative(float p_213309_1_, Vector3d p_213309_2_)
-
getInputVector
private static Vector3d getInputVector(Vector3d p_213299_0_, float p_213299_1_, float p_213299_2_)
-
getBrightness
public float getBrightness()
-
setLevel
public void setLevel(World p_70029_1_)
-
absMoveTo
public void absMoveTo(double p_70080_1_, double p_70080_3_, double p_70080_5_, float p_70080_7_, float p_70080_8_)
-
absMoveTo
public void absMoveTo(double p_242281_1_, double p_242281_3_, double p_242281_5_)
-
moveTo
public void moveTo(Vector3d p_233576_1_)
-
moveTo
public void moveTo(double p_225653_1_, double p_225653_3_, double p_225653_5_)
-
moveTo
public void moveTo(BlockPos p_174828_1_, float p_174828_2_, float p_174828_3_)
-
moveTo
public void moveTo(double p_70012_1_, double p_70012_3_, double p_70012_5_, float p_70012_7_, float p_70012_8_)
-
setPosAndOldPos
public void setPosAndOldPos(double p_226286_1_, double p_226286_3_, double p_226286_5_)
-
distanceTo
public float distanceTo(Entity p_70032_1_)
-
distanceToSqr
public double distanceToSqr(double p_70092_1_, double p_70092_3_, double p_70092_5_)
-
distanceToSqr
public double distanceToSqr(Entity p_70068_1_)
-
distanceToSqr
public double distanceToSqr(Vector3d p_195048_1_)
-
playerTouch
public void playerTouch(PlayerEntity p_70100_1_)
-
push
public void push(Entity p_70108_1_)
-
push
public void push(double p_70024_1_, double p_70024_3_, double p_70024_5_)
-
markHurt
protected void markHurt()
-
hurt
public boolean hurt(DamageSource p_70097_1_, float p_70097_2_)
-
getViewVector
public final Vector3d getViewVector(float p_70676_1_)
-
getViewXRot
public float getViewXRot(float p_195050_1_)
-
getViewYRot
public float getViewYRot(float p_195046_1_)
-
calculateViewVector
protected final Vector3d calculateViewVector(float p_174806_1_, float p_174806_2_)
-
getUpVector
public final Vector3d getUpVector(float p_213286_1_)
-
calculateUpVector
protected final Vector3d calculateUpVector(float p_213320_1_, float p_213320_2_)
-
getEyePosition
public final Vector3d getEyePosition(float p_174824_1_)
-
getLightProbePosition
public Vector3d getLightProbePosition(float p_241842_1_)
-
getPosition
public final Vector3d getPosition(float p_242282_1_)
-
pick
public RayTraceResult pick(double p_213324_1_, float p_213324_3_, boolean p_213324_4_)
-
isPickable
public boolean isPickable()
-
isPushable
public boolean isPushable()
-
awardKillScore
public void awardKillScore(Entity p_191956_1_, int p_191956_2_, DamageSource p_191956_3_)
-
shouldRender
public boolean shouldRender(double p_145770_1_, double p_145770_3_, double p_145770_5_)
-
shouldRenderAtSqrDistance
public boolean shouldRenderAtSqrDistance(double p_70112_1_)
-
saveAsPassenger
public boolean saveAsPassenger(CompoundNBT p_184198_1_)
-
save
public boolean save(CompoundNBT p_70039_1_)
-
saveWithoutId
public CompoundNBT saveWithoutId(CompoundNBT p_189511_1_)
-
load
public void load(CompoundNBT p_70020_1_)
-
repositionEntityAfterLoad
protected boolean repositionEntityAfterLoad()
-
getEncodeId
@Nullable public final java.lang.String getEncodeId()
-
readAdditionalSaveData
protected abstract void readAdditionalSaveData(CompoundNBT p_70037_1_)
-
addAdditionalSaveData
protected abstract void addAdditionalSaveData(CompoundNBT p_213281_1_)
-
newDoubleList
protected ListNBT newDoubleList(double... p_70087_1_)
-
newFloatList
protected ListNBT newFloatList(float... p_70049_1_)
-
spawnAtLocation
@Nullable public ItemEntity spawnAtLocation(IItemProvider p_199703_1_)
-
spawnAtLocation
@Nullable public ItemEntity spawnAtLocation(IItemProvider p_199702_1_, int p_199702_2_)
-
spawnAtLocation
@Nullable public ItemEntity spawnAtLocation(ItemStack p_199701_1_)
-
spawnAtLocation
@Nullable public ItemEntity spawnAtLocation(ItemStack p_70099_1_, float p_70099_2_)
-
isAlive
public boolean isAlive()
-
isInWall
public boolean isInWall()
-
interact
public ActionResultType interact(PlayerEntity p_184230_1_, Hand p_184230_2_)
-
canCollideWith
public boolean canCollideWith(Entity p_241849_1_)
-
canBeCollidedWith
public boolean canBeCollidedWith()
-
rideTick
public void rideTick()
-
positionRider
public void positionRider(Entity p_184232_1_)
-
positionRider
private void positionRider(Entity p_226266_1_, Entity.IMoveCallback p_226266_2_)
-
onPassengerTurned
public void onPassengerTurned(Entity p_184190_1_)
-
getMyRidingOffset
public double getMyRidingOffset()
-
getPassengersRidingOffset
public double getPassengersRidingOffset()
-
startRiding
public boolean startRiding(Entity p_184220_1_)
-
showVehicleHealth
public boolean showVehicleHealth()
-
startRiding
public boolean startRiding(Entity p_184205_1_, boolean p_184205_2_)
-
canRide
protected boolean canRide(Entity p_184228_1_)
-
canEnterPose
protected boolean canEnterPose(Pose p_213298_1_)
-
ejectPassengers
public void ejectPassengers()
-
removeVehicle
public void removeVehicle()
-
stopRiding
public void stopRiding()
-
addPassenger
protected void addPassenger(Entity p_184200_1_)
-
removePassenger
protected void removePassenger(Entity p_184225_1_)
-
canAddPassenger
protected boolean canAddPassenger(Entity p_184219_1_)
-
lerpTo
public void lerpTo(double p_180426_1_, double p_180426_3_, double p_180426_5_, float p_180426_7_, float p_180426_8_, int p_180426_9_, boolean p_180426_10_)
-
lerpHeadTo
public void lerpHeadTo(float p_208000_1_, int p_208000_2_)
-
getPickRadius
public float getPickRadius()
-
getLookAngle
public Vector3d getLookAngle()
-
getRotationVector
public Vector2f getRotationVector()
-
getForward
public Vector3d getForward()
-
handleInsidePortal
public void handleInsidePortal(BlockPos p_181015_1_)
-
handleNetherPortal
protected void handleNetherPortal()
-
getDimensionChangingDelay
public int getDimensionChangingDelay()
-
lerpMotion
public void lerpMotion(double p_70016_1_, double p_70016_3_, double p_70016_5_)
-
handleEntityEvent
public void handleEntityEvent(byte p_70103_1_)
-
animateHurt
public void animateHurt()
-
getHandSlots
public java.lang.Iterable<ItemStack> getHandSlots()
-
getArmorSlots
public java.lang.Iterable<ItemStack> getArmorSlots()
-
getAllSlots
public java.lang.Iterable<ItemStack> getAllSlots()
-
setItemSlot
public void setItemSlot(EquipmentSlotType p_184201_1_, ItemStack p_184201_2_)
-
isOnFire
public boolean isOnFire()
-
isPassenger
public boolean isPassenger()
-
isVehicle
public boolean isVehicle()
-
rideableUnderWater
@Deprecated public boolean rideableUnderWater()
Deprecated.
-
setShiftKeyDown
public void setShiftKeyDown(boolean p_226284_1_)
-
isShiftKeyDown
public boolean isShiftKeyDown()
-
isSteppingCarefully
public boolean isSteppingCarefully()
-
isSuppressingBounce
public boolean isSuppressingBounce()
-
isDiscrete
public boolean isDiscrete()
-
isDescending
public boolean isDescending()
-
isCrouching
public boolean isCrouching()
-
isSprinting
public boolean isSprinting()
-
setSprinting
public void setSprinting(boolean p_70031_1_)
-
isSwimming
public boolean isSwimming()
-
isVisuallySwimming
public boolean isVisuallySwimming()
-
isVisuallyCrawling
public boolean isVisuallyCrawling()
-
setSwimming
public void setSwimming(boolean p_204711_1_)
-
isGlowing
public boolean isGlowing()
-
setGlowing
public void setGlowing(boolean p_184195_1_)
-
isInvisible
public boolean isInvisible()
-
isInvisibleTo
public boolean isInvisibleTo(PlayerEntity p_98034_1_)
-
getTeam
@Nullable public Team getTeam()
-
isAlliedTo
public boolean isAlliedTo(Entity p_184191_1_)
-
isAlliedTo
public boolean isAlliedTo(Team p_184194_1_)
-
setInvisible
public void setInvisible(boolean p_82142_1_)
-
getSharedFlag
protected boolean getSharedFlag(int p_70083_1_)
-
setSharedFlag
protected void setSharedFlag(int p_70052_1_, boolean p_70052_2_)
-
getMaxAirSupply
public int getMaxAirSupply()
-
getAirSupply
public int getAirSupply()
-
setAirSupply
public void setAirSupply(int p_70050_1_)
-
thunderHit
public void thunderHit(ServerWorld p_241841_1_, LightningBoltEntity p_241841_2_)
-
onAboveBubbleCol
public void onAboveBubbleCol(boolean p_203002_1_)
-
onInsideBubbleColumn
public void onInsideBubbleColumn(boolean p_203004_1_)
-
killed
public void killed(ServerWorld p_241847_1_, LivingEntity p_241847_2_)
-
moveTowardsClosestSpace
protected void moveTowardsClosestSpace(double p_213282_1_, double p_213282_3_, double p_213282_5_)
-
makeStuckInBlock
public void makeStuckInBlock(BlockState p_213295_1_, Vector3d p_213295_2_)
-
removeAction
private static ITextComponent removeAction(ITextComponent p_233573_0_)
-
getName
public ITextComponent getName()
-
getTypeName
protected ITextComponent getTypeName()
-
is
public boolean is(Entity p_70028_1_)
-
getYHeadRot
public float getYHeadRot()
-
setYHeadRot
public void setYHeadRot(float p_70034_1_)
-
setYBodyRot
public void setYBodyRot(float p_181013_1_)
-
isAttackable
public boolean isAttackable()
-
skipAttackInteraction
public boolean skipAttackInteraction(Entity p_85031_1_)
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
isInvulnerableTo
public boolean isInvulnerableTo(DamageSource p_180431_1_)
-
isInvulnerable
public boolean isInvulnerable()
-
setInvulnerable
public void setInvulnerable(boolean p_184224_1_)
-
copyPosition
public void copyPosition(Entity p_82149_1_)
-
restoreFrom
public void restoreFrom(Entity p_180432_1_)
-
changeDimension
@Nullable public Entity changeDimension(ServerWorld p_241206_1_)
-
changeDimension
@Nullable public Entity changeDimension(ServerWorld p_241206_1_, ITeleporter teleporter)
-
removeAfterChangingDimensions
protected void removeAfterChangingDimensions()
-
findDimensionEntryPoint
@Nullable protected PortalInfo findDimensionEntryPoint(ServerWorld p_241829_1_)
-
getRelativePortalPosition
protected Vector3d getRelativePortalPosition(Direction.Axis p_241839_1_, TeleportationRepositioner.Result p_241839_2_)
-
getExitPortal
protected java.util.Optional<TeleportationRepositioner.Result> getExitPortal(ServerWorld p_241830_1_, BlockPos p_241830_2_, boolean p_241830_3_)
-
canChangeDimensions
public boolean canChangeDimensions()
-
getBlockExplosionResistance
public float getBlockExplosionResistance(Explosion p_180428_1_, IBlockReader p_180428_2_, BlockPos p_180428_3_, BlockState p_180428_4_, FluidState p_180428_5_, float p_180428_6_)
-
shouldBlockExplode
public boolean shouldBlockExplode(Explosion p_174816_1_, IBlockReader p_174816_2_, BlockPos p_174816_3_, BlockState p_174816_4_, float p_174816_5_)
-
getMaxFallDistance
public int getMaxFallDistance()
-
isIgnoringBlockTriggers
public boolean isIgnoringBlockTriggers()
-
fillCrashReportCategory
public void fillCrashReportCategory(CrashReportCategory p_85029_1_)
-
displayFireAnimation
public boolean displayFireAnimation()
-
setUUID
public void setUUID(java.util.UUID p_184221_1_)
-
getUUID
public java.util.UUID getUUID()
-
getStringUUID
public java.lang.String getStringUUID()
-
getScoreboardName
public java.lang.String getScoreboardName()
-
isPushedByFluid
public boolean isPushedByFluid()
-
getViewScale
public static double getViewScale()
-
setViewScale
public static void setViewScale(double p_184227_0_)
-
getDisplayName
public ITextComponent getDisplayName()
- Specified by:
getDisplayNamein interfaceINameable
-
setCustomName
public void setCustomName(@Nullable ITextComponent p_200203_1_)
-
getCustomName
@Nullable public ITextComponent getCustomName()
- Specified by:
getCustomNamein interfaceINameable
-
hasCustomName
public boolean hasCustomName()
- Specified by:
hasCustomNamein interfaceINameable
-
setCustomNameVisible
public void setCustomNameVisible(boolean p_174805_1_)
-
isCustomNameVisible
public boolean isCustomNameVisible()
-
teleportToWithTicket
public final void teleportToWithTicket(double p_223102_1_, double p_223102_3_, double p_223102_5_)
-
teleportTo
public void teleportTo(double p_70634_1_, double p_70634_3_, double p_70634_5_)
-
shouldShowName
public boolean shouldShowName()
-
onSyncedDataUpdated
public void onSyncedDataUpdated(DataParameter<?> p_184206_1_)
-
refreshDimensions
public void refreshDimensions()
-
getDirection
public Direction getDirection()
-
getMotionDirection
public Direction getMotionDirection()
-
createHoverEvent
protected HoverEvent createHoverEvent()
-
broadcastToPlayer
public boolean broadcastToPlayer(ServerPlayerEntity p_174827_1_)
-
getBoundingBox
public AxisAlignedBB getBoundingBox()
-
getBoundingBoxForCulling
public AxisAlignedBB getBoundingBoxForCulling()
-
getBoundingBoxForPose
protected AxisAlignedBB getBoundingBoxForPose(Pose p_213321_1_)
-
setBoundingBox
public void setBoundingBox(AxisAlignedBB p_174826_1_)
-
getEyeHeight
@Deprecated protected float getEyeHeight(Pose p_213316_1_, EntitySize p_213316_2_)
Deprecated.Can be overridden but callIForgeEntity.getEyeHeightForge(Pose, EntitySize)instead.
-
getEyeHeight
public float getEyeHeight(Pose p_213307_1_)
-
getEyeHeight
public final float getEyeHeight()
-
getLeashOffset
public Vector3d getLeashOffset()
-
setSlot
public boolean setSlot(int p_174820_1_, ItemStack p_174820_2_)
-
sendMessage
public void sendMessage(ITextComponent p_145747_1_, java.util.UUID p_145747_2_)
- Specified by:
sendMessagein interfaceICommandSource
-
getCommandSenderWorld
public World getCommandSenderWorld()
-
getServer
@Nullable public MinecraftServer getServer()
-
interactAt
public ActionResultType interactAt(PlayerEntity p_184199_1_, Vector3d p_184199_2_, Hand p_184199_3_)
-
ignoreExplosion
public boolean ignoreExplosion()
-
doEnchantDamageEffects
public void doEnchantDamageEffects(LivingEntity p_174815_1_, Entity p_174815_2_)
-
startSeenByPlayer
public void startSeenByPlayer(ServerPlayerEntity p_184178_1_)
-
stopSeenByPlayer
public void stopSeenByPlayer(ServerPlayerEntity p_184203_1_)
-
rotate
public float rotate(Rotation p_184229_1_)
-
mirror
public float mirror(Mirror p_184217_1_)
-
onlyOpCanSetNbt
public boolean onlyOpCanSetNbt()
-
checkAndResetForcedChunkAdditionFlag
public boolean checkAndResetForcedChunkAdditionFlag()
-
checkAndResetUpdateChunkPos
public boolean checkAndResetUpdateChunkPos()
-
getControllingPassenger
@Nullable public Entity getControllingPassenger()
-
getPassengers
public java.util.List<Entity> getPassengers()
-
hasPassenger
public boolean hasPassenger(Entity p_184196_1_)
-
hasPassenger
public boolean hasPassenger(java.lang.Class<? extends Entity> p_205708_1_)
-
getIndirectPassengers
public java.util.Collection<Entity> getIndirectPassengers()
-
getSelfAndPassengers
public java.util.stream.Stream<Entity> getSelfAndPassengers()
-
hasOnePlayerPassenger
public boolean hasOnePlayerPassenger()
-
fillIndirectPassengers
private void fillIndirectPassengers(boolean p_200604_1_, java.util.Set<Entity> p_200604_2_)
-
getRootVehicle
public Entity getRootVehicle()
-
isPassengerOfSameVehicle
public boolean isPassengerOfSameVehicle(Entity p_184223_1_)
-
hasIndirectPassenger
public boolean hasIndirectPassenger(Entity p_184215_1_)
-
isControlledByLocalInstance
public boolean isControlledByLocalInstance()
-
getCollisionHorizontalEscapeVector
protected static Vector3d getCollisionHorizontalEscapeVector(double p_233559_0_, double p_233559_2_, float p_233559_4_)
-
getDismountLocationForPassenger
public Vector3d getDismountLocationForPassenger(LivingEntity p_230268_1_)
-
getVehicle
@Nullable public Entity getVehicle()
-
getPistonPushReaction
public PushReaction getPistonPushReaction()
-
getSoundSource
public SoundCategory getSoundSource()
-
getFireImmuneTicks
protected int getFireImmuneTicks()
-
createCommandSourceStack
public CommandSource createCommandSourceStack()
-
getPermissionLevel
protected int getPermissionLevel()
-
hasPermissions
public boolean hasPermissions(int p_211513_1_)
-
acceptsSuccess
public boolean acceptsSuccess()
- Specified by:
acceptsSuccessin interfaceICommandSource
-
acceptsFailure
public boolean acceptsFailure()
- Specified by:
acceptsFailurein interfaceICommandSource
-
shouldInformAdmins
public boolean shouldInformAdmins()
- Specified by:
shouldInformAdminsin interfaceICommandSource
-
lookAt
public void lookAt(EntityAnchorArgument.Type p_200602_1_, Vector3d p_200602_2_)
-
updateFluidHeightAndDoFluidPushing
public boolean updateFluidHeightAndDoFluidPushing(ITag<Fluid> p_210500_1_, double p_210500_2_)
-
getFluidJumpThreshold
public double getFluidJumpThreshold()
-
getBbWidth
public final float getBbWidth()
-
getBbHeight
public final float getBbHeight()
-
getAddEntityPacket
public abstract IPacket<?> getAddEntityPacket()
-
getDimensions
@Deprecated public EntitySize getDimensions(Pose p_213305_1_)
Deprecated.Can be overridden but callIForgeEntity.getDimensionsForge(Pose)instead.
-
position
public Vector3d position()
-
blockPosition
public BlockPos blockPosition()
-
getDeltaMovement
public Vector3d getDeltaMovement()
-
setDeltaMovement
public void setDeltaMovement(Vector3d p_213317_1_)
-
setDeltaMovement
public void setDeltaMovement(double p_213293_1_, double p_213293_3_, double p_213293_5_)
-
getX
public final double getX()
-
getX
public double getX(double p_226275_1_)
-
getRandomX
public double getRandomX(double p_226282_1_)
-
getY
public final double getY()
-
getY
public double getY(double p_226283_1_)
-
getRandomY
public double getRandomY()
-
getEyeY
public double getEyeY()
-
getZ
public final double getZ()
-
getZ
public double getZ(double p_226285_1_)
-
getRandomZ
public double getRandomZ(double p_226287_1_)
-
setPosRaw
public void setPosRaw(double p_226288_1_, double p_226288_3_, double p_226288_5_)
-
checkDespawn
public void checkDespawn()
-
getRopeHoldPosition
public Vector3d getRopeHoldPosition(float p_241843_1_)
-
canUpdate
public void canUpdate(boolean value)
- Specified by:
canUpdatein interfaceIForgeEntity
-
canUpdate
public boolean canUpdate()
- Specified by:
canUpdatein interfaceIForgeEntity
-
captureDrops
public java.util.Collection<ItemEntity> captureDrops()
- Specified by:
captureDropsin interfaceIForgeEntity
-
captureDrops
public java.util.Collection<ItemEntity> captureDrops(java.util.Collection<ItemEntity> value)
- Specified by:
captureDropsin interfaceIForgeEntity
-
getPersistentData
public CompoundNBT getPersistentData()
Description copied from interface:IForgeEntityReturns a NBTTagCompound that can be used to store custom data for this entity. It will be written, and read from disc, so it persists over world saves.- Specified by:
getPersistentDatain interfaceIForgeEntity- Returns:
- A NBTTagCompound
-
canTrample
public boolean canTrample(BlockState state, BlockPos pos, float fallDistance)
Description copied from interface:IForgeEntityChecks if thisEntitycan trample aBlock.- Specified by:
canTramplein interfaceIForgeEntitypos- The block posfallDistance- The fall distance- Returns:
trueif this entity can trample,falseotherwise
-
isAddedToWorld
public final boolean isAddedToWorld()
Description copied from interface:IForgeEntityGets whether this entity has been added to a world (for tracking). Specifically between the times when an entity is added to a world and the entity being removed from the world's tracked lists. SeeWorld#onEntityAdded(Entity)andWorld#onEntityRemoved(Entity).- Specified by:
isAddedToWorldin interfaceIForgeEntity- Returns:
- True if this entity is being tracked by a world
-
onAddedToWorld
public void onAddedToWorld()
Description copied from interface:IForgeEntityCalled after the entity has been added to the world's ticking list. Can be overriden, but needs to call super to prevent MC-136995.- Specified by:
onAddedToWorldin interfaceIForgeEntity
-
onRemovedFromWorld
public void onRemovedFromWorld()
Description copied from interface:IForgeEntityCalled after the entity has been removed to the world's ticking list. Can be overriden, but needs to call super to prevent MC-136995.- Specified by:
onRemovedFromWorldin interfaceIForgeEntity
-
revive
public void revive()
Description copied from interface:IForgeEntityRevives an entity that has been removed from a world. Used as replacement for entity.removed = true. Having it as a function allows the entity to react to being revived.- Specified by:
revivein interfaceIForgeEntity
-
getEyeHeightAccess
public float getEyeHeightAccess(Pose pose, EntitySize size)
Accessor method forgetEyeHeight(Pose, EntitySize)
-
-