接口 Creature

所有超级接口:
Attributable, CommandSender, Damageable, Entity, LivingEntity, Metadatable, Nameable, Permissible, ProjectileSource, ServerOperator
所有已知子接口:
AbstractHorse, Ageable, Animals, Blaze, CaveSpider, ChestedHorse, Chicken, Cow, Creeper, Donkey, ElderGuardian, Enderman, Endermite, Evoker, Giant, Golem, Guardian, Horse, Husk, Illager, Illusioner, IronGolem, Llama, Monster, Mule, MushroomCow, NPC, Ocelot, Parrot, Pig, PigZombie, PolarBear, Rabbit, Sheep, Shulker, Silverfish, Skeleton, SkeletonHorse, Snowman, Spellcaster, Spider, Stray, Vex, Villager, Vindicator, Witch, Wither, WitherSkeleton, Wolf, Zombie, ZombieHorse, ZombieVillager

public interface Creature extends LivingEntity
Represents a Creature. Creatures are non-intelligent monsters or animals which have very simple abilities.
  • 方法详细资料

    • setTarget

      void setTarget(LivingEntity target)
      Instructs this Creature to set the specified LivingEntity as its target.

      Hostile creatures may attack their target, and friendly creatures may follow their target.

      参数:
      target - New LivingEntity to target, or null to clear the target
    • getTarget

      LivingEntity getTarget()
      Gets the current target of this Creature
      返回:
      Current target of this creature, or null if none exists