Class GlowEgg

All Implemented Interfaces:
net.kyori.adventure.audience.Audience, net.kyori.adventure.text.event.HoverEventSource<net.kyori.adventure.text.event.HoverEvent.ShowEntity>, org.bukkit.command.CommandSender, org.bukkit.entity.Egg, org.bukkit.entity.Entity, org.bukkit.entity.Projectile, org.bukkit.entity.ThrowableProjectile, org.bukkit.metadata.Metadatable, org.bukkit.Nameable, org.bukkit.permissions.Permissible, org.bukkit.permissions.ServerOperator, org.bukkit.persistence.PersistentDataHolder

public class GlowEgg extends GlowProjectile implements org.bukkit.entity.Egg
  • Constructor Details

    • GlowEgg

      public GlowEgg(org.bukkit.Location location)
      Creates a thrown egg with default speed.
      Parameters:
      location - the position and facing of the thrower
  • Method Details

    • collide

      public void collide(org.bukkit.block.Block block)
      Process random spawn chicks when collide with a block.
      Specified by:
      collide in class GlowProjectile
      Parameters:
      block - the block that the egg collides with
    • collide

      public void collide(org.bukkit.entity.LivingEntity entity)
      Process random spawn chicks when collide with a living entity.
      Specified by:
      collide in class GlowProjectile
      Parameters:
      entity - the eneity that the egg collides with
    • getObjectId

      protected int getObjectId()
      Specified by:
      getObjectId in class GlowProjectile
    • getItem

      @NotNull public @NotNull org.bukkit.inventory.ItemStack getItem()
      Specified by:
      getItem in interface org.bukkit.entity.ThrowableProjectile
    • setItem

      public void setItem(@NotNull @NotNull org.bukkit.inventory.ItemStack itemStack)
      Specified by:
      setItem in interface org.bukkit.entity.ThrowableProjectile