signs: instead of cancelling indirect break, remove the sign to prevent lagg

This commit is contained in:
Thijs Wiefferink 2018-12-27 19:44:30 +01:00
parent b4f33589a1
commit 5b327db316
1 changed files with 2 additions and 2 deletions

View File

@ -112,8 +112,8 @@ public class SignsFeature extends RegionFeature {
if(Materials.isSign(event.getBlock().getType())) {
// Check if the rent sign is really the same as a saved rent
if(SignsFeature.getSignByLocation(event.getBlock().getLocation()) != null) {
// Cancel the sign breaking, will create a floating sign but at least it is not disconnected/gone
event.setCancelled(true);
// Remove the sign so that it does not fall on the floor as an item (next region update will place it back)
event.getBlock().setType(Material.AIR);
}
}
}