public class BeeEntity extends AnimalEntity implements IFlyingAnimal
Modifier and Type | Class and Description |
---|---|
(package private) class |
BeeEntity.AngerGoal |
(package private) static class |
BeeEntity.AttackPlayerGoal |
(package private) class |
BeeEntity.BeeLookController |
(package private) class |
BeeEntity.EnterBeehiveGoal |
class |
BeeEntity.FindBeehiveGoal |
class |
BeeEntity.FindFlowerGoal |
(package private) class |
BeeEntity.FindPollinationTargetGoal |
(package private) class |
BeeEntity.PassiveGoal |
(package private) class |
BeeEntity.PollinateGoal |
(package private) class |
BeeEntity.StingGoal |
(package private) class |
BeeEntity.UpdateBeehiveGoal |
(package private) class |
BeeEntity.WanderGoal |
AgeableEntity.AgeableData
Entity.IMoveCallback
Modifier and Type | Field and Description |
---|---|
private static DataParameter<java.lang.Integer> |
ANGER_TIME |
private static DataParameter<java.lang.Byte> |
DATA_FLAGS_ID |
private BeeEntity.FindBeehiveGoal |
findBeehiveGoal |
private BeeEntity.FindFlowerGoal |
findFlowerGoal |
private BlockPos |
hivePos |
private java.util.UUID |
lastHurtBy |
private int |
numCropsGrownSincePollination |
private BeeEntity.PollinateGoal |
pollinateGoal |
private int |
remainingCooldownBeforeLocatingNewFlower |
private int |
remainingCooldownBeforeLocatingNewHive |
private float |
rollAmount |
private float |
rollAmountO |
private BlockPos |
savedFlowerPos |
private int |
stayOutOfHiveCountdown |
private int |
ticksWithoutNectarSinceExitingHive |
private int |
timeSinceSting |
private int |
underWaterTicks |
forcedAge, forcedAgeTimer, growingAge
experienceValue, goalSelector, inventoryArmorDropChances, inventoryHandsDropChances, jumpController, livingSoundTime, lookController, moveController, navigator, targetSelector
activeItemStack, activeItemStackUseCount, arrowHitTimer, attackedAtYaw, attackingPlayer, beeStingRemovalCooldown, brain, dead, deathTime, ENTITY_GRAVITY, hurtTime, idleTime, interpTargetHeadYaw, interpTargetPitch, interpTargetX, interpTargetY, interpTargetYaw, interpTargetZ, interpTicksHead, isJumping, isSwingInProgress, jumpMovementFactor, lastDamage, limbSwing, limbSwingAmount, LIVING_FLAGS, maxHurtResistantTime, maxHurtTime, movedDistance, moveForward, moveStrafing, moveVertical, NAMETAG_DISTANCE, newPosRotationIncrements, onGroundSpeedFactor, prevLimbSwingAmount, prevMovedDistance, prevOnGroundSpeedFactor, prevRenderYawOffset, prevRotationYawHead, prevSwingProgress, randomUnused1, randomUnused2, recentlyHit, renderYawOffset, rotationYawHead, scoreValue, SLEEPING_SIZE, spinAttackDuration, SWIM_SPEED, swingingHand, swingProgress, swingProgressInt, ticksElytraFlying, ticksSinceLastSwing, unused180
addedToChunk, cachedUniqueIdString, chunkCoordX, chunkCoordY, chunkCoordZ, collided, collidedHorizontally, collidedVertically, dataManager, dimension, distanceWalkedModified, distanceWalkedOnStepModified, entityCollisionReduction, entityUniqueID, eyesInWater, fallDistance, firstUpdate, FLAGS, forceSpawn, glowing, hurtResistantTime, ignoreFrustumCheck, inLava, inPortal, inWater, isAirBorne, lastPortalPos, lastPortalVec, lastTickPosX, lastTickPosY, lastTickPosZ, LOGGER, motionMultiplier, noClip, onGround, portalCounter, POSE, prevDistanceWalkedModified, preventEntitySpawning, prevPosX, prevPosY, prevPosZ, prevRotationPitch, prevRotationYaw, rand, removed, rideCooldown, rotationPitch, rotationYaw, serverPosX, serverPosY, serverPosZ, stepHeight, submergedHeight, teleportDirection, ticksExisted, timeUntilPortal, velocityChanged, world
DUMMY
Constructor and Description |
---|
BeeEntity(EntityType<? extends BeeEntity> type,
World worldIn) |
Modifier and Type | Method and Description |
---|---|
private void |
addCropCounter() |
private void |
addParticle(World worldIn,
double p_226397_2_,
double p_226397_4_,
double p_226397_6_,
double p_226397_8_,
double posY,
IParticleData particleData) |
boolean |
attackEntityAsMob(Entity entityIn) |
boolean |
attackEntityFrom(DamageSource source,
float amount) |
private boolean |
canEnterHive() |
BeeEntity |
createChild(AgeableEntity ageable) |
protected PathNavigator |
createNavigator(World worldIn) |
private boolean |
doesHiveHaveSpace(BlockPos pos) |
private boolean |
failedPollinatingTooLong() |
protected SoundEvent |
getAmbientSound() |
private int |
getAnger() |
private boolean |
getBeeFlag(int flagId) |
float |
getBlockPathWeight(BlockPos pos,
IWorldReader worldIn) |
float |
getBodyPitch(float p_226455_1_) |
CreatureAttribute |
getCreatureAttribute() |
private int |
getCropsGrownSincePollination() |
protected SoundEvent |
getDeathSound() |
BlockPos |
getFlowerPos() |
BlockPos |
getHivePos() |
protected SoundEvent |
getHurtSound(DamageSource damageSourceIn) |
protected float |
getSoundVolume() |
protected float |
getStandingEyeHeight(Pose poseIn,
EntitySize sizeIn) |
protected void |
handleFluidJump(Tag<Fluid> fluidTag) |
boolean |
hasFlower() |
boolean |
hasHive() |
boolean |
hasNectar() |
boolean |
hasStung() |
boolean |
isAngry() |
boolean |
isBreedingItem(ItemStack stack) |
private boolean |
isFlowers(BlockPos pos) |
private boolean |
isHiveNearFire() |
private boolean |
isHiveValid() |
private boolean |
isNearTarget() |
private boolean |
isTooFar(BlockPos pos) |
private boolean |
isWithinDistance(BlockPos pos,
int distance) |
void |
livingTick() |
protected boolean |
makeFlySound() |
void |
onHoneyDelivered() |
boolean |
onLivingFall(float distance,
float damageMultiplier) |
protected void |
playStepSound(BlockPos pos,
BlockState blockIn) |
void |
readAdditional(CompoundNBT compound) |
protected void |
registerAttributes() |
protected void |
registerData() |
protected void |
registerGoals() |
private void |
resetCropCounter() |
void |
resetTicksWithoutNectar() |
protected void |
sendDebugPackets() |
private void |
setAnger(int angerTime) |
boolean |
setBeeAttacker(Entity attacker) |
private void |
setBeeFlag(int flagId,
boolean p_226404_2_) |
void |
setFlowerPos(BlockPos pos) |
private void |
setHasNectar(boolean p_226447_1_) |
private void |
setHasStung(boolean p_226449_1_) |
private void |
setNearTarget(boolean p_226452_1_) |
void |
setRevengeTarget(LivingEntity livingBase) |
void |
setStayOutOfHiveCountdown(int p_226450_1_) |
private void |
startMovingTo(BlockPos pos) |
void |
tick() |
protected void |
updateAITasks() |
private void |
updateBodyPitch() |
protected void |
updateFallState(double y,
boolean onGroundIn,
BlockState state,
BlockPos pos) |
void |
writeAdditional(CompoundNBT compound) |
canAnimalSpawn, canBreed, canDespawn, canMateWith, consumeItemFromStack, getExperiencePoints, getLoveCause, getTalkInterval, getYOffset, handleStatusUpdate, isInLove, processInteract, resetInLove, setInLove, setInLove
addGrowth, ageUp, getGrowingAge, isChild, notifyDataManagerChange, onChildSpawnFromEgg, onGrowingAdult, onInitialSpawn, setGrowingAge
canSpawn, followLeashSpeed, getBlockPathWeight, hasPath, onLeashDistance, updateLeashedState
baseTick, canAttack, canAttack, canBeLeashedTo, canBeSteered, canEquipItem, canPassengerSteer, canPickUpItem, canPickUpLoot, canSpawnOn, checkDespawn, clearLeashed, createBodyController, detachHome, dropLoot, dropSpecialItems, eatGrassBonus, enablePersistence, faceEntity, getArmorByChance, getArmorInventoryList, getAttackTarget, getDropChance, getEntitySenses, getFaceRotSpeed, getHeldEquipment, getHomePosition, getHorizontalFaceSpeed, getItemStackFromSlot, getJumpController, getLeashed, getLeashHolder, getLookController, getLootContextBuilder, getLootTable, getLootTableResourceLocation, getMaxFallHeight, getMaximumHomeDistance, getMaxSpawnedInChunk, getMoveHelper, getNavigator, getPathPriority, getPrimaryHand, getSlotForItemStack, getVerticalFaceSpeed, isAggressive, isAIDisabled, isDespawnPeaceful, isHolding, isInDaylight, isItemStackInSlot, isLeftHanded, isMaxGroupSize, isNoDespawnRequired, isNotColliding, isServerWorld, isWithinHomeDistanceCurrentPosition, isWithinHomeDistanceFromPosition, playAmbientSound, playHurtSound, preventDespawn, processInitialInteract, replaceItemInInventory, setAggroed, setAIMoveSpeed, setAttackTarget, setCanPickUpLoot, setDropChance, setEnchantmentBasedOnDifficulty, setEquipmentBasedOnDifficulty, setHomePosAndDistance, setItemStackToSlot, setLeashHolder, setLeftHanded, setMoveForward, setMoveStrafing, setMoveVertical, setNoAI, setPathPriority, setVehicleEntityId, shouldExchangeEquipment, spawnExplosionParticle, startRiding, updateDistance, updateEntityActionState, updateEquipmentIfNeeded, updateMovementGoalFlags
addPotionEffect, applyArmorCalculations, applyEntityCollision, applyPotionDamageCalculations, areAllPotionsAmbient, attackable, attemptTeleport, blockUsingShield, calculateFallDamage, canAttack, canBeCollidedWith, canBeHitWithPotion, canBePushed, canBeRiddenInWater, canBreatheUnderwater, canDropLoot, canEntityBeSeen, clearActivePotions, clearBedPosition, collideWithEntity, collideWithNearbyEntities, constructKnockBackVector, createBrain, createSpawnPacket, createWitherRose, curePotionEffects, damageArmor, damageEntity, damageShield, decreaseAirSupply, determineNextAir, dropExperience, dropInventory, findAmmo, frostWalk, getAbsorptionAmount, getActiveHand, getActiveItemStack, getActivePotionEffect, getActivePotionEffects, getActivePotionMap, getAIMoveSpeed, getAlwaysRenderNameTagForRender, getArmorCoverPercentage, getArrowCountInEntity, getAttackingEntity, getAttribute, getAttributes, getBedDirection, getBedPosition, getBeeStingCount, getBlockState, getBrain, getCapability, getCombatTracker, getDrinkSound, getEatSound, getEyeHeight, getFallSound, getHealth, getHeldItem, getHeldItemMainhand, getHeldItemOffhand, getIdleTime, getItemInUseCount, getItemInUseMaxCount, getJumpUpwardsMotion, getLastAttackedEntity, getLastAttackedEntityTime, getLastDamageSource, getMaxHealth, getRenderScale, getRevengeTarget, getRevengeTimer, getRNG, getRotationYawHead, getSize, getSoundPitch, getSwimAnimation, getSwingProgress, getTicksElytraFlying, getTotalArmorValue, getVisibilityMultiplier, getWaterSlowDown, getYaw, handleFluidSneak, hasItemInSlot, heal, isActiveItemStackBlocking, isActualySwimming, isAlive, isElytraFlying, isEntityInsideOpaqueBlock, isEntityUndead, isHandActive, isMovementBlocked, isOnLadder, isPlayer, isPotionActive, isPotionApplicable, isSleeping, isSpinAttacking, isSuppressingSlidingDownLadder, jump, knockBack, lookAt, markPotionsDirty, markVelocityChanged, onChangedPotionEffect, onDeath, onDeathUpdate, onFinishedPotionEffect, onFoodEaten, onItemPickup, onItemUseFinish, onKillCommand, onNewPotionEffect, outOfWorld, performHurtAnimation, playEquipSound, playFallSound, remove, removeActivePotionEffect, removePotionEffect, resetActiveHand, resetPotionEffectMetadata, sendBreakAnimation, sendBreakAnimation, sendEndCombat, sendEnterCombat, setAbsorptionAmount, setActiveHand, setArrowCountInEntity, setBedPosition, setBeeStingCount, setHeadRotation, setHealth, setHeldItem, setIdleTime, setJumping, setLastAttackedEntity, setLivingFlag, setPartying, setPositionAndRotationDirect, setRenderYawOffset, setRotationYawHead, setSprinting, shouldRiderFaceForward, spawnDrops, spinAttack, startSleeping, startSpinAttack, stopActiveHand, stopRiding, swing, swingArm, travel, triggerItemUseEffects, updateArmSwingProgress, updatePotionEffects, updatePotionMetadata, updateRidden, updateSpinAttack, wakeUp
addPassenger, addTag, addTrackingPlayer, addVelocity, allowLogging, applyEnchantments, applyOrientationToEntity, applyPlayerInteraction, areEyesInFluid, areEyesInFluid, awardKillScore, calculateUpVector, canBeAttackedWithItem, canBeRidden, canExplosionDestroyBlock, canFitPassenger, canRenderOnFire, canSwim, canTrample, canTriggerWalking, canUpdate, canUpdate, captureDrops, captureDrops, changeDimension, changeDimension, collideBoundingBox, collideBoundingBoxHeuristically, copyDataFromOld, copyLocationAndAnglesFrom, createRunningParticles, dealFireDamage, decrementTimeUntilPortal, detach, determineNextStepDistance, doBlockCollisions, doesEntityNotTriggerPressurePlate, doWaterSplashEffect, entityDropItem, entityDropItem, entityDropItem, entityDropItem, equals, extinguish, fillCrashReport, forceSetPosition, getAdjustedHorizontalFacing, getAir, getAllowedMovement, getBoundingBox, getBoundingBox, getBrightness, getCachedUniqueIdString, getCollisionBorderSize, getCollisionBoundingBox, getCollisionBox, getCommandSource, getControllingPassenger, getCustomName, getDataManager, getDisplayName, getDistance, getDistanceSq, getDistanceSq, getDistanceSq, getEntityId, getEntityString, getEntityWorld, getEquipmentAndArmor, getExplosionResistance, getEyeHeight, getEyeHeight, getEyePosition, getFireImmuneTicks, getFireTimer, getFlag, getForward, getHeight, getHighspeedSplashSound, getHorizontalFacing, getHoverEvent, getJumpFactor, getLastPortalVec, getLook, getLookVec, getLowestRidingEntity, getMaxAir, getMaxInPortalTime, getMirroredYaw, getMotion, getMountedYOffset, getName, getOnPosition, getPassengers, getPermissionLevel, getPersistentData, getPitch, getPitchYaw, getPortalCooldown, getPose, getPosition, getPositionUnderneath, getPositionVec, getPositionVector, getPosX, getPosXRandom, getPosXWidth, getPosY, getPosYEye, getPosYHeight, getPosYRandom, getPosZ, getPosZRandom, getPosZWidth, getProfessionName, getPushReaction, getRecursivePassengers, getRenderBoundingBox, getRenderDistanceWeight, getRidingEntity, getRotatedYaw, getScoreboardName, getSelfAndPassengers, getServer, getSoundCategory, getSpeedFactor, getSplashSound, getSubmergedHeight, getSwimSound, getTags, getTeam, getTeamColor, getTeleportDirection, getType, getUniqueID, getUpVector, getVectorForRotation, getWidth, handleFluidAcceleration, handlePistonMovement, handleWaterMovement, hasCustomName, hashCode, hasNoGravity, hasPermissionLevel, hitByEntity, horizontalMag, ignoreItemEntityData, isAddedToWorld, isBeingRidden, isBurning, isCrouching, isCustomNameVisible, isDescending, isDiscrete, isEntityEqual, isGlowing, isImmuneToExplosions, isImmuneToFire, isInLava, isInRangeToRender3d, isInRangeToRenderDist, isInvisible, isInvisibleToPlayer, isInvulnerable, isInvulnerableTo, isInWater, isInWaterOrBubbleColumn, isInWaterRainOrBubbleColumn, isLiving, isNonBoss, isOffsetPositionInLiquid, isOnePlayerRiding, isOnSameTeam, isOnScoreboardTeam, isPassenger, isPassenger, isPassenger, isPoseClear, isPushedByWater, isRidingOrBeingRiddenBy, isRidingSameEntity, isSilent, isSneaking, isSpectatedByPlayer, isSpectator, isSprinting, isSteppingCarefully, isSuppressingBounce, isSwimming, isVisuallySwimming, isWet, maybeBackOffFromEdge, move, moveForced, moveRelative, moveToBlockPosAndAngles, newDoubleNBTList, newFloatNBTList, onAddedToWorld, onCollideWithPlayer, onEnterBubbleColumn, onEnterBubbleColumnWithAirAbove, onInsideBlock, onKillEntity, onRemovedFromWorld, onStruckByLightning, pick, playFlySound, playSound, playSwimSound, positionRider, preparePlayerToSpawn, pushOutOfBlocks, read, recalculateSize, recenterBoundingBox, remove, removePassenger, removePassengers, removeTag, removeTrackingPlayer, repositionDirectPassengers, resetPositionToBB, revive, rotateTowards, sendMessage, setAir, setBoundingBox, setCustomName, setCustomNameVisible, setEntityId, setFire, setFireTimer, setFlag, setGlowing, setInLava, setInvisible, setInvulnerable, setLocationAndAngles, setMotion, setMotion, setMotionMultiplier, setNoGravity, setOnFireFromLava, setPacketCoordinates, setPortal, setPose, setPosition, setPositionAndRotation, setPositionAndUpdate, setPositionNonDirty, setRawPosition, setRenderDistanceWeight, setRotation, setSilent, setSneaking, setSwimming, setUniqueId, setVelocity, setWorld, shouldReceiveErrors, shouldReceiveFeedback, shouldSetPosAfterLoading, spawnRunningParticles, startRiding, teleportKeepLoaded, toString, updatePassenger, updatePortal, updateSwimming, writeUnlessPassenger, writeUnlessRemoved, writeWithoutTypeId
areCapsCompatible, areCapsCompatible, deserializeCaps, gatherCapabilities, gatherCapabilities, getCapabilities, invalidateCaps, reviveCaps, serializeCaps
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
canBeRiddenInWater, canRiderInteract, deserializeNBT, getClassification, getEntity, getPickedResult, serializeNBT, shouldRiderSit
getCapability
private static final DataParameter<java.lang.Byte> DATA_FLAGS_ID
private static final DataParameter<java.lang.Integer> ANGER_TIME
private java.util.UUID lastHurtBy
private float rollAmount
private float rollAmountO
private int timeSinceSting
private int ticksWithoutNectarSinceExitingHive
private int stayOutOfHiveCountdown
private int numCropsGrownSincePollination
private int remainingCooldownBeforeLocatingNewHive
private int remainingCooldownBeforeLocatingNewFlower
@Nullable private BlockPos savedFlowerPos
@Nullable private BlockPos hivePos
private BeeEntity.PollinateGoal pollinateGoal
private BeeEntity.FindBeehiveGoal findBeehiveGoal
private BeeEntity.FindFlowerGoal findFlowerGoal
private int underWaterTicks
public BeeEntity(EntityType<? extends BeeEntity> type, World worldIn)
protected void registerData()
registerData
in class AgeableEntity
public float getBlockPathWeight(BlockPos pos, IWorldReader worldIn)
getBlockPathWeight
in class AnimalEntity
protected void registerGoals()
registerGoals
in class MobEntity
public void writeAdditional(CompoundNBT compound)
writeAdditional
in class AnimalEntity
public void readAdditional(CompoundNBT compound)
readAdditional
in class AnimalEntity
public boolean attackEntityAsMob(Entity entityIn)
attackEntityAsMob
in class MobEntity
private void addParticle(World worldIn, double p_226397_2_, double p_226397_4_, double p_226397_6_, double p_226397_8_, double posY, IParticleData particleData)
private void startMovingTo(BlockPos pos)
@Nullable public BlockPos getFlowerPos()
public boolean hasFlower()
public void setFlowerPos(BlockPos pos)
private boolean failedPollinatingTooLong()
private boolean canEnterHive()
public void setStayOutOfHiveCountdown(int p_226450_1_)
public float getBodyPitch(float p_226455_1_)
private void updateBodyPitch()
public void setRevengeTarget(@Nullable LivingEntity livingBase)
setRevengeTarget
in class LivingEntity
protected void updateAITasks()
updateAITasks
in class AnimalEntity
public void resetTicksWithoutNectar()
private boolean isHiveNearFire()
public boolean isAngry()
private int getAnger()
private void setAnger(int angerTime)
private boolean doesHiveHaveSpace(BlockPos pos)
public boolean hasHive()
@Nullable public BlockPos getHivePos()
protected void sendDebugPackets()
sendDebugPackets
in class MobEntity
private int getCropsGrownSincePollination()
private void resetCropCounter()
private void addCropCounter()
public void livingTick()
livingTick
in class AnimalEntity
private boolean isHiveValid()
public boolean hasNectar()
private void setHasNectar(boolean p_226447_1_)
public boolean hasStung()
private void setHasStung(boolean p_226449_1_)
private boolean isNearTarget()
private void setNearTarget(boolean p_226452_1_)
private boolean isTooFar(BlockPos pos)
private void setBeeFlag(int flagId, boolean p_226404_2_)
private boolean getBeeFlag(int flagId)
protected void registerAttributes()
registerAttributes
in class MobEntity
protected PathNavigator createNavigator(World worldIn)
createNavigator
in class MobEntity
public boolean isBreedingItem(ItemStack stack)
isBreedingItem
in class AnimalEntity
private boolean isFlowers(BlockPos pos)
protected void playStepSound(BlockPos pos, BlockState blockIn)
playStepSound
in class Entity
protected SoundEvent getAmbientSound()
getAmbientSound
in class MobEntity
protected SoundEvent getHurtSound(DamageSource damageSourceIn)
getHurtSound
in class LivingEntity
protected SoundEvent getDeathSound()
getDeathSound
in class LivingEntity
protected float getSoundVolume()
getSoundVolume
in class LivingEntity
public BeeEntity createChild(AgeableEntity ageable)
createChild
in class AgeableEntity
protected float getStandingEyeHeight(Pose poseIn, EntitySize sizeIn)
getStandingEyeHeight
in class LivingEntity
public boolean onLivingFall(float distance, float damageMultiplier)
onLivingFall
in class LivingEntity
protected void updateFallState(double y, boolean onGroundIn, BlockState state, BlockPos pos)
updateFallState
in class LivingEntity
protected boolean makeFlySound()
makeFlySound
in class Entity
public void onHoneyDelivered()
public boolean setBeeAttacker(Entity attacker)
public boolean attackEntityFrom(DamageSource source, float amount)
attackEntityFrom
in class AnimalEntity
public CreatureAttribute getCreatureAttribute()
getCreatureAttribute
in class LivingEntity
protected void handleFluidJump(Tag<Fluid> fluidTag)
handleFluidJump
in class MobEntity
private boolean isWithinDistance(BlockPos pos, int distance)