Class Bee
- All Implemented Interfaces:
CommandSource
,SyncedDataHolder
,FlyingAnimal
,Attackable
,EquipmentUser
,Leashable
,NeutralMob
,Targeting
,EntityAccess
,Nameable
,ScoreHolder
,IAttachmentHolder
,IEntityExtension
,ILivingEntityExtension
,INBTSerializable<CompoundTag>
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescription(package private) class
(package private) class
(package private) static class
(package private) class
class
class
(package private) class
(package private) class
(package private) class
(package private) class
(package private) class
(package private) class
Nested classes/interfaces inherited from class net.minecraft.world.entity.AgeableMob
AgeableMob.AgeableMobGroupData
Nested classes/interfaces inherited from class net.minecraft.world.entity.LivingEntity
LivingEntity.Fallsounds
Nested classes/interfaces inherited from class net.minecraft.world.entity.Entity
Entity.MoveFunction, Entity.MovementEmission, Entity.RemovalReason
Nested classes/interfaces inherited from class net.neoforged.neoforge.attachment.AttachmentHolder
AttachmentHolder.AsField
Nested classes/interfaces inherited from interface net.minecraft.world.entity.Leashable
Leashable.LeashData
-
Field Summary
FieldsModifier and TypeFieldDescription(package private) Bee.BeePollinateGoal
private static final int
private static final int
private static final EntityDataAccessor
<Byte> private static final EntityDataAccessor
<Integer> private static final int
private static final int
private static final int
static final float
(package private) Bee.BeeGoToHiveGoal
private Bee.BeeGoToKnownFlowerGoal
private static final int
private static final int
(package private) BlockPos
private static final int
private static final int
private int
private static final int
private static final UniformInt
private UUID
private static final int
private static final int
(package private) int
(package private) int
private float
private float
(package private) BlockPos
private int
private static final int
static final String
static final String
static final String
static final String
static final String
static final String
static final String
private static final int
static final int
private static final int
(package private) int
private int
private static final int
private int
Fields inherited from class net.minecraft.world.entity.animal.Animal
PARENT_AGE_AFTER_BREEDING
Fields inherited from class net.minecraft.world.entity.AgeableMob
age, BABY_START_AGE, forcedAge, forcedAgeTimer
Fields inherited from class net.minecraft.world.entity.PathfinderMob
DEFAULT_WALK_TARGET_VALUE
Fields inherited from class net.minecraft.world.entity.Mob
ambientSoundTime, armorDropChances, bodyArmorDropChance, DEFAULT_EQUIPMENT_DROP_CHANCE, goalSelector, handDropChances, jumpControl, lookControl, MAX_ENCHANTED_ARMOR_CHANCE, MAX_ENCHANTED_WEAPON_CHANCE, MAX_PICKUP_LOOT_CHANCE, MAX_WEARING_ARMOR_CHANCE, moveControl, navigation, PICKUP_REACH, PRESERVE_ITEM_DROP_CHANCE, PRESERVE_ITEM_DROP_CHANCE_THRESHOLD, RANDOM_SPAWN_BONUS_ID, targetSelector, UPDATE_GOAL_SELECTOR_EVERY_N_TICKS, xpReward
Fields inherited from class net.minecraft.world.entity.LivingEntity
animStep, animStepO, appliedScale, ARMOR_SLOT_OFFSET, ARMOR_SLOTS, attackAnim, attackStrengthTicker, ATTRIBUTES_FIELD, autoSpinAttackDmg, autoSpinAttackItemStack, autoSpinAttackTicks, BASE_JUMP_POWER, BODY_ARMOR_OFFSET, brain, damageContainers, DATA_LIVING_ENTITY_FLAGS, dead, DEATH_DURATION, deathScore, deathTime, DEFAULT_BABY_SCALE, DEFAULT_BASE_GRAVITY, EQUIPMENT_SLOT_OFFSET, EXTRA_RENDER_CULLING_SIZE_WITH_BIG_HAT, fallFlyTicks, HAND_SLOTS, hurtDuration, hurtTime, invulnerableDuration, jumping, lastHurt, lastHurtByPlayer, lastHurtByPlayerTime, lerpHeadSteps, lerpSteps, lerpX, lerpXRot, lerpY, lerpYHeadRot, lerpYRot, lerpZ, LIVING_ENTITY_FLAG_IS_USING, LIVING_ENTITY_FLAG_OFF_HAND, LIVING_ENTITY_FLAG_SPIN_ATTACK, MIN_MOVEMENT_DISTANCE, noActionTime, oAttackAnim, oRun, PLAYER_HURT_EXPERIENCE_TIME, removeArrowTime, removeStingerTime, rotA, rotOffs, run, SLEEPING_DIMENSIONS, SWING_DURATION, swinging, swingingArm, swingTime, timeOffs, USE_ITEM_INTERVAL, useItem, useItemRemaining, walkAnimation, xxa, yBodyRot, yBodyRotO, yHeadRot, yHeadRotO, yya, zza
Fields inherited from class net.minecraft.world.entity.Entity
BASE_SAFE_FALL_DISTANCE, BASE_TICKS_REQUIRED_TO_FREEZE, blocksBuilding, BOARDING_COOLDOWN, boardingCooldown, CONTENTS_SLOT_INDEX, DATA_POSE, DATA_SHARED_FLAGS_ID, DEFAULT_BB_HEIGHT, DEFAULT_BB_WIDTH, DELTA_AFFECTED_BY_BLOCKS_BELOW_0_2, DELTA_AFFECTED_BY_BLOCKS_BELOW_0_5, DELTA_AFFECTED_BY_BLOCKS_BELOW_1_0, ENTITY_COUNTER, entityData, fallDistance, firstTick, FLAG_FALL_FLYING, FLAG_GLOWING, FLAG_ONFIRE, fluidHeight, flyDist, forgeFluidTypeHeight, FREEZE_HURT_FREQUENCY, hasImpulse, horizontalCollision, hurtMarked, ID_TAG, invulnerableTime, isInPowderSnow, mainSupportingBlockPos, MAX_ENTITY_TAG_COUNT, minorHorizontalCollision, moveDist, noCulling, noPhysics, PASSENGERS_TAG, portalProcess, random, stringUUID, stuckSpeedMultiplier, tickCount, TOTAL_AIR_SUPPLY, uuid, UUID_TAG, verticalCollision, verticalCollisionBelow, walkDist, walkDistO, wasEyeInWater, wasInPowderSnow, wasOnFire, wasTouchingWater, xo, xOld, xRotO, yo, yOld, yRotO, zo, zOld
Fields inherited from class net.neoforged.neoforge.attachment.AttachmentHolder
ATTACHMENTS_NBT_KEY
Fields inherited from interface net.minecraft.commands.CommandSource
NULL
Fields inherited from interface net.minecraft.world.entity.Leashable
LEASH_ELASTIC_DIST, LEASH_TAG, LEASH_TOO_FAR_DIST
Fields inherited from interface net.minecraft.world.entity.NeutralMob
TAG_ANGER_TIME, TAG_ANGRY_AT
Fields inherited from interface net.minecraft.world.scores.ScoreHolder
WILDCARD, WILDCARD_NAME
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
addAdditionalSaveData
(CompoundTag pCompound) void
aiStep()
protected void
checkFallDamage
(double pY, boolean pOnGround, BlockState pState, BlockPos pPos) (package private) boolean
closerThan
(BlockPos pPos, int pDistance) static AttributeSupplier.Builder
protected PathNavigation
createNavigation
(Level pLevel) protected void
protected void
defineSynchedData
(SynchedEntityData.Builder pBuilder) private boolean
doesHiveHaveSpace
(BlockPos pHivePos) boolean
doHurtTarget
(Entity pEntity) void
protected SoundEvent
getBreedOffspring
(ServerLevel pLevel, AgeableMob pOtherParent) (package private) int
protected SoundEvent
private boolean
getFlag
(int pFlagId) protected SoundEvent
getHurtSound
(DamageSource pDamageSource) int
float
getRollAmount
(float pPartialTick) protected float
int
float
getWalkTargetValue
(BlockPos pPos, LevelReader pLevel) boolean
hasHive()
boolean
boolean
boolean
hasStung()
boolean
hurt
(DamageSource pSource, float pAmount) Called when the entity is attacked.(package private) void
boolean
(package private) boolean
isFlowerValid
(BlockPos pPos) boolean
isFlying()
boolean
Checks if the parameter is an item which this animal can be fed to breed it (wheat, carrots or seeds depending on the animal type)private boolean
(package private) boolean
private boolean
private boolean
(package private) boolean
isTooFarAway
(BlockPos pPos) void
jumpInFluid
(FluidType type) Performs what to do when an entity attempts to go up or "jump" in a fluid.protected void
jumpInLiquid
(TagKey<Fluid> pFluidTag) Deprecated.private void
(package private) void
protected void
playStepSound
(BlockPos pPos, BlockState pBlock) void
readAdditionalSaveData
(CompoundTag pCompound) (abstract) Protected helper method to read subclass entity data from NBT.protected void
private void
void
protected void
private void
setFlag
(int pFlagId, boolean pValue) (package private) void
setHasNectar
(boolean pHasNectar) private void
setHasStung
(boolean pHasStung) void
setHivePos
(BlockPos pHivePos) void
setPersistentAngerTarget
(UUID pTarget) void
setRemainingPersistentAngerTime
(int pTime) private void
setRolling
(boolean pIsRolling) void
setSavedFlowerPos
(BlockPos pSavedFlowerPos) void
setStayOutOfHiveCountdown
(int pStayOutOfHiveCountdown) private void
spawnFluidParticle
(Level pLevel, double pStartX, double pEndX, double pStartZ, double pEndZ, double pPosY, ParticleOptions pParticleOption) void
void
tick()
private void
(package private) boolean
Methods inherited from class net.minecraft.world.entity.animal.Animal
actuallyHurt, canFallInLove, canMate, checkAnimalSpawnRules, finalizeSpawnChildFromBreeding, getAmbientSoundInterval, getBaseExperienceReward, getInLoveTime, getLoveCause, handleEntityEvent, isBrightEnoughToSpawn, isInLove, mobInteract, removeWhenFarAway, resetLove, setInLove, setInLoveTime, spawnChildFromBreeding, usePlayerItem
Methods inherited from class net.minecraft.world.entity.AgeableMob
ageBoundaryReached, ageUp, ageUp, canBreed, finalizeSpawn, getAge, getSpeedUpSecondsWhenFeeding, isBaby, onSyncedDataUpdated, setAge, setBaby
Methods inherited from class net.minecraft.world.entity.PathfinderMob
checkSpawnRules, closeRangeLeashBehaviour, followLeashSpeed, getWalkTargetValue, handleLeashAtDistance, isPanicking, isPathFinding, shouldStayCloseToLeashHolder
Methods inherited from class net.minecraft.world.entity.Mob
ate, baseTick, canAttackType, canBeLeashed, canFireProjectileWeapon, canHoldItem, canPickUpLoot, canReplaceCurrentItem, canReplaceEqualItem, canTakeItem, canUseSlot, checkDespawn, checkMobSpawnRules, checkSpawnObstruction, clampHeadRotationToBody, clearRestriction, convertTo, createBodyControl, createMobAttributes, dropCustomDeathLoot, dropFromLootTable, dropLeash, dropPreservedEquipment, dropPreservedEquipment, enchantSpawnedArmor, enchantSpawnedWeapon, equip, equip, equipItemIfPossible, getArmorAndBodyArmorSlots, getArmorSlots, getAttackBoundingBox, getBodyArmorItem, getControllingPassenger, getDefaultLootTable, getEquipmentDropChance, getEquipmentForSlot, getHandSlots, getHeadRotSpeed, getItemBySlot, getJumpControl, getLeashData, getLookControl, getLootTable, getLootTableSeed, getMainArm, getMaxFallDistance, getMaxHeadXRot, getMaxHeadYRot, getMaxSpawnClusterSize, getMoveControl, getNavigation, getPathfindingMalus, getPickResult, getPickupReach, getRestrictCenter, getRestrictRadius, getSensing, getSpawnType, getTarget, getTargetFromBrain, hasRestriction, interact, isAggressive, isBodyArmorItem, isEffectiveAi, isLeftHanded, isMaxGroupSizeReached, isNoAi, isPersistenceRequired, isSpawnCancelled, isSunBurnTick, isWearingBodyArmor, isWithinMeleeAttackRange, isWithinRestriction, isWithinRestriction, leashTooFarBehaviour, lookAt, onOffspringSpawnedFromEgg, onPathfindingDone, onPathfindingStart, pickUpItem, playAmbientSound, playAttackSound, playHurtSound, populateDefaultEquipmentEnchantments, populateDefaultEquipmentSlots, removeAfterChangingDimensions, removeAllGoals, removeFreeWill, requiresCustomPersistence, restrictTo, serverAiStep, setAggressive, setBodyArmorItem, setCanPickUpLoot, setDropChance, setGuaranteedDrop, setItemSlot, setItemSlotAndDropWhenKilled, setLeashData, setLeftHanded, setNoAi, setPathfindingMalus, setPersistenceRequired, setSpawnCancelled, setSpeed, setTarget, setXxa, setYya, setZza, shouldDespawnInPeaceful, shouldPassengersInheritMalus, spawnAnim, startRiding, stopInPlace, tickHeadTurn, updateControlFlags, wantsToPickUp
Methods inherited from class net.minecraft.world.entity.LivingEntity
activeLocationDependentEnchantments, addEffect, addEffect, animateHurt, areAllEffectsAmbient, attackable, blockedByShield, blockUsingShield, brainProvider, calculateEntityAnimation, calculateFallDamage, canAttack, canAttack, canBeAffected, canBeSeenAsEnemy, canBeSeenByAnyone, canBreatheUnderwater, canDisableShield, canFreeze, canStandOnFluid, canUsePortal, causeFallDamage, checkAutoSpinAttack, clearSleepingPos, completeUsingItem, createLivingAttributes, createWitherRose, decreaseAirSupply, die, doAutoAttackOnTouch, doesEmitEquipEvent, doHurtEquipment, doPush, dropAllDeathLoot, dropEquipment, dropExperience, eat, eat, equipmentHasChanged, forceAddEffect, getAbsorptionAmount, getActiveEffects, getActiveEffectsMap, getAgeScale, getAllSlots, getArmorCoverPercentage, getArmorValue, getArrowCount, getAttackAnim, getAttribute, getAttributeBaseValue, getAttributes, getAttributeValue, getBedOrientation, getBlockSpeedFactor, getBoundingBoxForCulling, getBrain, getCombatTracker, getComfortableFallDistance, getCurrentSwingDuration, getDamageAfterArmorAbsorb, getDamageAfterMagicAbsorb, getDefaultDimensions, getDefaultGravity, getDimensions, getDismountPoses, getDrinkingSound, getEatingSound, getEffect, getEquipmentSlotForItem, getExperienceReward, getFallFlyingTicks, getFallSounds, getFluidFallingAdjustedMovement, getFlyingSpeed, getHealth, getHitbox, getHurtDir, getItemInHand, getJumpBoostPower, getJumpPower, getJumpPower, getKillCredit, getKnockback, getLastAttacker, getLastClimbablePos, getLastDamageSource, getLastHurtByMob, getLastHurtByMobTimestamp, getLastHurtMob, getLastHurtMobTimestamp, getLocalBoundsForPose, getMainHandItem, getMaxAbsorption, getMaxHeadRotationRelativeToBody, getMaxHealth, getNoActionTime, getOffhandItem, getPassengerRidingPosition, getPreciseBodyRotation, getProjectile, getRelativePortalPosition, getRiddenInput, getRiddenSpeed, getScale, getSleepingPos, getSlot, getSlotForHand, getSpeed, getStingerCount, getSwimAmount, getTicksUsingItem, getUsedItemHand, getUseItem, getUseItemRemainingTicks, getViewYRot, getVisibilityPercent, getVisualRotationYInDegrees, getVoicePitch, getWaterSlowDown, getWeaponItem, getYHeadRot, goDownInWater, handleDamageEvent, handleRelativeFrictionAndCalculateMovement, hasEffect, hasInfiniteMaterials, hasItemInSlot, hasLandedInLiquid, hasLineOfSight, heal, hurtArmor, hurtCurrentlyUsedShield, hurtHelmet, igniteForTicks, increaseAirSupply, indicateDamage, internalSetAbsorptionAmount, isAffectedByFluids, isAffectedByPotions, isAlive, isAlwaysExperienceDropper, isAutoSpinAttack, isBlocking, isCurrentlyGlowing, isDamageSourceBlocked, isDeadOrDying, isFallFlying, isHolding, isHolding, isImmobile, isInvertedHealAndHarm, isInvulnerableTo, isInWall, isPickable, isPushable, isSensitiveToWater, isSleeping, isSuppressingSlidingDownLadder, isUsingItem, isVisuallySwimming, jumpFromGround, kill, knockback, lerpHeadRotationStep, lerpHeadTo, lerpTargetX, lerpTargetXRot, lerpTargetY, lerpTargetYRot, lerpTargetZ, lerpTo, lookAt, makeBrain, makeSound, maxUpStep, onBelowWorld, onChangedBlock, onClimbable, onEffectAdded, onEffectRemoved, onEffectUpdated, onEnterCombat, onEquipItem, onEquippedItemBroken, onItemPickup, onLeaveCombat, playBlockFallSound, push, pushEntities, randomTeleport, recreateFromPacket, releaseUsingItem, remove, removeAllEffects, removeEffect, removeEffectNoUpdate, removeEffectParticles, removeEffectsCuredBy, removeFrost, resetForwardDirectionOfRelativePortalPosition, rideTick, sanitizeScale, sendEffectToPassengers, setAbsorptionAmount, setArrowCount, setDiscardFriction, setHealth, setItemInHand, setJumping, setLastHurtByMob, setLastHurtByPlayer, setLastHurtMob, setLivingEntityFlag, setNoActionTime, setRecordPlayingNearby, setSleepingPos, setSprinting, setStingerCount, setYBodyRot, setYHeadRot, shouldDiscardFriction, shouldDropExperience, shouldDropLoot, shouldRiderFaceForward, shouldShowName, skipDropExperience, startSleeping, startUsingItem, stopRiding, stopSleeping, stopUsingItem, swing, swing, take, tickDeath, tickEffects, tickRidden, travel, triggerItemUseEffects, triggerOnDeathMobEffects, tryAddFrost, updateEffectVisibility, updateInvisibilityStatus, updateSwingTime, updateUsingItem, updateWalkAnimation, verifyEquippedItem, wasExperienceConsumed, wouldNotSuffocateAtTargetPose
Methods inherited from class net.minecraft.world.entity.Entity
absMoveTo, absMoveTo, absRotateTo, acceptsFailure, acceptsSuccess, addDeltaMovement, addPassenger, addTag, adjustSpawnLocation, applyGravity, awardKillScore, blockPosition, broadcastToPlayer, calculateUpVector, calculateViewVector, canAddPassenger, canBeCollidedWith, canBeHitByProjectile, canChangeDimensions, canCollideWith, canControlVehicle, canRide, canSpawnSprintParticle, canSprint, canTrample, captureDrops, captureDrops, changeDimension, checkBelowWorld, checkInsideBlocks, checkSlowFallDistance, checkSupportingBlock, chunkPosition, clearFire, closerThan, closerThan, collideBoundingBox, copyPosition, couldAcceptPassenger, countPlayerPassengers, createCommandSourceStack, createHoverEvent, damageSources, dampensVibrations, deflection, discard, dismountsUnderwater, dismountTo, displayFireAnimation, distanceTo, distanceToSqr, distanceToSqr, distanceToSqr, doWaterSplashEffect, ejectPassengers, equals, extinguishFire, fillCrashReportCategory, fireImmune, fixupDimensions, fudgePositionAfterSizeChange, gameEvent, gameEvent, getAddEntityPacket, getAirSupply, getAttachments, getBbHeight, getBbWidth, getBlockExplosionResistance, getBlockJumpFactor, getBlockPosBelowThatAffectsMyMovement, getBlockStateOn, getBlockStateOnLegacy, getBlockX, getBlockY, getBlockZ, getBoundingBox, getCapability, getCapability, getCollisionHorizontalEscapeVector, getCommandSenderWorld, getControlledVehicle, getCustomName, getDefaultPassengerAttachmentPoint, getDeltaMovement, getDimensionChangingDelay, getDirection, getDismountLocationForPassenger, getDisplayName, getEncodeId, getEntityData, getEyeHeight, getEyeHeight, getEyeInFluidType, getEyePosition, getEyePosition, getEyeY, getFireImmuneTicks, getFirstPassenger, getFluidHeight, getFluidJumpThreshold, getFluidTypeHeight, getForward, getGravity, getHandHoldingItemAngle, getId, getInBlockState, getIndirectPassengers, getKnownMovement, getLeashOffset, getLightLevelDependentMagicValue, getLightProbePosition, getLookAngle, getMaxAirSupply, getMaxHeightFluidType, getMotionDirection, getMovementEmission, getName, getNearestViewDirection, getOnPos, getOnPos, getOnPosLegacy, getPassengerAttachmentPoint, getPassengers, getPassengersAndSelf, getPercentFrozen, getPermissionLevel, getPersistentData, getPickRadius, getPistonPushReaction, getPortalCooldown, getPose, getPosition, getPositionCodec, getPrimaryStepSoundBlockPos, getRandom, getRandomX, getRandomY, getRandomZ, getRemainingFireTicks, getRemovalReason, getRootVehicle, getRopeHoldPosition, getRotationVector, getScoreboardName, getSelfAndPassengers, getServer, getSharedFlag, getSoundSource, getStringUUID, getSwimHighSpeedSplashSound, getSwimSound, getSwimSplashSound, getTags, getTeam, getTeamColor, getTicksFrozen, getTicksRequiredToFreeze, getType, getTypeName, getUpVector, getUUID, getVehicle, getVehicleAttachmentPoint, getViewScale, getViewVector, getViewXRot, getX, getX, getXRot, getY, getY, getYRot, getZ, getZ, handlePortal, hasControllingPassenger, hasCustomName, hasExactlyOnePlayerPassenger, hasGlowingTag, hashCode, hasIndirectPassenger, hasPassenger, hasPassenger, hasPermissions, hasPose, igniteForSeconds, ignoreExplosion, interactAt, is, isAddedToLevel, isAlliedTo, isAlliedTo, isAlwaysTicking, isAttackable, isColliding, isControlledByLocalInstance, isCrouching, isCustomNameVisible, isDescending, isDiscrete, isEyeInFluid, isFree, isFreezing, isFullyFrozen, isHorizontalCollisionMinor, isIgnoringBlockTriggers, isInFluidType, isInFluidType, isInLava, isInLiquid, isInvisible, isInvisibleTo, isInvulnerable, isInWater, isInWaterOrBubble, isInWaterOrRain, isInWaterRainOrBubble, isNoGravity, isOnFire, isOnPortalCooldown, isOnRails, isPassenger, isPassengerOfSameVehicle, isPushedByFluid, isRemoved, isShiftKeyDown, isSilent, isSpectator, isSprinting, isSteppingCarefully, isSupportedBy, isSuppressingBounce, isSwimming, isUnderWater, isVehicle, isVisuallyCrawling, killedEntity, lavaHurt, lerpMotion, lerpPositionAndRotationStep, level, limitPistonMovement, load, makeBoundingBox, makeStuckInBlock, markHurt, maybeBackOffFromEdge, mayInteract, mirror, move, moveRelative, moveTo, moveTo, moveTo, moveTo, moveTo, moveTowardsClosestSpace, newDoubleList, newFloatList, nextStep, onAboveBubbleCol, onAddedToLevel, onClientRemoval, onExplosionHit, onFlap, onGround, onInsideBlock, onInsideBubbleColumn, onlyOpCanSetNbt, onPassengerTurned, onRemovedFromLevel, onSyncedDataUpdated, pick, placePortalTicket, playCombinationStepSounds, playEntityOnFireExtinguishedSound, playerTouch, playMuffledStepSound, playSound, playSound, playSwimSound, position, positionRider, positionRider, processFlappingMovement, processPortalCooldown, push, push, reapplyPosition, refreshDimensions, registryAccess, removePassenger, removeTag, removeVehicle, repositionEntityAfterLoad, resetFallDistance, restoreFrom, revive, rotate, save, saveAsPassenger, saveWithoutId, sendSystemMessage, setAirSupply, setAsInsidePortal, setBoundingBox, setCustomName, setCustomNameVisible, setData, setDeltaMovement, setDeltaMovement, setFluidTypeHeight, setGlowingTag, setId, setInvisible, setInvulnerable, setIsInPowderSnow, setLevel, setLevelCallback, setNoGravity, setOldPosAndRot, setOnGround, setOnGroundWithMovement, setPortalCooldown, setPortalCooldown, setPos, setPos, setPose, setPosRaw, setRemainingFireTicks, setRemoved, setRot, setSharedFlag, setSharedFlagOnFire, setShiftKeyDown, setSilent, setSwimming, setTicksFrozen, setUUID, setViewScale, setXRot, setYRot, shouldBeSaved, shouldBlockExplode, shouldInformAdmins, shouldRender, shouldRenderAtSqrDistance, showVehicleHealth, skipAttackInteraction, spawnAtLocation, spawnAtLocation, spawnAtLocation, spawnAtLocation, spawnSprintParticle, startRiding, startSeenByPlayer, stopSeenByPlayer, syncPacketPositionCodec, teleportRelative, teleportTo, teleportTo, thunderHit, toString, touchingUnloadedChunk, trackingPosition, tryCheckInsideBlocks, turn, unRide, unsetRemoved, updateDynamicGameEventListener, updateFluidHeightAndDoFluidPushing, updateFluidHeightAndDoFluidPushing, updateInWaterStateAndDoFluidPushing, updateSwimming, waterSwimSound
Methods inherited from class net.neoforged.neoforge.attachment.AttachmentHolder
deserializeAttachments, getData, getExistingDataOrNull, hasAttachments, hasData, removeData, serializeAttachments
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface net.minecraft.commands.CommandSource
alwaysAccepts
Methods inherited from interface net.minecraft.world.entity.EquipmentUser
equip, equip, equip, resolveSlot
Methods inherited from interface net.neoforged.neoforge.attachment.IAttachmentHolder
getData, getExistingData, getExistingData, getExistingDataOrNull, hasData, removeData, setData
Methods inherited from interface net.neoforged.neoforge.common.extensions.IEntityExtension
canBeRiddenUnderFluidType, canFluidExtinguish, canHydrateInFluidType, canRiderInteract, canStartSwimming, canTrample, captureDrops, captureDrops, copyAttachmentsFrom, deserializeNBT, getClassification, getEyeInFluidType, getFluidFallDistanceModifier, getFluidMotionScale, getFluidTypeHeight, getMaxHeightFluidType, getParts, getPersistentData, getPickedResult, getSoundFromFluidType, hasCustomOutlineRendering, isAddedToLevel, isEyeInFluidType, isInFluidType, isInFluidType, isInFluidType, isInFluidType, isInFluidType, isMultipartEntity, isPushedByFluid, onAddedToLevel, onRemovedFromLevel, revive, sendPairingData, serializeNBT, shouldRiderSit
Methods inherited from interface net.neoforged.neoforge.common.extensions.ILivingEntityExtension
canDrownInFluidType, canSwimInFluidType, moveInFluid, onDamageTaken, self, sinkInFluid
Methods inherited from interface net.minecraft.world.entity.Leashable
canHaveALeashAttachedToIt, elasticRangeLeashBehaviour, getLeashHolder, isLeashed, mayBeLeashed, readLeashData, setDelayedLeashHolderId, setLeashedTo, writeLeashData
Methods inherited from interface net.minecraft.world.entity.NeutralMob
addPersistentAngerSaveData, canAttack, forgetCurrentTargetAndRefreshUniversalAnger, getLastHurtByMob, getTarget, isAngry, isAngryAt, isAngryAtAllPlayers, playerDied, readPersistentAngerSaveData, setLastHurtByMob, setLastHurtByPlayer, setTarget, stopBeingAngry, updatePersistentAnger
Methods inherited from interface net.minecraft.world.scores.ScoreHolder
getFeedbackDisplayName
-
Field Details
-
FLAP_DEGREES_PER_TICK
public static final float FLAP_DEGREES_PER_TICK- See Also:
-
TICKS_PER_FLAP
public static final int TICKS_PER_FLAP -
DATA_FLAGS_ID
-
DATA_REMAINING_ANGER_TIME
-
FLAG_ROLL
private static final int FLAG_ROLL- See Also:
-
FLAG_HAS_STUNG
private static final int FLAG_HAS_STUNG- See Also:
-
FLAG_HAS_NECTAR
private static final int FLAG_HAS_NECTAR- See Also:
-
STING_DEATH_COUNTDOWN
private static final int STING_DEATH_COUNTDOWN- See Also:
-
TICKS_BEFORE_GOING_TO_KNOWN_FLOWER
private static final int TICKS_BEFORE_GOING_TO_KNOWN_FLOWER- See Also:
-
TICKS_WITHOUT_NECTAR_BEFORE_GOING_HOME
private static final int TICKS_WITHOUT_NECTAR_BEFORE_GOING_HOME- See Also:
-
MIN_ATTACK_DIST
private static final int MIN_ATTACK_DIST- See Also:
-
MAX_CROPS_GROWABLE
private static final int MAX_CROPS_GROWABLE- See Also:
-
POISON_SECONDS_NORMAL
private static final int POISON_SECONDS_NORMAL- See Also:
-
POISON_SECONDS_HARD
private static final int POISON_SECONDS_HARD- See Also:
-
TOO_FAR_DISTANCE
private static final int TOO_FAR_DISTANCE- See Also:
-
HIVE_CLOSE_ENOUGH_DISTANCE
private static final int HIVE_CLOSE_ENOUGH_DISTANCE- See Also:
-
PATHFIND_TO_HIVE_WHEN_CLOSER_THAN
private static final int PATHFIND_TO_HIVE_WHEN_CLOSER_THAN- See Also:
-
HIVE_SEARCH_DISTANCE
private static final int HIVE_SEARCH_DISTANCE- See Also:
-
TAG_CROPS_GROWN_SINCE_POLLINATION
- See Also:
-
TAG_CANNOT_ENTER_HIVE_TICKS
- See Also:
-
TAG_TICKS_SINCE_POLLINATION
- See Also:
-
TAG_HAS_STUNG
- See Also:
-
TAG_HAS_NECTAR
- See Also:
-
TAG_FLOWER_POS
- See Also:
-
TAG_HIVE_POS
- See Also:
-
PERSISTENT_ANGER_TIME
-
persistentAngerTarget
-
rollAmount
private float rollAmount -
rollAmountO
private float rollAmountO -
timeSinceSting
private int timeSinceSting -
ticksWithoutNectarSinceExitingHive
int ticksWithoutNectarSinceExitingHive -
stayOutOfHiveCountdown
private int stayOutOfHiveCountdown -
numCropsGrownSincePollination
private int numCropsGrownSincePollination -
COOLDOWN_BEFORE_LOCATING_NEW_HIVE
private static final int COOLDOWN_BEFORE_LOCATING_NEW_HIVE- See Also:
-
remainingCooldownBeforeLocatingNewHive
int remainingCooldownBeforeLocatingNewHive -
COOLDOWN_BEFORE_LOCATING_NEW_FLOWER
private static final int COOLDOWN_BEFORE_LOCATING_NEW_FLOWER- See Also:
-
remainingCooldownBeforeLocatingNewFlower
int remainingCooldownBeforeLocatingNewFlower -
savedFlowerPos
-
hivePos
-
beePollinateGoal
Bee.BeePollinateGoal beePollinateGoal -
goToHiveGoal
Bee.BeeGoToHiveGoal goToHiveGoal -
goToKnownFlowerGoal
-
underWaterTicks
private int underWaterTicks
-
-
Constructor Details
-
Bee
-
-
Method Details
-
defineSynchedData
- Overrides:
defineSynchedData
in classAgeableMob
-
getWalkTargetValue
- Overrides:
getWalkTargetValue
in classAnimal
-
registerGoals
protected void registerGoals()- Overrides:
registerGoals
in classMob
-
addAdditionalSaveData
- Overrides:
addAdditionalSaveData
in classAnimal
-
readAdditionalSaveData
(abstract) Protected helper method to read subclass entity data from NBT.- Overrides:
readAdditionalSaveData
in classAnimal
-
doHurtTarget
- Overrides:
doHurtTarget
in classMob
-
tick
public void tick() -
spawnFluidParticle
private void spawnFluidParticle(Level pLevel, double pStartX, double pEndX, double pStartZ, double pEndZ, double pPosY, ParticleOptions pParticleOption) -
pathfindRandomlyTowards
-
getSavedFlowerPos
-
hasSavedFlowerPos
public boolean hasSavedFlowerPos() -
setSavedFlowerPos
-
getTravellingTicks
public int getTravellingTicks() -
getBlacklistedHives
-
isTiredOfLookingForNectar
private boolean isTiredOfLookingForNectar() -
wantsToEnterHive
boolean wantsToEnterHive() -
setStayOutOfHiveCountdown
public void setStayOutOfHiveCountdown(int pStayOutOfHiveCountdown) -
getRollAmount
public float getRollAmount(float pPartialTick) -
updateRollAmount
private void updateRollAmount() -
customServerAiStep
protected void customServerAiStep()- Overrides:
customServerAiStep
in classAnimal
-
resetTicksWithoutNectarSinceExitingHive
public void resetTicksWithoutNectarSinceExitingHive() -
isHiveNearFire
private boolean isHiveNearFire() -
getRemainingPersistentAngerTime
public int getRemainingPersistentAngerTime()- Specified by:
getRemainingPersistentAngerTime
in interfaceNeutralMob
-
setRemainingPersistentAngerTime
public void setRemainingPersistentAngerTime(int pTime) - Specified by:
setRemainingPersistentAngerTime
in interfaceNeutralMob
-
getPersistentAngerTarget
- Specified by:
getPersistentAngerTarget
in interfaceNeutralMob
-
setPersistentAngerTarget
- Specified by:
setPersistentAngerTarget
in interfaceNeutralMob
-
startPersistentAngerTimer
public void startPersistentAngerTimer()- Specified by:
startPersistentAngerTimer
in interfaceNeutralMob
-
doesHiveHaveSpace
-
hasHive
public boolean hasHive() -
getHivePos
-
getGoalSelector
-
sendDebugPackets
protected void sendDebugPackets()- Overrides:
sendDebugPackets
in classMob
-
getCropsGrownSincePollination
int getCropsGrownSincePollination() -
resetNumCropsGrownSincePollination
private void resetNumCropsGrownSincePollination() -
incrementNumCropsGrownSincePollination
void incrementNumCropsGrownSincePollination() -
aiStep
public void aiStep() -
isHiveValid
boolean isHiveValid() -
hasNectar
public boolean hasNectar() -
setHasNectar
void setHasNectar(boolean pHasNectar) -
hasStung
public boolean hasStung() -
setHasStung
private void setHasStung(boolean pHasStung) -
isRolling
private boolean isRolling() -
setRolling
private void setRolling(boolean pIsRolling) -
isTooFarAway
-
setFlag
private void setFlag(int pFlagId, boolean pValue) -
getFlag
private boolean getFlag(int pFlagId) -
createAttributes
-
isFood
Checks if the parameter is an item which this animal can be fed to breed it (wheat, carrots or seeds depending on the animal type) -
isFlowerValid
-
playStepSound
- Overrides:
playStepSound
in classEntity
-
getAmbientSound
- Overrides:
getAmbientSound
in classMob
-
getHurtSound
- Overrides:
getHurtSound
in classLivingEntity
-
getDeathSound
- Overrides:
getDeathSound
in classLivingEntity
-
getSoundVolume
protected float getSoundVolume()- Overrides:
getSoundVolume
in classLivingEntity
-
getBreedOffspring
- Specified by:
getBreedOffspring
in classAgeableMob
-
checkFallDamage
- Overrides:
checkFallDamage
in classLivingEntity
-
isFlapping
public boolean isFlapping()- Overrides:
isFlapping
in classEntity
-
isFlying
public boolean isFlying()- Specified by:
isFlying
in interfaceFlyingAnimal
-
dropOffNectar
public void dropOffNectar() -
hurt
Called when the entity is attacked.- Overrides:
hurt
in classLivingEntity
-
jumpInLiquid
Deprecated.- Overrides:
jumpInLiquid
in classMob
-
jumpInLiquidInternal
private void jumpInLiquidInternal() -
jumpInFluid
Description copied from interface:ILivingEntityExtension
Performs what to do when an entity attempts to go up or "jump" in a fluid.- Specified by:
jumpInFluid
in interfaceILivingEntityExtension
- Overrides:
jumpInFluid
in classMob
- Parameters:
type
- the type of the fluid
-
getLeashOffset
- Overrides:
getLeashOffset
in classEntity
-
closerThan
-
setHivePos
-