Package com.ranull.graves.integration
Class ProtectionLib
java.lang.Object
com.ranull.graves.integration.ProtectionLib
Provides integration with ProtectionLib to check if a player can build at a specific location.
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionProtectionLib
(Graves plugin, org.bukkit.plugin.Plugin protectionLibPlugin) Constructs a new ProtectionLib instance with the specified Graves plugin and ProtectionLib plugin. -
Method Summary
Modifier and TypeMethodDescriptionboolean
canBuild
(org.bukkit.Location location, org.bukkit.entity.Player player) Checks if a player is allowed to build at the specified location.
-
Field Details
-
plugin
-
protectionLibPlugin
private final org.bukkit.plugin.Plugin protectionLibPlugin
-
-
Constructor Details
-
ProtectionLib
Constructs a new ProtectionLib instance with the specified Graves plugin and ProtectionLib plugin.- Parameters:
plugin
- The main Graves plugin instance.protectionLibPlugin
- The ProtectionLib plugin instance.
-
-
Method Details
-
canBuild
public boolean canBuild(org.bukkit.Location location, org.bukkit.entity.Player player) Checks if a player is allowed to build at the specified location. Uses FurnitureLib integration if available; otherwise, reflects ProtectionLib's method.- Parameters:
location
- The location to check.player
- The player attempting to build.- Returns:
- True if the player can build at the location, false otherwise.
-