Class GlowItemFrame

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.Entity, org.bukkit.entity.Hanging, org.bukkit.entity.ItemFrame, org.bukkit.material.Attachable, org.bukkit.material.Directional, org.bukkit.metadata.Metadatable, org.bukkit.Nameable, org.bukkit.permissions.Permissible, org.bukkit.permissions.ServerOperator, org.bukkit.persistence.PersistentDataHolder

public class GlowItemFrame extends GlowHangingEntity implements org.bukkit.entity.ItemFrame
  • Constructor Details

    • GlowItemFrame

      public GlowItemFrame(GlowPlayer player, org.bukkit.Location location, org.bukkit.block.BlockFace facing)
      Creates an item frame entity, and consumes the item frame item if a player is hanging it.
      Parameters:
      player - the player who is hanging this item frame if it was an item before, or null if it wasn't (e.g. it's from the saved world or a /summon command)
      location - the item frame's location
      facing - the direction this item frame is facing
  • Method Details

    • entityInteract

      public boolean entityInteract(GlowPlayer player, InteractEntityMessage message)
      Overrides:
      entityInteract in class GlowEntity
    • pulse

      public void pulse()
      Description copied from class: GlowEntity
      Called every game cycle. Subclasses should implement this to implement periodic functionality e.g. mob AI.
      Overrides:
      pulse in class GlowEntity
    • pulsePhysics

      protected void pulsePhysics()
      Overrides:
      pulsePhysics in class GlowEntity
    • createSpawnMessage

      public List<com.flowpowered.network.Message> createSpawnMessage()
      Description copied from class: GlowEntity
      Creates a list of Messages which can be sent to a client to spawn this entity. Implementations in concrete subclasses may return a shallowly immutable list.
      Specified by:
      createSpawnMessage in class GlowEntity
      Returns:
      A list of messages which can spawn this entity.
    • isEmpty

      public boolean isEmpty()
      Specified by:
      isEmpty in interface org.bukkit.entity.Entity
      Overrides:
      isEmpty in class GlowEntity
    • getType

      public org.bukkit.entity.EntityType getType()
      Specified by:
      getType in interface org.bukkit.entity.Entity
      Overrides:
      getType in class GlowEntity
    • getItem

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

      public void setItem(org.bukkit.inventory.ItemStack is)
      Specified by:
      setItem in interface org.bukkit.entity.ItemFrame
    • setItem

      public void setItem(@Nullable @Nullable org.bukkit.inventory.ItemStack item, boolean playSound)
      Specified by:
      setItem in interface org.bukkit.entity.ItemFrame
    • setFacingDirection

      public boolean setFacingDirection(org.bukkit.block.BlockFace blockface, boolean force)
      Specified by:
      setFacingDirection in interface org.bukkit.entity.Hanging
    • setFacingDirection

      public void setFacingDirection(org.bukkit.block.BlockFace blockface)
      Specified by:
      setFacingDirection in interface org.bukkit.material.Directional
    • getRotation

      public org.bukkit.Rotation getRotation()
      Specified by:
      getRotation in interface org.bukkit.entity.ItemFrame
    • setRotation

      public void setRotation(org.bukkit.Rotation rotation)
      Specified by:
      setRotation in interface org.bukkit.entity.ItemFrame
    • getItemDropChance

      public float getItemDropChance()
      Specified by:
      getItemDropChance in interface org.bukkit.entity.ItemFrame
    • setItemDropChance

      public void setItemDropChance(float itemDropChance)
      Specified by:
      setItemDropChance in interface org.bukkit.entity.ItemFrame
    • isVisible

      public boolean isVisible()
      Specified by:
      isVisible in interface org.bukkit.entity.ItemFrame
    • setVisible

      public void setVisible(boolean visible)
      Specified by:
      setVisible in interface org.bukkit.entity.ItemFrame
    • isFixed

      public boolean isFixed()
      Specified by:
      isFixed in interface org.bukkit.entity.ItemFrame
    • setFixed

      public void setFixed(boolean fixed)
      Specified by:
      setFixed in interface org.bukkit.entity.ItemFrame