net.minecraft.entity.passive

public abstract class TameableEntity

extends AnimalEntity implements Tameable

All mapped superinterfaces:

Nameable, EntityLike, UniquelyIdentifiable, ScoreHolder, DataTracked, ComponentsAccess, HeldItemContext, StackReferenceGetter, DebugTrackable, Attackable, ServerWaypoint, Waypoint, Targeter, EquipmentHolder, Leashable, Tameable

net.minecraft.world.entity.TamableAnimal
net.minecraft.class_1321
net.minecraft.entity.passive.TameableEntity

Field summary

Modifier and TypeField
public static final int
TELEPORT_WHEN_DISTANCE_IS_SQ
field_52002
field_52002
private static final int
MIN_HORIZONTAL_DISTANCE_FROM_TARGET_AFTER_TELEPORTING
field_52003
field_52003
private static final int
MAX_HORIZONTAL_DISTANCE_FROM_TARGET_AFTER_TELEPORTING
field_52004
field_52004
private static final int
MAX_VERTICAL_DISTANCE_FROM_TARGET_AFTER_TELEPORTING
field_52005
field_52005
private static final boolean
DEFAULT_ORDERED_TO_SIT
field_57595
DEFAULT_SITTING
protected static final TrackedData<Byte>
DATA_FLAGS_ID
field_6322
TAMEABLE_FLAGS
protected static final TrackedData<Optional<LazyEntityReference<LivingEntity>>>
DATA_OWNERUUID_ID
field_6320
OWNER_UUID
private boolean
orderedToSit
field_21974
sitting

Constructor summary

ModifierConstructor
protected (EntityType<? extends TameableEntity> type, World level)

Method summary

Modifier and TypeMethod
protected void
defineSynchedData(SynchedEntityData$Builder entityData)
method_5693(class_2945$class_9222 arg0)
initDataTracker(DataTracker$Builder arg0)
protected void
addAdditionalSaveData(ValueOutput output)
method_5652(class_11372 arg0)
writeCustomData(WriteView arg0)
protected void
readAdditionalSaveData(ValueInput input)
method_5749(class_11368 arg0)
readCustomData(ReadView arg0)
public boolean
canBeLeashed()
method_5931()
canBeLeashed()
protected void
spawnTamingParticles(boolean success)
method_6180(boolean arg0)
showEmoteParticle(boolean positive)
public void
handleEntityEvent(byte id)
method_5711(byte arg0)
handleStatus(byte arg0)
public boolean
isTame()
method_6181()
isTamed()
public void
setTame(boolean isTame, boolean includeSideEffects)
method_6173(boolean arg0, boolean arg1)
setTamed(boolean tamed, boolean updateAttributes)
protected void
applyTamingSideEffects()
method_56996()
updateAttributesForTamed()
public boolean
isInSittingPose()
method_6172()
isInSittingPose()
public void
setInSittingPose(boolean value)
method_6179(boolean arg0)
setInSittingPose(boolean inSittingPose)
public LazyEntityReference<LivingEntity>
getOwnerReference()
method_66287()
getOwnerReference()
public void
setOwner(LivingEntity owner)
method_6174(class_1309 arg0)
setOwner(LivingEntity owner)
public void
setOwnerReference(EntityReference<LivingEntity> owner)
method_66288(class_10583<class_1309> arg0)
setOwner(LazyEntityReference<LivingEntity> owner)
public void
tame(Player player)
method_6170(class_1657 arg0)
setTamedBy(PlayerEntity player)
public boolean
canAttack(LivingEntity target)
method_18395(class_1309 arg0)
canTarget(LivingEntity arg0)
public boolean
isOwnedBy(LivingEntity entity)
method_6171(class_1309 arg0)
isOwner(LivingEntity entity)
public boolean
wantsToAttack(LivingEntity target, LivingEntity owner)
method_6178(class_1309 arg0, class_1309 arg1)
canAttackWithOwner(LivingEntity target, LivingEntity owner)
public Team
getTeam()
method_5781()
getScoreboardTeam()
protected boolean
considersEntityAsAlly(Entity other)
method_61416(class_1297 arg0)
isInSameTeam(Entity arg0)
public void
die(DamageSource source)
method_6078(class_1282 arg0)
onDeath(DamageSource arg0)
public boolean
isOrderedToSit()
method_24345()
isSitting()
public void
setOrderedToSit(boolean orderedToSit)
method_24346(boolean arg0)
setSitting(boolean sitting)
public void
tryToTeleportToOwner()
method_60713()
tryTeleportToOwner()
public boolean
shouldTryTeleportToOwner()
method_60714()
shouldTryTeleportToOwner()
private void
teleportToAroundBlockPos(BlockPos targetPos)
method_60712(class_2338 arg0)
tryTeleportNear(BlockPos pos)
private boolean
maybeTeleportTo(int x, int y, int z)
method_60711(int arg0, int arg1, int arg2)
tryTeleportTo(int x, int y, int z)
private boolean
canTeleportTo(BlockPos pos)
method_60717(class_2338 arg0)
canTeleportTo(BlockPos pos)
public final boolean
unableToMoveToOwner()
method_60715()
cannotFollowOwner()
protected boolean
canFlyToOwner()
method_60716()
canTeleportOntoLeaves()