Package net.minecraft.entity.passive
Class WolfEntity
- All Implemented Interfaces:
Angerable
,CommandOutput
,Nameable
public class WolfEntity extends TameableEntity implements Angerable
-
Nested Class Summary
Nested Classes Modifier and Type Class Description (package private) class
WolfEntity.AvoidLlamaGoal<T extends LivingEntity>
Nested classes/interfaces inherited from class net.minecraft.entity.passive.PassiveEntity
PassiveEntity.PassiveData
Nested classes/interfaces inherited from class net.minecraft.entity.Entity
Entity.PositionUpdater
-
Field Summary
Fields Modifier and Type Field Description private static TrackedData<Integer>
ANGER_TIME
private static IntRange
ANGER_TIME_RANGE
private float
begAnimationProgress
private static TrackedData<Boolean>
BEGGING
private boolean
canShakeWaterOff
private static TrackedData<Integer>
COLLAR_COLOR
static Predicate<LivingEntity>
FOLLOW_TAMED_PREDICATE
private boolean
furWet
private float
lastBegAnimationProgress
private float
lastShakeProgress
private float
shakeProgress
private UUID
targetUuid
Fields inherited from class net.minecraft.entity.passive.TameableEntity
OWNER_UUID, TAMEABLE_FLAGS
Fields inherited from class net.minecraft.entity.passive.PassiveEntity
breedingAge, forcedAge, happyTicksRemaining
Fields inherited from class net.minecraft.entity.mob.MobEntity
ambientSoundChance, armorDropChances, experiencePoints, goalSelector, handDropChances, jumpControl, lookControl, moveControl, navigation, targetSelector
Fields inherited from class net.minecraft.entity.LivingEntity
activeItemStack, attackingPlayer, bodyTrackingIncrements, bodyYaw, brain, dead, deathTime, defaultMaxHealth, despawnCounter, 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, randomLargeSeed, randomSmallSeed, riptideTicks, roll, scoreAmount, serverHeadYaw, serverPitch, serverX, serverY, serverYaw, serverZ, sidewaysSpeed, SLEEPING_DIMENSIONS, stepBobbingAmount, stuckArrowTimer, stuckStingerTimer, upwardSpeed
Fields inherited from class net.minecraft.entity.Entity
age, chunkX, chunkY, chunkZ, dataTracker, distanceTraveled, fallDistance, field_25599, firstUpdate, FLAGS, fluidHeight, glowing, horizontalCollision, horizontalSpeed, ignoreCameraFrustum, inanimate, inNetherPortal, lastNetherPortalPosition, lastRenderX, lastRenderY, lastRenderZ, LOGGER, movementMultiplier, netherPortalTime, noClip, onGround, pitch, POSE, prevHorizontalSpeed, prevPitch, prevX, prevY, prevYaw, prevZ, pushSpeedReduction, random, removed, ridingCooldown, stepHeight, submergedInWater, teleporting, timeUntilRegen, touchingWater, updateNeeded, uuid, uuidString, velocityDirty, velocityModified, verticalCollision, world, yaw
Fields inherited from interface net.minecraft.server.command.CommandOutput
DUMMY
-
Constructor Summary
Constructors Constructor Description WolfEntity(EntityType<? extends WolfEntity> type, World world)
-
Method Summary
Methods inherited from class net.minecraft.entity.passive.TameableEntity
canTarget, getOwner, getOwnerUuid, getScoreboardTeam, isInSittingPose, isOwner, isSitting, isTamed, isTeammate, onTamedChanged, setInSittingPose, setOwner, setOwnerUuid, setSitting, showEmoteParticle
Methods inherited from class net.minecraft.entity.passive.AnimalEntity
breed, canEat, canImmediatelyDespawn, eat, getCurrentExperience, getHeightOffset, getLoveTicks, getLovingPlayer, getMinAmbientSoundDelay, getPathfindingFavor, isInLove, isValidNaturalSpawn, lovePlayer, mobTick, resetLoveTicks, setLoveTicks
Methods inherited from class net.minecraft.entity.passive.PassiveEntity
getBreedingAge, growUp, growUp, initialize, isBaby, isReadyToBreed, onGrowUp, onTrackedDataSet, setBaby, setBreedingAge
Methods inherited from class net.minecraft.entity.mob.PathAwareEntity
canSpawn, getPathfindingFavor, getRunFromLeashSpeed, isNavigating, updateForLeashLength, updateLeash
Methods inherited from class net.minecraft.entity.mob.MobEntity
attachLeash, baseTick, canBeControlledByRider, canEquip, canEquipmentSlotContain, canGather, canMobSpawn, canMoveVoluntarily, cannotDespawn, canPickupItem, canPickUpLoot, canSpawn, canTarget, canUseRangedWeapon, checkDespawn, createBodyControl, createMobAttributes, createNavigation, detachLeash, dropEquipment, dropLoot, equip, equipLootStack, equipStack, getArmorItems, getBodyYawSpeed, getDropChance, getEquipmentForSlot, getEquippedStack, getHoldingEntity, getItemsHand, getJumpControl, getLookControl, getLookYawSpeed, getLootContextBuilder, getLootTable, getLootTableId, getMainArm, getMoveControl, getNavigation, getPathfindingPenalty, getPositionTarget, getPositionTargetRange, getPreferredEquipmentSlot, getSafeFallDistance, getTarget, getVisibilityCache, hasPositionTarget, initEquipment, interact, isAffectedByDaylight, isAiDisabled, isAttacking, isDisallowedInPeaceful, isInWalkTargetRange, isInWalkTargetRange, isLeashed, isLeftHanded, isLogicalSideForUpdatingMovement, isPersistent, lookAtEntity, loot, method_29243, method_29244, method_30076, method_30758, method_30759, movesIndependently, onEatingGrass, onPlayerSpawnedChild, playAmbientSound, playHurtSound, playSpawnEffects, prefersNewDamageableItem, prefersNewEquipment, sendAiDebugData, setAiDisabled, setAttacking, setCanPickUpLoot, setEquipmentDropChance, setForwardSpeed, setHoldingEntityId, setLeftHanded, setMovementSpeed, setPathfindingPenalty, setPersistent, setPositionTarget, setSidewaysSpeed, setTarget, setUpwardSpeed, spawnsTooManyForEachTry, startRiding, swimUpward, tickNewAi, tryEquip, turnHead, updateDropChances, updateEnchantments, updateGoalControls
Methods inherited from class net.minecraft.entity.LivingEntity
addSoulSpeedBoostIfNeeded, addStatusEffect, animateDamage, applyArmorToDamage, applyDamage, applyEnchantmentsToDamage, applyMovementEffects, applyStatusEffect, attackLivingEntity, canBeRiddenInWater, canBreatheInWater, canDropLootAndXp, canHaveStatusEffect, canSee, canWalkOnFluid, clearActiveItem, clearPotionSwirls, clearSleepingPosition, clearStatusEffects, collides, computeFallDamage, consumeItem, containsOnlyAmbientEffects, createBrainProfile, createLivingAttributes, createSpawnPacket, damageArmor, damageShield, deserializeBrain, destroy, displaySoulSpeedEffects, drop, dropInventory, dropXp, eatFood, endCombat, enterCombat, fall, getAbsorptionAmount, getActiveHand, getActiveItem, getActiveStatusEffects, getArmor, getArmorVisibility, getArrowType, getAttackDistanceScalingFactor, getAttacker, getAttacking, getAttributeBaseValue, getAttributeInstance, getAttributes, getAttributeValue, getBaseMovementSpeedMultiplier, getBlockState, getBoundingBox, getBrain, getClimbingPos, getDamageTracker, getDespawnCounter, getDimensions, getDrinkSound, getEatSound, getEyeHeight, getFallSound, getGroup, getHandSwingProgress, getHeadYaw, getHealth, getItemUseTime, getItemUseTimeLeft, getJumpVelocity, getLastAttackedTime, getLastAttackTime, getLeaningPitch, getMainHandStack, getMaxHealth, getMovementSpeed, getNextAirOnLand, getNextAirUnderwater, getOffHandStack, getPoses, getPrimeAdversary, getRandom, getRecentDamageSource, getRoll, getScaleFactor, getSleepingDirection, getSleepingPosition, getSoundPitch, getStackInHand, getStatusEffect, getStatusEffects, getStingerCount, getStuckArrowCount, getVelocityMultiplier, getVisibilityBoundingBox, getYaw, handleFallDamage, hasStackEquipped, hasStatusEffect, heal, hurtByWater, isAffectedBySplashPotions, isAlive, isBlocking, isClimbing, isDead, isFallFlying, isHolding, isHolding, isHoldingOntoLadder, isImmobile, isInsideWall, isInSwimmingPose, isMobOrPlayer, isOnSoulSpeedBlock, isPushable, isSleeping, isTarget, isUndead, isUsingItem, isUsingRiptide, jump, kill, knockback, knockDownwards, lookAt, markEffectsDirty, method_26317, method_26318, method_29242, method_29499, method_29500, method_29920, method_30633, method_31079, onAttacking, onEquipStack, onKilledBy, onStatusEffectApplied, onStatusEffectRemoved, onStatusEffectUpgraded, playBlockFallSound, pushAway, pushAwayFrom, removeSoulSpeedBoost, removeStatusEffect, removeStatusEffectInternal, scheduleVelocityUpdate, sendEquipmentBreakStatus, sendPickup, sendToolBreakStatus, setAbsorptionAmount, setAttacker, setAttacking, setCurrentHand, setDespawnCounter, setHeadYaw, setHealth, setJumping, setLivingFlag, setNearbySongPlaying, setOnGround, setRiptideTicks, setSleepingPosition, setSprinting, setStackInHand, setStingerCount, setStuckArrowCount, setYaw, shouldAlwaysDropXp, shouldDisplaySoulSpeedEffects, shouldDropLoot, shouldRenderName, sleep, spawnConsumptionEffects, stopRiding, stopUsingItem, swingHand, swingHand, takeKnockback, takeShieldHit, teleport, tickCramming, tickHandSwing, tickRiding, tickRiptide, tickStatusEffects, travel, updatePostDeath, updatePotionVisibility, updateTrackedHeadRotation, updateTrackedPositionAndAngles, wakeUp
Methods inherited from class net.minecraft.entity.Entity
addPassenger, addScoreboardTag, addVelocity, adjustMovementForCollisions, adjustMovementForCollisions, adjustMovementForPiston, adjustMovementForSneaking, adjustSingleAxisMovementForCollisions, afterSpawn, applyMirror, applyRotation, bypassesLandingEffects, bypassesSteppingEffects, calculateBoundsForPose, calculateDimensions, calculateNextStepSoundDistance, canAddPassenger, canAvoidTraps, canBeSpectated, canClimb, canExplosionDestroyBlock, canFly, canStartRiding, canUsePortals, changeLookDirection, checkBlockCollision, collidesWith, copyFrom, copyPositionAndRotation, dealDamage, detach, distanceTo, doesNotCollide, doesRenderOnFire, dropItem, dropItem, dropStack, dropStack, entityDataRequiresOperator, equals, extinguish, fromTag, getAir, getBlockPos, getBodyY, getBoundingBox, getBrightnessAtEyes, getBurningDuration, getCameraPosVec, getCommandSource, getCustomName, getDataTracker, getDefaultName, getDefaultNetherPortalCooldown, getDisplayName, getEffectiveExplosionResistance, getEntityId, getEntityName, getEntityWorld, getEyeHeight, getEyeY, getFireTicks, getFlag, getFluidHeight, getHeight, getHighSpeedSplashSound, getHorizontalFacing, getHoverEvent, getItemsEquipped, getJumpVelocityMultiplier, getLandingBlockState, getLandingPos, getMaxAir, getMaxNetherPortalTime, getMountedHeightOffset, getMovementDirection, getName, getOppositeRotationVector, getOppositeRotationVector, getParticleX, getParticleZ, getPassengerDismountOffset, getPassengerList, getPassengersDeep, getPermissionLevel, getPistonBehavior, getPitch, getPos, getPose, getPrimaryPassenger, getRandomBodyY, getRenderDistanceMultiplier, getRootVehicle, getRotationClient, getRotationVec, getRotationVecClient, getRotationVector, getRotationVector, getSavedEntityId, getScoreboardTags, getServer, getSoundCategory, getSplashSound, getStandingEyeHeight, getSwimSound, getTargetingMargin, getTeamColorValue, getTeleportTarget, getTrackedPosition, getType, getUuid, getUuidAsString, getVehicle, getVelocity, getVelocityAffectingPos, getWidth, getX, getY, getZ, handleAttack, hasCustomName, hashCode, hasNetherPortalCooldown, hasNoGravity, hasPassenger, hasPassengerDeep, hasPassengers, hasPassengerType, hasPermissionLevel, hasPlayerRider, hasVehicle, hasWings, interactAt, isAttackable, isChunkPosUpdateRequested, isCollidable, isConnectedThroughVehicle, isCustomNameVisible, isDescending, isFireImmune, isGlowing, isImmuneToExplosion, isInLava, isInRange, isInsideWaterOrBubbleColumn, isInSneakingPose, isInvisible, isInvisibleTo, isInvulnerable, isInvulnerableTo, isLiving, isOnFire, isOnGround, isPartOf, isSilent, isSneaking, isSneaky, isSpectator, isSprinting, isSubmergedIn, isSubmergedInWater, isSwimming, isTeamPlayer, isTouchingWater, isTouchingWaterOrRain, isWet, method_29239, method_29241, method_30330, method_30632, method_30634, method_30950, method_30951, method_31166, move, moveToBoundingBoxCenter, moveToWorld, offsetX, offsetZ, onBlockCollision, onBubbleColumnCollision, onBubbleColumnSurfaceCollision, onKilledOther, onPassengerLookAround, onPlayerCollision, onStartedTrackingBy, onStoppedTrackingBy, onStruckByLightning, onSwimmingStart, playFlySound, playSound, playSwimSound, populateCrashReport, pushOutOfBlocks, raycast, refreshPosition, refreshPositionAfterTeleport, refreshPositionAfterTeleport, refreshPositionAndAngles, refreshPositionAndAngles, remove, removeAllPassengers, removePassenger, removeScoreboardTag, requestTeleport, resetNetherPortalCooldown, resetPosition, saveSelfToTag, saveToTag, sendSystemMessage, setAir, setBoundingBox, setCustomName, setCustomNameVisible, setEntityId, setFireTicks, setFlag, setGlowing, setInNetherPortal, setInvisible, setInvulnerable, setNoGravity, setOnFireFor, setOnFireFromLava, setPos, setPose, setRenderDistanceMultiplier, setRotation, setSilent, setSneaking, setSwimming, setUuid, setVelocity, setVelocity, setVelocityClient, setWorld, shouldBroadcastConsoleToOps, shouldLeaveSwimmingPose, shouldReceiveFeedback, shouldRender, shouldRender, shouldSetPositionOnLoad, shouldSpawnSprintingParticles, shouldTrackOutput, slowMovement, spawnSprintingParticles, squaredDistanceTo, squaredDistanceTo, squaredDistanceTo, squaredHorizontalLength, startRiding, streamPassengersRecursively, teleport, teleportRequested, tickNetherPortal, tickNetherPortalCooldown, toListTag, toListTag, toString, toTag, updateKilledAdvancementCriterion, updateMovementInFluid, updatePassengerForDismount, updatePassengerPosition, updatePosition, updatePositionAndAngles, updateSwimming, updateTrackedPosition, updateTrackedPosition, updateVelocity, updateWaterState, wouldPoseNotCollide
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface net.minecraft.entity.mob.Angerable
angerFromTag, angerToTag, forgive, getTarget, hasAngerTime, isUniversallyAngry, setAttacker, setAttacking, setTarget, shouldAngerAt, stopAnger, tickAngerLogic, universallyAnger
-
Field Details
-
BEGGING
-
COLLAR_COLOR
-
ANGER_TIME
-
FOLLOW_TAMED_PREDICATE
-
ANGER_TIME_RANGE
-
begAnimationProgress
private float begAnimationProgress -
lastBegAnimationProgress
private float lastBegAnimationProgress -
furWet
private boolean furWet -
canShakeWaterOff
private boolean canShakeWaterOff -
shakeProgress
private float shakeProgress -
lastShakeProgress
private float lastShakeProgress -
targetUuid
-
-
Constructor Details
-
WolfEntity
-
-
Method Details
-
initGoals
protected void initGoals() -
createWolfAttributes
-
initDataTracker
protected void initDataTracker()- Overrides:
initDataTracker
in classTameableEntity
-
playStepSound
- Overrides:
playStepSound
in classEntity
-
writeCustomDataToTag
- Overrides:
writeCustomDataToTag
in classTameableEntity
-
readCustomDataFromTag
- Overrides:
readCustomDataFromTag
in classTameableEntity
-
getAmbientSound
- Overrides:
getAmbientSound
in classMobEntity
-
getHurtSound
- Overrides:
getHurtSound
in classLivingEntity
-
getDeathSound
- Overrides:
getDeathSound
in classLivingEntity
-
getSoundVolume
protected float getSoundVolume()- Overrides:
getSoundVolume
in classLivingEntity
-
tickMovement
public void tickMovement()- Overrides:
tickMovement
in classAnimalEntity
-
tick
public void tick() -
method_31167
private void method_31167() -
onDeath
- Overrides:
onDeath
in classTameableEntity
-
isFurWet
@Environment(CLIENT) public boolean isFurWet()Returns whether this wolf's fur is wet.The wolf's fur will remain wet until the wolf shakes.
-
getFurWetBrightnessMultiplier
@Environment(CLIENT) public float getFurWetBrightnessMultiplier(float tickDelta)Returns this wolf's brightness multiplier based on the fur wetness.The brightness multiplier represents how much darker the wolf gets while its fur is wet. The multiplier changes (from 0.75 to 1.0 incrementally) when a wolf shakes.
- Parameters:
tickDelta
- Progress for linearly interpolating between the previous and current game state.- Returns:
- Brightness as a float value between 0.75 and 1.0.
- See Also:
TintableAnimalModel.setColorMultiplier(float, float, float)
-
getShakeAnimationProgress
@Environment(CLIENT) public float getShakeAnimationProgress(float tickDelta, float float2) -
getBegAnimationProgress
@Environment(CLIENT) public float getBegAnimationProgress(float tickDelta) -
getActiveEyeHeight
- Overrides:
getActiveEyeHeight
in classLivingEntity
-
getLookPitchSpeed
public int getLookPitchSpeed()- Overrides:
getLookPitchSpeed
in classMobEntity
-
damage
- Overrides:
damage
in classAnimalEntity
-
tryAttack
-
setTamed
public void setTamed(boolean tamed)- Overrides:
setTamed
in classTameableEntity
-
interactMob
- Overrides:
interactMob
in classAnimalEntity
-
handleStatus
@Environment(CLIENT) public void handleStatus(byte status)- Overrides:
handleStatus
in classTameableEntity
-
getTailAngle
@Environment(CLIENT) public float getTailAngle() -
isBreedingItem
- Overrides:
isBreedingItem
in classAnimalEntity
-
getLimitPerChunk
public int getLimitPerChunk()- Overrides:
getLimitPerChunk
in classMobEntity
-
getAngerTime
public int getAngerTime()- Specified by:
getAngerTime
in interfaceAngerable
-
setAngerTime
public void setAngerTime(int ticks)- Specified by:
setAngerTime
in interfaceAngerable
-
chooseRandomAngerTime
public void chooseRandomAngerTime()- Specified by:
chooseRandomAngerTime
in interfaceAngerable
-
getAngryAt
- Specified by:
getAngryAt
in interfaceAngerable
-
setAngryAt
- Specified by:
setAngryAt
in interfaceAngerable
-
getCollarColor
-
setCollarColor
-
createChild
- Specified by:
createChild
in classPassiveEntity
-
setBegging
public void setBegging(boolean begging) -
canBreedWith
- Overrides:
canBreedWith
in classAnimalEntity
-
isBegging
public boolean isBegging() -
canAttackWithOwner
- Overrides:
canAttackWithOwner
in classTameableEntity
-
canBeLeashedBy
- Overrides:
canBeLeashedBy
in classTameableEntity
-
method_29919
- Overrides:
method_29919
in classEntity
-