Package net.minecraft.world.entity
Interface Leashable
- All Known Implementing Classes:
AbstractChestedHorse,AbstractFish,AbstractGolem,AbstractHorse,AbstractIllager,AbstractPiglin,AbstractSchoolingFish,AbstractSkeleton,AbstractVillager,AgeableMob,Allay,AmbientCreature,Animal,Armadillo,Axolotl,Bat,Bee,Blaze,Boat,Bogged,Breeze,Camel,Cat,CaveSpider,ChestBoat,Chicken,Cod,Cow,Creeper,Dolphin,Donkey,Drowned,ElderGuardian,EnderDragon,EnderMan,Endermite,Evoker,FlyingMob,Fox,Frog,Ghast,Giant,GlowSquid,Goat,Guardian,Hoglin,Horse,Husk,Illusioner,IronGolem,Llama,MagmaCube,Mob,Monster,Mule,MushroomCow,Ocelot,Panda,Parrot,PartEntityTest.TestEntity,PathfinderMob,PatrollingMonster,Phantom,Pig,Piglin,PiglinBrute,Pillager,PolarBear,Pufferfish,Rabbit,Raider,Ravager,Salmon,Sheep,ShoulderRidingEntity,Shulker,Silverfish,Skeleton,SkeletonHorse,Slime,Sniffer,SnowGolem,SpellcasterIllager,Spider,Squid,Stray,Strider,Tadpole,TamableAnimal,TraderLlama,TropicalFish,Turtle,Vex,Villager,Vindicator,WanderingTrader,Warden,WaterAnimal,Witch,WitherBoss,WitherSkeleton,Wolf,Zoglin,Zombie,ZombieHorse,ZombieVillager,ZombifiedPiglin
public interface Leashable
-
Nested Class Summary
Nested Classes -
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptiondefault booleandefault booleandefault voidcloseRangeLeashBehaviour(Entity p_352073_) default voiddropLeash(boolean p_352294_, boolean p_352456_) dropLeash(E p_352163_, boolean p_352286_, boolean p_352272_) default voidelasticRangeLeashBehaviour(Entity p_353036_, float p_353047_) default EntitygetLeashHolder(E p_352466_) default booleanhandleLeashAtDistance(Entity p_352458_, float p_352101_) default booleandefault voidlegacyElasticRangeLeashBehaviour(E p_353048_, Entity p_353039_, float p_353053_) default booleandefault Leashable.LeashDatareadLeashData(CompoundTag p_352410_) restoreLeashFromSave(E p_352354_, Leashable.LeashData p_352106_) default voidsetDelayedLeashHolderId(int p_352387_) voidsetLeashData(Leashable.LeashData p_352114_) setLeashedTo(E p_352280_, Entity p_352109_, boolean p_352239_) default voidsetLeashedTo(Entity p_352411_, boolean p_352183_) tickLeash(E p_352082_) default voidwriteLeashData(CompoundTag p_352349_, Leashable.LeashData p_352363_)
-
Field Details
-
LEASH_TAG
- See Also:
-
LEASH_TOO_FAR_DIST
static final double LEASH_TOO_FAR_DIST- See Also:
-
LEASH_ELASTIC_DIST
static final double LEASH_ELASTIC_DIST- See Also:
-
-
Method Details
-
getLeashData
-
setLeashData
-
isLeashed
default boolean isLeashed() -
mayBeLeashed
default boolean mayBeLeashed() -
canHaveALeashAttachedToIt
default boolean canHaveALeashAttachedToIt() -
canBeLeashed
default boolean canBeLeashed() -
setDelayedLeashHolderId
default void setDelayedLeashHolderId(int p_352387_) -
readLeashData
-
writeLeashData
-
restoreLeashFromSave
private static <E extends Entity & Leashable> void restoreLeashFromSave(E p_352354_, Leashable.LeashData p_352106_) -
dropLeash
default void dropLeash(boolean p_352294_, boolean p_352456_) -
dropLeash
-
tickLeash
-
handleLeashAtDistance
-
leashTooFarBehaviour
default void leashTooFarBehaviour() -
closeRangeLeashBehaviour
-
elasticRangeLeashBehaviour
-
legacyElasticRangeLeashBehaviour
-
setLeashedTo
-
setLeashedTo
-
getLeashHolder
-
getLeashHolder
-