Package com.palmergames.bukkit.util
Class BlockUtil
java.lang.Object
com.palmergames.bukkit.util.BlockUtil
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic boolean
sameOwner
(org.bukkit.block.Block b1, org.bukkit.block.Block b2) Are the blocks owned by the same resident or same town (if not player-owned.)static boolean
sameOwnerOrHasMayorOverride
(org.bukkit.block.Block b1, org.bukkit.block.Block b2, org.bukkit.entity.Player player) Are the blocks owned by the same resident, same town, or does the given Player have the towny.command.plot.asmayor permission node used to discern mayor-like priviledges.static boolean
sameWorldCoord
(WorldCoord wc, WorldCoord wc2) static boolean
sameWorldCoord
(org.bukkit.block.Block b1, org.bukkit.block.Block b2)
-
Field Details
-
CARDINAL_BLOCKFACES
-
-
Constructor Details
-
BlockUtil
public BlockUtil()
-
-
Method Details
-
sameOwner
public static boolean sameOwner(org.bukkit.block.Block b1, org.bukkit.block.Block b2) Are the blocks owned by the same resident or same town (if not player-owned.)- Parameters:
b1
- Block 1b2
- Block 2- Returns:
- True if the blocks have the same owner.
-
sameOwnerOrHasMayorOverride
public static boolean sameOwnerOrHasMayorOverride(org.bukkit.block.Block b1, org.bukkit.block.Block b2, org.bukkit.entity.Player player) Are the blocks owned by the same resident, same town, or does the given Player have the towny.command.plot.asmayor permission node used to discern mayor-like priviledges.- Parameters:
b1
- Block 1b2
- Block 2player
- Player who is acting.- Returns:
- True if the blocks have the same owner, or a mayor-like player has override.
-
sameWorldCoord
public static boolean sameWorldCoord(org.bukkit.block.Block b1, org.bukkit.block.Block b2) -
sameWorldCoord
-