Package net.minecraft.entity.passive
Class PandaEntity
- All Implemented Interfaces:
ICommandSource
,INameable
,ICapabilityProvider
,ICapabilitySerializable<CompoundNBT>
,IForgeEntity
,INBTSerializable<CompoundNBT>
-
Nested Class Summary
Modifier and TypeClassDescription(package private) static class
(package private) static class
PandaEntity.AvoidGoal<T extends LivingEntity>
(package private) static class
static enum
(package private) static class
(package private) class
(package private) static class
(package private) static class
(package private) static class
(package private) static class
(package private) class
(package private) static class
Nested classes/interfaces inherited from class net.minecraft.entity.AgeableEntity
AgeableEntity.AgeableData
Nested classes/interfaces inherited from class net.minecraft.entity.Entity
Entity.IMoveCallback
-
Field Summary
Modifier and TypeFieldDescriptionprivate static final EntityPredicate
private static final DataParameter<Byte>
private boolean
private static final DataParameter<Integer>
private boolean
private static final DataParameter<Byte>
private PandaEntity.WatchGoal
private static final DataParameter<Byte>
private float
private float
private static final Predicate<ItemEntity>
private float
private float
int
private Vector3d
private float
private float
private static final DataParameter<Integer>
private static final DataParameter<Integer>
Fields inherited from class net.minecraft.entity.AgeableEntity
age, forcedAge, forcedAgeTimer
Fields inherited from class net.minecraft.entity.MobEntity
ambientSoundTime, armorDropChances, goalSelector, handDropChances, jumpControl, lookControl, moveControl, navigation, targetSelector, xpReward
Fields inherited from class net.minecraft.entity.LivingEntity
animationPosition, animationSpeed, animationSpeedOld, animStep, animStepO, attackAnim, attackStrengthTicker, autoSpinAttackTicks, brain, DATA_LIVING_ENTITY_FLAGS, dead, deathScore, deathTime, fallFlyTicks, flyingSpeed, hurtDir, hurtDuration, hurtTime, invulnerableDuration, jumping, lastHurt, lastHurtByPlayer, lastHurtByPlayerTime, lerpHeadSteps, lerpSteps, lerpX, lerpXRot, lerpY, lerpYRot, lerpZ, lyHeadRot, noActionTime, oAttackAnim, oRun, removeArrowTime, removeStingerTime, rotA, rotOffs, run, SLEEPING_DIMENSIONS, swinging, swingingArm, swingTime, timeOffs, useItem, useItemRemaining, xxa, yBodyRot, yBodyRotO, yHeadRot, yHeadRotO, yya, zza
Fields inherited from class net.minecraft.entity.Entity
blocksBuilding, boardingCooldown, DATA_POSE, DATA_SHARED_FLAGS_ID, ENTITY_COUNTER, entityData, fallDistance, firstTick, fluidHeight, fluidOnEyes, forcedLoading, glowing, hasImpulse, horizontalCollision, hurtMarked, inChunk, invulnerableTime, isInsidePortal, level, LOGGER, maxUpStep, moveDist, noCulling, noPhysics, onGround, portalEntrancePos, portalTime, pushthrough, random, removed, stringUUID, stuckSpeedMultiplier, tickCount, uuid, verticalCollision, walkDist, walkDistO, wasEyeInWater, wasTouchingWater, xChunk, xo, xOld, xRot, xRotO, yChunk, yo, yOld, yRot, yRotO, zChunk, zo, zOld
Fields inherited from interface net.minecraft.command.ICommandSource
NULL
-
Constructor Summary
ConstructorDescriptionPandaEntity
(EntityType<? extends PandaEntity> p_i50252_1_, World p_i50252_2_) -
Method Summary
Modifier and TypeMethodDescriptionvoid
addAdditionalSaveData
(CompoundNBT p_213281_1_) private void
private void
boolean
canBeLeashed
(PlayerEntity p_184652_1_) boolean
boolean
canTakeItem
(ItemStack p_213365_1_) protected void
boolean
doHurtTarget
(Entity p_70652_1_) void
eat
(boolean p_213534_1_) finalizeSpawn
(IServerWorld p_213386_1_, DifficultyInstance p_213386_2_, SpawnReason p_213386_3_, ILivingEntityData p_213386_4_, CompoundNBT p_213386_5_) protected SoundEvent
getBreedOffspring
(ServerWorld p_241840_1_, AgeableEntity p_241840_2_) protected SoundEvent
private int
private boolean
getFlag
(int p_213547_1_) protected SoundEvent
getHurtSound
(DamageSource p_184601_1_) float
getLieOnBackAmount
(float p_213583_1_) private PandaEntity.Gene
float
getRollAmount
(float p_213591_1_) float
getSitAmount
(float p_213561_1_) int
int
private void
private void
boolean
hurt
(DamageSource p_70097_1_, float p_70097_2_) boolean
boolean
isEating()
boolean
private boolean
isFoodOrCake
(ItemStack p_213548_1_) boolean
isLazy()
boolean
isOnBack()
boolean
boolean
boolean
isScared()
boolean
boolean
boolean
isWeak()
boolean
mobInteract
(PlayerEntity p_230254_1_, Hand p_230254_2_) protected void
pickUpItem
(ItemEntity p_175445_1_) protected void
playStepSound
(BlockPos p_180429_1_, BlockState p_180429_2_) void
readAdditionalSaveData
(CompoundNBT p_70037_1_) protected void
void
roll
(boolean p_213576_1_) void
private void
setEatCounter
(int p_213571_1_) private void
setFlag
(int p_213587_1_, boolean p_213587_2_) void
setGeneFromParents
(PandaEntity p_213545_1_, PandaEntity p_213545_2_) void
setHiddenGene
(PandaEntity.Gene p_213541_1_) void
setMainGene
(PandaEntity.Gene p_213589_1_) void
setOnBack
(boolean p_213542_1_) void
setSneezeCounter
(int p_213562_1_) void
setUnhappyCounter
(int p_213588_1_) void
sit
(boolean p_213553_1_) void
sneeze
(boolean p_213581_1_) void
tick()
private void
tryToSit()
private void
private void
private void
Methods inherited from class net.minecraft.entity.passive.AnimalEntity
aiStep, canFallInLove, canMate, checkAnimalSpawnRules, customServerAiStep, getAmbientSoundInterval, getExperienceReward, getInLoveTime, getLoveCause, getMyRidingOffset, getWalkTargetValue, handleEntityEvent, isInLove, removeWhenFarAway, resetLove, setInLove, setInLoveTime, spawnChildFromBreeding, usePlayerItem
Methods inherited from class net.minecraft.entity.AgeableEntity
ageBoundaryReached, ageUp, ageUp, canBreed, getAge, isBaby, onSyncedDataUpdated, setAge, setBaby
Methods inherited from class net.minecraft.entity.CreatureEntity
checkSpawnRules, followLeashSpeed, getWalkTargetValue, isPathFinding, onLeashDistance, tickLeash
Methods inherited from class net.minecraft.entity.MobEntity
ate, baseTick, canAttack, canAttackType, canBeControlledByRider, canCutCorner, canFireProjectileWeapon, canHoldItem, canPickUpLoot, canReplaceCurrentItem, canReplaceEqualItem, checkDespawn, checkMobSpawnRules, checkSpawnObstruction, convertTo, createBodyControl, createLootContext, createMobAttributes, createNavigation, dropCustomDeathLoot, dropFromLootTable, dropLeash, enchantSpawnedArmor, enchantSpawnedWeapon, equipItemIfPossible, getArmorSlots, getDefaultLootTable, getEquipmentDropChance, getEquipmentForSlot, getEquipmentSlotForItem, getHandSlots, getHeadRotSpeed, getItemBySlot, getJumpControl, getLeashHolder, getLookControl, getLootTable, getMainArm, getMaxFallDistance, getMaxHeadXRot, getMaxHeadYRot, getMaxSpawnClusterSize, getMoveControl, getNavigation, getPathfindingMalus, getRestrictCenter, getRestrictRadius, getSensing, getTarget, hasRestriction, interact, isControlledByLocalInstance, isEffectiveAi, isLeashed, isLeftHanded, isMaxGroupSizeReached, isNoAi, isPersistenceRequired, isSunBurnTick, isValidSlotForItem, isWithinRestriction, isWithinRestriction, jumpInLiquid, lookAt, onOffspringSpawnedFromEgg, playAmbientSound, playHurtSound, populateDefaultEquipmentEnchantments, populateDefaultEquipmentSlots, removeAfterChangingDimensions, requiresCustomPersistence, restrictTo, sendDebugPackets, serverAiStep, setAggressive, setCanPickUpLoot, setDelayedLeashHolderId, setDropChance, setGuaranteedDrop, setItemSlot, setItemSlotAndDropWhenKilled, setLeashedTo, setLeftHanded, setNoAi, setPathfindingMalus, setPersistenceRequired, setSlot, setSpeed, setTarget, setXxa, setYya, setZza, shouldDespawnInPeaceful, shouldPassengersInheritMalus, spawnAnim, startRiding, tickHeadTurn, updateControlFlags, wantsToPickUp
Methods inherited from class net.minecraft.entity.LivingEntity
actuallyHurt, addEffect, animateHurt, areAllEffectsAmbient, attackable, blockedByShield, blockUsingShield, brainProvider, broadcastBreakEvent, broadcastBreakEvent, calculateEntityAnimation, calculateFallDamage, canAttack, canBeAffected, canBreatheUnderwater, canSee, canSpawnSoulSpeedParticle, canStandOnFluid, causeFallDamage, checkAutoSpinAttack, checkFallDamage, clearSleepingPos, completeUsingItem, createLivingAttributes, createWitherRose, curePotionEffects, decreaseAirSupply, die, doAutoAttackOnTouch, doPush, dropAllDeathLoot, dropEquipment, dropExperience, eat, forceAddEffect, getAbsorptionAmount, getActiveEffects, getActiveEffectsMap, getAddEntityPacket, getArmorCoverPercentage, getArmorValue, getArrowCount, getAttackAnim, getAttribute, getAttributeBaseValue, getAttributes, getAttributeValue, getBedOrientation, getBlockSpeedFactor, getBoundingBoxForCulling, getBrain, getCapability, getCombatTracker, getDamageAfterArmorAbsorb, getDamageAfterMagicAbsorb, getDimensions, getDismountPoses, getDrinkingSound, getEatingSound, getEffect, getEyeHeight, getFallDamageSound, getFallFlyingTicks, getFeetBlockState, getFluidFallingAdjustedMovement, getHealth, getItemInHand, getJumpPower, getKillCredit, getLastClimbablePos, getLastDamageSource, getLastHurtByMob, getLastHurtByMobTimestamp, getLastHurtMob, getLastHurtMobTimestamp, getLocalBoundsForPose, getMainHandItem, getMaxHealth, getMobType, getNoActionTime, getOffhandItem, getProjectile, getRandom, getRelativePortalPosition, getScale, getSleepingPos, getSoundVolume, getSpeed, getStandingEyeHeight, getStingerCount, getSwimAmount, getTicksUsingItem, getUsedItemHand, getUseItem, getUseItemRemainingTicks, getViewYRot, getVisibilityPercent, getVoicePitch, getWaterSlowDown, getYHeadRot, goDownInWater, handleRelativeFrictionAndCalculateMovement, hasEffect, hasItemInSlot, heal, hurtArmor, hurtCurrentlyUsedShield, increaseAirSupply, invalidateCaps, isAffectedByFluids, isAffectedByPotions, isAlive, isAlwaysExperienceDropper, isAutoSpinAttack, isBlocking, isDeadOrDying, isFallFlying, isHolding, isHolding, isImmobile, isInvertedHealAndHarm, isInWall, isPickable, isPushable, isSensitiveToWater, isSleeping, isSuppressingSlidingDownLadder, isUsingItem, isVisuallySwimming, jumpFromGround, kill, knockback, lerpHeadTo, lerpTo, lookAt, makeBrain, markHurt, onChangedBlock, onClimbable, onEffectAdded, onEffectRemoved, onEffectUpdated, onEnterCombat, onItemPickup, onLeaveCombat, onSoulSpeedBlock, outOfWorld, playBlockFallSound, playEquipSound, push, pushEntities, randomTeleport, releaseUsingItem, removeAllEffects, removeEffect, removeEffectNoUpdate, removeEffectParticles, removeSoulSpeed, resetForwardDirectionOfRelativePortalPosition, rideableUnderWater, rideTick, setAbsorptionAmount, setArrowCount, setHealth, setItemInHand, setJumping, setLastHurtByMob, setLastHurtByPlayer, setLastHurtMob, setLivingEntityFlag, setNoActionTime, setOnGround, setRecordPlayingNearby, setSleepingPos, setSprinting, setStingerCount, setYBodyRot, setYHeadRot, shouldDropExperience, shouldDropLoot, shouldRemoveSoulSpeed, shouldRiderFaceForward, shouldShowName, spawnSoulSpeedParticle, startAutoSpinAttack, startSleeping, startUsingItem, stopRiding, stopSleeping, stopUsingItem, swing, swing, take, tickDeath, tickEffects, travel, triggerItemUseEffects, tryAddSoulSpeed, updateEffectVisibility, updateInvisibilityStatus, updateSwingTime
Methods inherited from class net.minecraft.entity.Entity
absMoveTo, absMoveTo, acceptsFailure, acceptsSuccess, addPassenger, addTag, awardKillScore, blockPosition, broadcastToPlayer, calculateUpVector, calculateViewVector, canAddPassenger, canBeCollidedWith, canChangeDimensions, canCollideWith, canEnterPose, canRide, canSpawnSprintParticle, canTrample, canUpdate, canUpdate, captureDrops, captureDrops, changeDimension, changeDimension, checkAndResetForcedChunkAdditionFlag, checkAndResetUpdateChunkPos, checkInsideBlocks, clearFire, closerThan, collideBoundingBox, collideBoundingBoxHeuristically, collideBoundingBoxLegacy, copyPosition, createCommandSourceStack, createHoverEvent, displayFireAnimation, distanceTo, distanceToSqr, distanceToSqr, distanceToSqr, doEnchantDamageEffects, doWaterSplashEffect, ejectPassengers, equals, fillCrashReportCategory, findDimensionEntryPoint, fireImmune, getAirSupply, getAllSlots, getBbHeight, getBbWidth, getBlockExplosionResistance, getBlockJumpFactor, getBlockPosBelowThatAffectsMyMovement, getBlockStateOn, getBoundingBox, getBoundingBoxForPose, getBrightness, getCollisionHorizontalEscapeVector, getCommandSenderWorld, getControllingPassenger, getCustomName, getDeltaMovement, getDimensionChangingDelay, getDirection, getDismountLocationForPassenger, getDisplayName, getEncodeId, getEntityData, getExitPortal, getEyeHeight, getEyeHeight, getEyeHeightAccess, getEyePosition, getEyeY, getFireImmuneTicks, getFluidHeight, getFluidJumpThreshold, getForward, getHorizontalDistanceSqr, getId, getIndirectPassengers, getLeashOffset, getLightProbePosition, getLookAngle, getMaxAirSupply, getMotionDirection, getName, getOnPos, getPacketCoordinates, getPassengers, getPassengersRidingOffset, getPermissionLevel, getPersistentData, getPickRadius, getPistonPushReaction, getPortalWaitTime, getPose, getPosition, getRandomX, getRandomY, getRandomZ, getRemainingFireTicks, getRootVehicle, getRopeHoldPosition, getRotationVector, getScoreboardName, getSelfAndPassengers, getServer, getSharedFlag, getSoundSource, getStringUUID, getSwimHighSpeedSplashSound, getSwimSound, getSwimSplashSound, getTags, getTeam, getTeamColor, getType, getTypeName, getUpVector, getUUID, getVehicle, getViewScale, getViewVector, getViewXRot, getX, getX, getY, getY, getZ, getZ, handleInsidePortal, handleNetherPortal, hasCustomName, hashCode, hasIndirectPassenger, hasOnePlayerPassenger, hasPassenger, hasPassenger, hasPermissions, ignoreExplosion, interactAt, is, isAddedToWorld, isAlliedTo, isAlliedTo, isAttackable, isColliding, isCrouching, isCustomNameVisible, isDescending, isDiscrete, isEyeInFluid, isFree, isGlowing, isIgnoringBlockTriggers, isInLava, isInvisible, isInvisibleTo, isInvulnerable, isInvulnerableTo, isInWater, isInWaterOrBubble, isInWaterOrRain, isInWaterRainOrBubble, isMovementNoisy, isNoGravity, isOnFire, isOnGround, isOnPortalCooldown, isPassenger, isPassengerOfSameVehicle, isPushedByFluid, isShiftKeyDown, isSilent, isSpectator, isSprinting, isSteppingCarefully, isSuppressingBounce, isSwimming, isUnderWater, isVehicle, isVisuallyCrawling, killed, lavaHurt, lerpMotion, limitPistonMovement, load, makeFlySound, makeStuckInBlock, maybeBackOffFromEdge, mirror, move, moveRelative, moveTo, moveTo, moveTo, moveTo, moveTowardsClosestSpace, newDoubleList, newFloatList, nextStep, onAboveBubbleCol, onAddedToWorld, onInsideBlock, onInsideBubbleColumn, onlyOpCanSetNbt, onPassengerTurned, onRemovedFromWorld, pick, playerTouch, playFlySound, playSound, playSwimSound, position, positionRider, processPortalCooldown, push, reapplyPosition, refreshDimensions, remove, remove, removePassenger, removeTag, removeVehicle, repositionEntityAfterLoad, resetPos, restoreFrom, revive, rotate, save, saveAsPassenger, saveWithoutId, sendMessage, setAirSupply, setBoundingBox, setCustomName, setCustomNameVisible, setDeltaMovement, setDeltaMovement, setGlowing, setId, setInvisible, setInvulnerable, setLevel, setLocationFromBoundingbox, setNoGravity, setPacketCoordinates, setPacketCoordinates, setPortalCooldown, setPos, setPosAndOldPos, setPose, setPosRaw, setRemainingFireTicks, setRot, setSecondsOnFire, setSharedFlag, setShiftKeyDown, setSilent, setSwimming, setUUID, setViewScale, shouldBlockExplode, shouldInformAdmins, shouldRender, shouldRenderAtSqrDistance, showVehicleHealth, skipAttackInteraction, spawnAtLocation, spawnAtLocation, spawnAtLocation, spawnAtLocation, spawnSprintParticle, startRiding, startSeenByPlayer, stopSeenByPlayer, teleportTo, teleportToWithTicket, thunderHit, toString, turn, unRide, updateFluidHeightAndDoFluidPushing, updateInWaterStateAndDoFluidPushing, updateSwimming
Methods inherited from class net.minecraftforge.common.capabilities.CapabilityProvider
areCapsCompatible, areCapsCompatible, deserializeCaps, gatherCapabilities, gatherCapabilities, gatherCapabilities, getCapabilities, 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
Methods inherited from interface net.minecraftforge.common.extensions.IForgeEntity
canBeRiddenInWater, canRiderInteract, deserializeNBT, getClassification, getDimensionsForge, getEntity, getEyeHeightForge, getParts, getPickedResult, isMultipartEntity, serializeNBT, shouldRiderSit
-
Field Details
-
UNHAPPY_COUNTER
-
SNEEZE_COUNTER
-
EAT_COUNTER
-
MAIN_GENE_ID
-
HIDDEN_GENE_ID
-
DATA_ID_FLAGS
-
BREED_TARGETING
-
gotBamboo
private boolean gotBamboo -
didBite
private boolean didBite -
rollCounter
public int rollCounter -
rollDelta
-
sitAmount
private float sitAmount -
sitAmountO
private float sitAmountO -
onBackAmount
private float onBackAmount -
onBackAmountO
private float onBackAmountO -
rollAmount
private float rollAmount -
rollAmountO
private float rollAmountO -
lookAtPlayerGoal
-
PANDA_ITEMS
-
-
Constructor Details
-
PandaEntity
-
-
Method Details
-
canTakeItem
- Overrides:
canTakeItem
in classMobEntity
-
getUnhappyCounter
public int getUnhappyCounter() -
setUnhappyCounter
public void setUnhappyCounter(int p_213588_1_) -
isSneezing
public boolean isSneezing() -
isSitting
public boolean isSitting() -
sit
public void sit(boolean p_213553_1_) -
isOnBack
public boolean isOnBack() -
setOnBack
public void setOnBack(boolean p_213542_1_) -
isEating
public boolean isEating() -
eat
public void eat(boolean p_213534_1_) -
getEatCounter
private int getEatCounter() -
setEatCounter
private void setEatCounter(int p_213571_1_) -
sneeze
public void sneeze(boolean p_213581_1_) -
getSneezeCounter
public int getSneezeCounter() -
setSneezeCounter
public void setSneezeCounter(int p_213562_1_) -
getMainGene
-
setMainGene
-
getHiddenGene
-
setHiddenGene
-
isRolling
public boolean isRolling() -
roll
public void roll(boolean p_213576_1_) -
defineSynchedData
protected void defineSynchedData()- Overrides:
defineSynchedData
in classAgeableEntity
-
getFlag
private boolean getFlag(int p_213547_1_) -
setFlag
private void setFlag(int p_213587_1_, boolean p_213587_2_) -
addAdditionalSaveData
- Overrides:
addAdditionalSaveData
in classAnimalEntity
-
readAdditionalSaveData
- Overrides:
readAdditionalSaveData
in classAnimalEntity
-
getBreedOffspring
@Nullable public AgeableEntity getBreedOffspring(ServerWorld p_241840_1_, AgeableEntity p_241840_2_) - Specified by:
getBreedOffspring
in classAgeableEntity
-
registerGoals
protected void registerGoals()- Overrides:
registerGoals
in classMobEntity
-
createAttributes
-
getVariant
-
isLazy
public boolean isLazy() -
isWorried
public boolean isWorried() -
isPlayful
public boolean isPlayful() -
isWeak
public boolean isWeak() -
isAggressive
public boolean isAggressive()- Overrides:
isAggressive
in classMobEntity
-
canBeLeashed
- Overrides:
canBeLeashed
in classMobEntity
-
doHurtTarget
- Overrides:
doHurtTarget
in classMobEntity
-
tick
public void tick() -
isScared
public boolean isScared() -
handleEating
private void handleEating() -
addEatingParticles
private void addEatingParticles() -
updateSitAmount
private void updateSitAmount() -
updateOnBackAnimation
private void updateOnBackAnimation() -
updateRollAmount
private void updateRollAmount() -
getSitAmount
public float getSitAmount(float p_213561_1_) -
getLieOnBackAmount
public float getLieOnBackAmount(float p_213583_1_) -
getRollAmount
public float getRollAmount(float p_213591_1_) -
handleRoll
private void handleRoll() -
afterSneeze
private void afterSneeze() -
pickUpItem
- Overrides:
pickUpItem
in classMobEntity
-
hurt
- Overrides:
hurt
in classAnimalEntity
-
finalizeSpawn
@Nullable public ILivingEntityData finalizeSpawn(IServerWorld p_213386_1_, DifficultyInstance p_213386_2_, SpawnReason p_213386_3_, @Nullable ILivingEntityData p_213386_4_, @Nullable CompoundNBT p_213386_5_) - Overrides:
finalizeSpawn
in classAgeableEntity
-
setGeneFromParents
-
getOneOfGenesRandomly
-
setAttributes
public void setAttributes() -
tryToSit
private void tryToSit() -
mobInteract
- Overrides:
mobInteract
in classAnimalEntity
-
getAmbientSound
- Overrides:
getAmbientSound
in classMobEntity
-
playStepSound
- Overrides:
playStepSound
in classEntity
-
isFood
- Overrides:
isFood
in classAnimalEntity
-
isFoodOrCake
-
getDeathSound
- Overrides:
getDeathSound
in classLivingEntity
-
getHurtSound
- Overrides:
getHurtSound
in classLivingEntity
-
canPerformAction
public boolean canPerformAction()
-