Removed some limitations on hoppers and mine carts.

No longer needed - building at the bottom of a claim now extends the
claim downward, so no important blocks (like chests) will be thievable
by hoppers or hopper mine carts except in extremely rare,
not-manufacturable situations.
This commit is contained in:
ryanhamshire 2014-12-13 11:39:53 -08:00
parent cabcebe807
commit 3f33679424

View File

@ -176,39 +176,6 @@ public class BlockEventHandler implements Listener
{
playerData.lastClaim = claim;
//FEATURE: prevent theft from container using a hopper when the container is at the very bottom of a land claim
if(block.getType() == Material.HOPPER)
{
//is the above block inside the land claim?
Block aboveBlock = block.getRelative(BlockFace.UP);
if(claim.contains(aboveBlock.getLocation(), false, false))
{
//then the player needs container trust to place the hopper
String failureMessage = claim.allowContainers(player);
if(failureMessage != null)
{
placeEvent.setCancelled(true);
GriefPrevention.sendMessage(player, TextMode.Err, failureMessage);
return;
}
}
}
//rails can't be placed ANYWHERE under a claim, because they could be pushed up to the
//target container using pistons
if(block.getType().name().contains("RAIL"))
{
//then the player needs container trust to place the hopper
String failureMessage = claim.allowContainers(player);
if(failureMessage != null)
{
placeEvent.setCancelled(true);
GriefPrevention.sendMessage(player, TextMode.Err, failureMessage);
return;
}
}
//warn about TNT not destroying claimed blocks
if(block.getType() == Material.TNT && !claim.areExplosivesAllowed)
{