Class BlockFailedDispenseEvent

java.lang.Object
org.bukkit.event.Event
org.bukkit.event.block.BlockEvent
io.papermc.paper.event.block.BlockFailedDispenseEvent

public class BlockFailedDispenseEvent extends BlockEvent
Called when a block tries to dispense an item, but its inventory is empty.
  • Constructor Details

  • Method Details

    • shouldPlayEffect

      public boolean shouldPlayEffect()
      Returns:
      if the effect should be played
    • shouldPlayEffect

      public void shouldPlayEffect(boolean playEffect)
      Sets if the effect for empty dispensers should be played
      Parameters:
      playEffect - if the effect should be played
    • callEvent

      public boolean callEvent()
      Calls the event and tests if cancelled.
      Overrides:
      callEvent in class Event
      Returns:
      shouldPlayEffect()
    • getHandlers

      @NotNull public @NotNull HandlerList getHandlers()
      Specified by:
      getHandlers in class Event
    • getHandlerList

      @NotNull public static @NotNull HandlerList getHandlerList()