Class GlowTameable

All Implemented Interfaces:
net.kyori.adventure.audience.Audience, net.kyori.adventure.text.event.HoverEventSource<net.kyori.adventure.text.event.HoverEvent.ShowEntity>, org.bukkit.attribute.Attributable, org.bukkit.command.CommandSender, org.bukkit.entity.Ageable, org.bukkit.entity.Animals, org.bukkit.entity.Breedable, org.bukkit.entity.Creature, org.bukkit.entity.Damageable, org.bukkit.entity.Entity, org.bukkit.entity.LivingEntity, org.bukkit.entity.Mob, org.bukkit.entity.Tameable, org.bukkit.loot.Lootable, org.bukkit.metadata.Metadatable, org.bukkit.Nameable, org.bukkit.permissions.Permissible, org.bukkit.permissions.ServerOperator, org.bukkit.persistence.PersistentDataHolder, org.bukkit.projectiles.ProjectileSource
Direct Known Subclasses:
GlowAbstractHorse, GlowOcelot, GlowParrot, GlowWolf

public abstract class GlowTameable extends GlowAnimal implements org.bukkit.entity.Tameable
  • Constructor Details

    • GlowTameable

      public GlowTameable(org.bukkit.Location location, org.bukkit.entity.EntityType type, double maxHealth)
    • GlowTameable

      protected GlowTameable(org.bukkit.Location location, org.bukkit.entity.EntityType type, double maxHealth, org.bukkit.entity.AnimalTamer owner)
  • Method Details

    • isTamed

      public boolean isTamed()
      Specified by:
      isTamed in interface org.bukkit.entity.Tameable
    • setTamed

      public void setTamed(boolean isTamed)
      Specified by:
      setTamed in interface org.bukkit.entity.Tameable
    • getOwner

      public org.bukkit.entity.AnimalTamer getOwner()
      Specified by:
      getOwner in interface org.bukkit.entity.Tameable
    • setOwner

      public void setOwner(org.bukkit.entity.AnimalTamer animalTamer)
      Specified by:
      setOwner in interface org.bukkit.entity.Tameable
    • setOwnerUniqueId

      public void setOwnerUniqueId(UUID ownerUniqueId)
      Added needed method for Storage to convert from UUID to owners.

      The UUID's are validated through offline player checking.

      If a player with the specified UUID has not played on the server before, the owner is not set.

      ownerUniqueId - The player UUID of the owner.
    • isSitting

      public boolean isSitting()
      Checks if this animal is sitting.
      true if sitting
    • setSitting

      public void setSitting(boolean isSitting)
      Sets if this animal is sitting. Will remove any path that the animal was following beforehand.
      isSitting - true if sitting
    • fireEntityTameEvent

      protected boolean fireEntityTameEvent(org.bukkit.entity.AnimalTamer owner)
      Fires an EntityTameEvent, and checks whether it was cancelled.
      owner - the AnimalTamer performing the action.
      false if the event was cancelled, true otherwise.
    • getOwnerUniqueId

      public UUID getOwnerUniqueId()
      Specified by:
      getOwnerUniqueId in interface org.bukkit.entity.Tameable