Class FurnitureBreakListener

java.lang.Object
com.ranull.graves.listener.integration.itemsadder.FurnitureBreakListener
All Implemented Interfaces:
org.bukkit.event.Listener

public class FurnitureBreakListener extends Object implements org.bukkit.event.Listener
A listener for handling ItemsAdder's FurnitureBreakEvent. This class is responsible for cancelling the furniture break event for graves, depending on the configuration settings in the Graves plugin.
  • Field Details

    • plugin

      private final Graves plugin
  • Constructor Details

    • FurnitureBreakListener

      public FurnitureBreakListener(Graves plugin)
      Constructs a new FurnitureBreakListener.
      Parameters:
      plugin - the instance of the Graves plugin
  • Method Details

    • onFurnitureBreak

      public void onFurnitureBreak(dev.lone.itemsadder.api.Events.FurnitureBreakEvent event)
      Handles the FurnitureBreakEvent for ItemsAdder custom furniture. Cancels the event if the furniture is part of a grave and the configuration for preventing furniture breaking is enabled.
      Parameters:
      event - the ItemsAdder FurnitureBreakEvent triggered when a custom furniture entity is broken