Package com.sk89q.worldguard.chest
Interface ChestProtection
- All Known Implementing Classes:
SignChestProtection
public interface ChestProtection
Interface for chest protection.
-
Method Summary
Modifier and TypeMethodDescriptionboolean
isAdjacentChestProtected
(com.sk89q.worldedit.util.Location searchBlock, LocalPlayer player) Returns whether an adjacent chest is protected.default boolean
isChest
(com.sk89q.worldedit.world.block.BlockType blockType) Returns whether a blockType is a chest.boolean
isProtected
(com.sk89q.worldedit.util.Location block, LocalPlayer player) Returns whether a block is protected.boolean
isProtectedPlacement
(com.sk89q.worldedit.util.Location block, LocalPlayer player) Returns whether a location where a chest block is trying to be created is protected.
-
Method Details
-
isProtected
Returns whether a block is protected.- Parameters:
block
- The block to checkplayer
- The player to check- Returns:
- Whether the block is protected for player
-
isProtectedPlacement
Returns whether a location where a chest block is trying to be created is protected.- Parameters:
block
- The block to checkplayer
- The player to check- Returns:
- Whether
player
can place a block at the specified block
-
isAdjacentChestProtected
Returns whether an adjacent chest is protected.- Parameters:
searchBlock
- The block to checkplayer
- The player to check- Returns:
- Whether
searchBlock
is protected from access byplayer
-
isChest
default boolean isChest(com.sk89q.worldedit.world.block.BlockType blockType) Returns whether a blockType is a chest.- Parameters:
blockType
- The blockType to check- Returns:
- Whether a type is a 'chest' (protectable block)
-