public class BeeEntity extends AnimalEntity implements Flutterer
| Modifier and Type | Class and Description |
|---|---|
(package private) static class |
BeeEntity.BeeFollowTargetGoal |
(package private) class |
BeeEntity.BeeLookControl |
(package private) class |
BeeEntity.BeeRevengeGoal |
(package private) class |
BeeEntity.BeeWanderAroundGoal |
(package private) class |
BeeEntity.EnterHiveGoal |
(package private) class |
BeeEntity.FindHiveGoal |
(package private) class |
BeeEntity.GrowCropsGoal |
class |
BeeEntity.MoveToFlowerGoal |
class |
BeeEntity.MoveToHiveGoal |
(package private) class |
BeeEntity.NotAngryGoal |
(package private) class |
BeeEntity.PollinateGoal |
(package private) class |
BeeEntity.StingGoal |
PassiveEntity.PassiveDataEntity.PositionUpdater| Modifier and Type | Field and Description |
|---|---|
private static TrackedData<Integer> |
anger |
private int |
cannotEnterHiveTicks |
private int |
cropsGrownSincePollination |
private float |
currentPitch |
private BlockPos |
flowerPos |
private BlockPos |
hivePos |
private float |
lastPitch |
private BeeEntity.MoveToFlowerGoal |
moveToFlowerGoal |
private BeeEntity.MoveToHiveGoal |
moveToHiveGoal |
private static TrackedData<Byte> |
multipleByteTracker |
private BeeEntity.PollinateGoal |
pollinateGoal |
private UUID |
targetPlayer |
private int |
ticksInsideWater |
private int |
ticksLeftToFindHive |
private int |
ticksSincePollination |
private int |
ticksSinceSting |
private int |
ticksUntilCanPollinate |
breedingAge, forcedAge, happyTicksRemainingambientSoundChance, armorDropChances, experiencePoints, goalSelector, handDropChances, jumpControl, lookControl, moveControl, navigation, targetSelectoractiveItemStack, attackingPlayer, bodyTrackingIncrements, bodyYaw, brain, dead, deathTime, defaultMaximumHealth, despawnCounter, field_20347, field_6215, flyingSpeed, forwardSpeed, handSwinging, handSwingProgress, handSwingTicks, headTrackingIncrements, headYaw, hurtTime, itemUseTimeLeft, jumping, knockbackVelocity, lastAttackedTicks, lastDamageTaken, lastHandSwingProgress, lastLimbDistance, limbAngle, limbDistance, LIVING_FLAGS, lookDirection, maxHurtTime, playerHitTimer, preferredHand, prevBodyYaw, prevHeadYaw, prevLookDirection, prevStepBobbingAmount, pushCooldown, randomLargeSeed, randomSmallSeed, roll, scoreAmount, serverHeadYaw, serverPitch, serverX, serverY, serverYaw, serverZ, sidewaysSpeed, SLEEPING_DIMENSIONS, stepBobbingAmount, stuckArrowTimer, upwardSpeedage, chunkX, chunkY, chunkZ, dataTracker, dimension, distanceTraveled, fallDistance, firstUpdate, FLAGS, glowing, horizontalCollision, horizontalSpeed, ignoreCameraFrustum, inanimate, inLava, inNetherPortal, lastNetherPortalDirection, lastNetherPortalDirectionVector, lastNetherPortalPosition, lastRenderX, lastRenderY, lastRenderZ, LOGGER, movementMultiplier, netherPortalCooldown, netherPortalTime, noClip, onGround, pitch, POSE, prevHorizontalSpeed, prevPitch, prevX, prevY, prevYaw, prevZ, pushSpeedReduction, random, removed, ridingCooldown, stepHeight, submergedInWater, teleporting, timeUntilRegen, touchingWater, trackedX, trackedY, trackedZ, updateNeeded, uuid, uuidString, velocityDirty, velocityModified, verticalCollision, waterHeight, world, yawDUMMY| Constructor and Description |
|---|
BeeEntity(EntityType<? extends BeeEntity> type,
World world) |
| Modifier and Type | Method and Description |
|---|---|
private void |
addCropCounter() |
private void |
addParticle(World world,
double lastX,
double x,
double lastZ,
double z,
double y,
ParticleEffect effect) |
private boolean |
canEnterHive() |
static DefaultAttributeContainer.Builder |
createBeeAttributes() |
BeeEntity |
createChild(PassiveEntity passiveEntity) |
protected EntityNavigation |
createNavigation(World world) |
boolean |
damage(DamageSource source,
float amount) |
private boolean |
doesHiveHaveSpace(BlockPos pos) |
private boolean |
failedPollinatingTooLong() |
protected void |
fall(double heightDifference,
boolean onGround,
BlockState landedState,
BlockPos landedPosition) |
protected float |
getActiveEyeHeight(EntityPose pose,
EntityDimensions dimensions) |
protected SoundEvent |
getAmbientSound() |
private int |
getAnger() |
private boolean |
getBeeFlag(int location) |
float |
getBodyPitch(float tickDelta) |
private int |
getCropsGrownSincePollination() |
protected SoundEvent |
getDeathSound() |
BlockPos |
getFlowerPos() |
EntityGroup |
getGroup() |
BlockPos |
getHivePos() |
protected SoundEvent |
getHurtSound(DamageSource source) |
float |
getPathfindingFavor(BlockPos pos,
WorldView world) |
protected float |
getSoundVolume() |
boolean |
handleFallDamage(float fallDistance,
float damageMultiplier) |
boolean |
hasFlower() |
boolean |
hasHive() |
boolean |
hasNectar() |
boolean |
hasStung() |
protected boolean |
hasWings() |
protected void |
initDataTracker() |
protected void |
initGoals() |
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) |
protected void |
mobTick() |
void |
onHoneyDelivered() |
protected void |
playStepSound(BlockPos pos,
BlockState state) |
void |
readCustomDataFromTag(CompoundTag tag) |
private void |
resetCropCounter() |
void |
resetPollinationTicks() |
protected void |
sendAiDebugData() |
private void |
setAnger(int ticks) |
void |
setAttacker(LivingEntity attacker) |
boolean |
setBeeAttacker(Entity attacker) |
private void |
setBeeFlag(int bit,
boolean value) |
void |
setCannotEnterHiveTicks(int ticks) |
void |
setFlowerPos(BlockPos pos) |
private void |
setHasNectar(boolean hasNectar) |
private void |
setHasStung(boolean hasStung) |
private void |
setNearTarget(boolean nearTarget) |
private void |
startMovingTo(BlockPos pos) |
protected void |
swimUpward(Tag<Fluid> fluid) |
void |
tick() |
void |
tickMovement() |
boolean |
tryAttack(Entity target) |
private void |
updateBodyPitch() |
void |
writeCustomDataToTag(CompoundTag tag) |
breed, canBreedWith, canEat, canImmediatelyDespawn, eat, getCurrentExperience, getHeightOffset, getLovingPlayer, getMinAmbientSoundDelay, handleStatus, interactMob, isInLove, isValidNaturalSpawn, lovePlayer, resetLoveTicks, setLoveTicksgetBreedingAge, growUp, growUp, initialize, isBaby, isReadyToBreed, onGrowUp, onTrackedDataSet, setBaby, setBreedingAgecanSpawn, getPathfindingFavor, getRunFromLeashSpeed, isNavigating, updateForLeashLength, updateLeashattachLeash, baseTick, canBeControlledByRider, canBeLeashedBy, canEquipmentSlotContain, canGather, canMobSpawn, canMoveVoluntarily, cannotDespawn, canPickUp, canPickupItem, canPickUpLoot, canSpawn, canTarget, canTarget, checkDespawn, createBodyControl, createMobAttributes, detachLeash, dropEquipment, dropLoot, equip, equipLootStack, equipStack, getArmorItems, getBodyYawSpeed, getDropChance, getEquipmentForSlot, getEquippedStack, getHoldingEntity, getItemsHand, getJumpControl, getLimitPerChunk, getLookControl, getLookPitchSpeed, getLookYawSpeed, getLootContextBuilder, getLootTable, getLootTableId, getMainArm, getMoveControl, getNavigation, getPathfindingPenalty, getPositionTarget, getPositionTargetRange, getPreferredEquipmentSlot, getSafeFallDistance, getTarget, getVisibilityCache, hasPositionTarget, initEquipment, interact, isAiDisabled, isAttacking, isBetterItemFor, isDisallowedInPeaceful, isInDaylight, isInWalkTargetRange, isInWalkTargetRange, isLeashed, isLeftHanded, isLogicalSideForUpdatingMovement, isPersistent, lookAtEntity, loot, method_20417, method_25938, method_25939, movesIndependently, onEatingGrass, onPlayerSpawnedChild, playAmbientSound, playHurtSound, playSpawnEffects, setAiDisabled, setAttacking, setCanPickUpLoot, setEquipmentDropChance, setForwardSpeed, setHoldingEntityId, setLeftHanded, setMovementSpeed, setPathfindingPenalty, setPersistent, setPositionTarget, setSidewaysSpeed, setTarget, setUpwardSpeed, spawnsTooManyForEachTry, startRiding, tickNewAi, tryEquip, turnHead, updateEnchantmentsaddStatusEffect, animateDamage, applyArmorToDamage, applyDamage, applyEnchantmentsToDamage, applyFrostWalker, attackLivingEntity, attemptSprintingParticles, canBeRiddenInWater, canBreatheInWater, canDropLootAndXp, canHaveStatusEffect, canSee, canWalkOnLava, clearActiveItem, clearPotionSwirls, clearSleepingPosition, clearStatusEffects, collides, computeFallDamage, consumeItem, containsOnlyAmbientEffects, createLivingAttributes, createSpawnPacket, damageArmor, damageShield, deserializeBrain, destroy, drop, dropInventory, dropXp, eatFood, endCombat, enterCombat, getAbsorptionAmount, getActiveHand, getActiveItem, getActiveStatusEffects, getArmor, getArmorVisibility, getArrowType, getAttackDistanceScalingFactor, getAttacker, getAttacking, getAttribute, getAttributeInstance, getAttributes, getBaseMovementSpeedMultiplier, getBlockState, getBrain, getDamageTracker, getDespawnCounter, getDimensions, getDrinkSound, getEatSound, getEyeHeight, getFallSound, getHandSwingProgress, getHeadYaw, getHealth, getItemUseTime, getItemUseTimeLeft, getJumpVelocity, getLastAttackedTime, getLastAttackTime, getLeaningPitch, getMainHandStack, getMaximumHealth, getMovementSpeed, getNextAirOnLand, getNextAirUnderwater, getOffHandStack, getPoses, getPrimeAdversary, getRandom, getRecentDamageSource, getRoll, getScaleFactor, getSleepingDirection, getSleepingPosition, getSoundPitch, getStackInHand, getStatusEffect, getStatusEffects, getStingerCount, getStuckArrowCount, getVelocityMultiplier, getYaw, hasStackEquipped, hasStatusEffect, heal, isAffectedBySplashPotions, isAlive, isBlocking, isClimbing, isFallFlying, isHolding, isHolding, isHoldingOntoLadder, isImmobile, isInsideWall, isInSwimmingPose, isMobOrPlayer, isPushable, isSleeping, isTarget, isUndead, isUsingItem, isUsingRiptide, jump, kill, knockback, knockDownwards, lookAt, markEffectsDirty, method_24832, method_24833, method_25937, method_26081, method_26082, method_26317, method_26318, method_26826, method_27071, onAttacking, onDeath, onEquipStack, onKilledBy, onStatusEffectApplied, onStatusEffectRemoved, onStatusEffectUpgraded, playBlockFallSound, push, pushAway, pushAwayFrom, removeStatusEffect, removeStatusEffectInternal, scheduleVelocityUpdate, sendEquipmentBreakStatus, sendPickup, sendToolBreakStatus, setAbsorptionAmount, setCurrentHand, setDespawnCounter, setHeadYaw, setHealth, setJumping, setLivingFlag, setNearbySongPlaying, setOnGround, setPushCooldown, setSleepingPosition, setSprinting, setStackInHand, setStingerCount, setStuckArrowCount, setYaw, shouldAlwaysDropXp, shouldRenderName, sleep, spawnConsumptionEffects, stopRiding, stopUsingItem, swingHand, swingHand, takeKnockback, takeShieldHit, teleport, tickCramming, tickHandSwing, tickRiding, tickStatusEffects, travel, updatePostDeath, updatePotionVisibility, updateTrackedHeadRotation, updateTrackedPositionAndAngles, wakeUpaddPassenger, addScoreboardTag, addVelocity, adjustMovementForCollisions, adjustMovementForCollisions, adjustMovementForPiston, adjustMovementForSneaking, adjustSingleAxisMovementForCollisions, afterSpawn, applyMirror, applyRotation, bypassesLandingEffects, bypassesSteppingEffects, calculateBoundsForPose, calculateDimensions, calculateNextStepSoundDistance, canAddPassenger, canAvoidTraps, canBeSpectated, canClimb, canExplosionDestroyBlock, canFly, canStartRiding, canUsePortals, changeDimension, changeLookDirection, checkBlockCollision, copyFrom, copyPositionAndRotation, dealDamage, detach, distanceTo, doesNotCollide, doesRenderOnFire, dropItem, dropItem, dropStack, dropStack, entityDataRequiresOperator, equals, extinguish, fromTag, getAir, getBlockPos, getBodyY, getBoundingBox, getBrightnessAtEyes, getBurningDuration, getCameraPosVec, getCollisionBox, getCommandSource, getCustomName, getDataTracker, getDefaultName, getDefaultNetherPortalCooldown, getDisplayName, getEffectiveExplosionResistance, getEntityId, getEntityName, getEntityWorld, getEyeHeight, getEyeY, getFireTicks, getFlag, getHardCollisionBox, getHeight, getHighSpeedSplashSound, getHorizontalFacing, getHoverEvent, getItemsEquipped, getJumpVelocityMultiplier, getLandingBlockState, getLandingPos, getLastNetherPortalDirection, getLastNetherPortalDirectionVector, getMaxAir, getMaxNetherPortalTime, getMountedHeightOffset, getMovementDirection, getName, getOppositeRotationVector, getOppositeRotationVector, getParticleX, getParticleZ, getPassengerList, getPassengersDeep, getPermissionLevel, getPistonBehavior, getPitch, getPos, getPose, getPrimaryPassenger, getRandomBodyY, getRenderDistanceMultiplier, getRootVehicle, getRotationClient, getRotationVec, getRotationVecClient, getRotationVector, getRotationVector, getSavedEntityId, getScoreboardTags, getScoreboardTeam, getServer, getSoundCategory, getSplashSound, getStandingEyeHeight, getSwimSound, getTargetingMargin, getTeamColorValue, getType, getUuid, getUuidAsString, getVehicle, getVelocity, getVelocityAffectingPos, getVisibilityBoundingBox, getWaterHeight, getWidth, getX, getY, getZ, handleAttack, hasCustomName, hashCode, hasNoGravity, hasPassenger, hasPassengerDeep, hasPassengers, hasPassengerType, hasPermissionLevel, hasPlayerRider, hasVehicle, interactAt, isAttackable, isConnectedThroughVehicle, isCustomNameVisible, isDescending, isFireImmune, isGlowing, isImmuneToExplosion, isInLava, isInRange, isInsideWaterOrBubbleColumn, isInSneakingPose, isInvisible, isInvisibleTo, isInvulnerable, isInvulnerableTo, isLiving, isOnFire, isOnGround, isPartOf, isSilent, isSneaking, isSneaky, isSpectator, isSprinting, isSubmergedIn, isSubmergedIn, isSubmergedInWater, isSwimming, isTeammate, isTeamPlayer, isTouchingWater, isTouchingWaterOrRain, isWet, method_24826, method_24829, move, moveToBoundingBoxCenter, offsetX, offsetZ, onBlockCollision, onBubbleColumnCollision, onBubbleColumnSurfaceCollision, onKilledOther, onPassengerLookAround, onPlayerCollision, onStartedTrackingBy, onStoppedTrackingBy, onStruckByLightning, onSwimmingStart, playFlySound, playSound, playSwimSound, populateCrashReport, positAfterTeleport, pushOutOfBlocks, rayTrace, refreshPosition, refreshPositionAndAngles, refreshPositionAndAngles, remove, removeAllPassengers, removePassenger, removeScoreboardTag, requestTeleport, resetPosition, saveSelfToTag, saveToTag, sendSystemMessage, setAir, setBoundingBox, setCustomName, setCustomNameVisible, setEntityId, setFireTicks, setFlag, setGlowing, setInLava, setInNetherPortal, setInvisible, setInvulnerable, setNoGravity, setOnFireFor, setOnFireFromLava, setPos, setPose, setRenderDistanceMultiplier, setRotation, setSilent, setSneaking, setSwimming, setUuid, setVelocity, setVelocity, setVelocityClient, setWorld, shouldBroadcastConsoleToOps, shouldLeaveSwimmingPose, shouldReceiveFeedback, shouldRender, shouldRender, shouldSetPositionOnLoad, shouldTrackOutput, slowMovement, spawnSprintingParticles, squaredDistanceTo, squaredDistanceTo, squaredDistanceTo, squaredHorizontalLength, startRiding, streamPassengersRecursively, teleport, teleportRequested, tickNetherPortal, tickNetherPortalCooldown, toListTag, toListTag, toString, toTag, updateKilledAdvancementCriterion, updateMovementInFluid, updatePassengerPosition, updatePassengerPosition, updatePosition, updatePositionAndAngles, updatePositionsRecursively, updateSwimming, updateTrackedPosition, updateVelocity, updateWaterState, wouldPoseNotCollideprivate static final TrackedData<Byte> multipleByteTracker
private static final TrackedData<Integer> anger
private UUID targetPlayer
private float currentPitch
private float lastPitch
private int ticksSinceSting
private int ticksSincePollination
private int cannotEnterHiveTicks
private int cropsGrownSincePollination
private int ticksLeftToFindHive
private int ticksUntilCanPollinate
private BeeEntity.PollinateGoal pollinateGoal
private BeeEntity.MoveToHiveGoal moveToHiveGoal
private BeeEntity.MoveToFlowerGoal moveToFlowerGoal
private int ticksInsideWater
public BeeEntity(EntityType<? extends BeeEntity> type, World world)
protected void initDataTracker()
initDataTracker in class PassiveEntitypublic float getPathfindingFavor(BlockPos pos, WorldView world)
getPathfindingFavor in class AnimalEntitypublic void writeCustomDataToTag(CompoundTag tag)
writeCustomDataToTag in class AnimalEntitypublic void readCustomDataFromTag(CompoundTag tag)
readCustomDataFromTag in class AnimalEntityprivate void addParticle(World world, double lastX, double x, double lastZ, double z, double y, ParticleEffect effect)
private void startMovingTo(BlockPos pos)
public boolean hasFlower()
public void setFlowerPos(BlockPos pos)
private boolean failedPollinatingTooLong()
private boolean canEnterHive()
public void setCannotEnterHiveTicks(int ticks)
@Environment(value=CLIENT) public float getBodyPitch(float tickDelta)
private void updateBodyPitch()
public void setAttacker(@Nullable LivingEntity attacker)
setAttacker in class LivingEntityprotected void mobTick()
mobTick in class AnimalEntitypublic void resetPollinationTicks()
private boolean isHiveNearFire()
public boolean isAngry()
private int getAnger()
private void setAnger(int ticks)
private boolean doesHiveHaveSpace(BlockPos pos)
public boolean hasHive()
protected void sendAiDebugData()
sendAiDebugData in class MobEntityprivate int getCropsGrownSincePollination()
private void resetCropCounter()
private void addCropCounter()
public void tickMovement()
tickMovement in class AnimalEntityprivate boolean isHiveValid()
public boolean hasNectar()
private void setHasNectar(boolean hasNectar)
public boolean hasStung()
private void setHasStung(boolean hasStung)
private boolean isNearTarget()
private void setNearTarget(boolean nearTarget)
private boolean isTooFar(BlockPos pos)
private void setBeeFlag(int bit,
boolean value)
private boolean getBeeFlag(int location)
public static DefaultAttributeContainer.Builder createBeeAttributes()
protected EntityNavigation createNavigation(World world)
createNavigation in class MobEntitypublic boolean isBreedingItem(ItemStack stack)
isBreedingItem in class AnimalEntityprivate boolean isFlowers(BlockPos pos)
protected void playStepSound(BlockPos pos, BlockState state)
playStepSound in class Entityprotected SoundEvent getAmbientSound()
getAmbientSound in class MobEntityprotected SoundEvent getHurtSound(DamageSource source)
getHurtSound in class LivingEntityprotected SoundEvent getDeathSound()
getDeathSound in class LivingEntityprotected float getSoundVolume()
getSoundVolume in class LivingEntitypublic BeeEntity createChild(PassiveEntity passiveEntity)
createChild in class PassiveEntityprotected float getActiveEyeHeight(EntityPose pose, EntityDimensions dimensions)
getActiveEyeHeight in class LivingEntitypublic boolean handleFallDamage(float fallDistance,
float damageMultiplier)
handleFallDamage in class LivingEntityprotected void fall(double heightDifference,
boolean onGround,
BlockState landedState,
BlockPos landedPosition)
fall in class LivingEntitypublic void onHoneyDelivered()
public boolean setBeeAttacker(Entity attacker)
public boolean damage(DamageSource source, float amount)
damage in class AnimalEntitypublic EntityGroup getGroup()
getGroup in class LivingEntityprotected void swimUpward(Tag<Fluid> fluid)
swimUpward in class MobEntityprivate boolean isWithinDistance(BlockPos pos, int distance)