Fixed double dot bug

This commit is contained in:
t3hk0d3 2012-06-28 22:23:25 +04:00
parent 40417f7fde
commit baf265ee9c

View File

@ -43,14 +43,14 @@ public class BlockListener extends ModifyworldListener {
@EventHandler(priority = EventPriority.LOW) @EventHandler(priority = EventPriority.LOW)
public void onBlockBreak(BlockBreakEvent event) { public void onBlockBreak(BlockBreakEvent event) {
if (permissionDenied(event.getPlayer(), "modifyworld.blocks.destroy.", event.getBlock())) { if (permissionDenied(event.getPlayer(), "modifyworld.blocks.destroy", event.getBlock())) {
event.setCancelled(true); event.setCancelled(true);
} }
} }
@EventHandler(priority = EventPriority.LOW) @EventHandler(priority = EventPriority.LOW)
public void onBlockPlace(BlockPlaceEvent event) { public void onBlockPlace(BlockPlaceEvent event) {
if (permissionDenied(event.getPlayer(), "modifyworld.blocks.place.", event.getBlock())) { if (permissionDenied(event.getPlayer(), "modifyworld.blocks.place", event.getBlock())) {
event.setCancelled(true); event.setCancelled(true);
} }
} }
@ -63,14 +63,14 @@ public class BlockListener extends ModifyworldListener {
PaintingBreakByEntityEvent pbee = (PaintingBreakByEntityEvent) event; PaintingBreakByEntityEvent pbee = (PaintingBreakByEntityEvent) event;
if (pbee.getRemover() instanceof Player if (pbee.getRemover() instanceof Player
&& permissionDenied((Player) pbee.getRemover(), "modifyworld.blocks.destroy.", Material.PAINTING)) { && permissionDenied((Player) pbee.getRemover(), "modifyworld.blocks.destroy", Material.PAINTING)) {
event.setCancelled(true); event.setCancelled(true);
} }
} }
@EventHandler(priority = EventPriority.LOW) @EventHandler(priority = EventPriority.LOW)
public void onPaintingPlace(PaintingPlaceEvent event) { public void onPaintingPlace(PaintingPlaceEvent event) {
if (permissionDenied(event.getPlayer(), "modifyworld.blocks.place.", Material.PAINTING)) { if (permissionDenied(event.getPlayer(), "modifyworld.blocks.place", Material.PAINTING)) {
event.setCancelled(true); event.setCancelled(true);
} }
} }