Class FurnitureLib

java.lang.Object
com.ranull.graves.manager.EntityDataManager
com.ranull.graves.integration.FurnitureLib

public final class FurnitureLib extends EntityDataManager
Manages integration with the FurnitureLib plugin for creating, removing, and interacting with furniture.
  • Constructor Details

    • FurnitureLib

      public FurnitureLib(Graves plugin)
      Constructs a FurnitureLib instance.
      Parameters:
      plugin - The main plugin instance.
  • Method Details

    • registerListeners

      public void registerListeners()
      Registers FurnitureLib event listeners.
    • unregisterListeners

      public void unregisterListeners()
      Unregisters FurnitureLib event listeners.
    • canBuild

      public boolean canBuild(org.bukkit.Location location, org.bukkit.entity.Player player)
      Checks if a player can build at a specific location using FurnitureLib's protection.
      Parameters:
      location - The location to check.
      player - The player to check permissions for.
      Returns:
      True if the player can build, false otherwise.
    • createFurniture

      public void createFurniture(org.bukkit.Location location, Grave grave)
      Creates and places furniture at the specified location.
      Parameters:
      location - The location where the furniture should be placed.
      grave - The grave associated with the furniture.
    • removeFurniture

      public void removeFurniture(Grave grave)
      Removes furniture associated with the specified grave.
      Parameters:
      grave - The grave for which to remove furniture.
    • removeFurniture

      public void removeFurniture(EntityData entityData)
      Removes specific furniture entity data.
      Parameters:
      entityData - The entity data of the furniture to remove.
    • removeFurniture

      public void removeFurniture(List<EntityData> entityDataList)
      Removes multiple pieces of furniture based on a list of entity data.
      Parameters:
      entityDataList - A list of entity data for the furniture to remove.
    • hasFurniture

      public boolean hasFurniture(Grave grave)
      True if FurnitureLib furniture occupies the grave's location.
      Parameters:
      grave - The grave to check.
      Returns:
      True if any FurnitureLib ObjectID covers the grave's block position.