mirror of
https://github.com/songoda/FabledSkyBlock.git
synced 2025-01-25 08:51:33 +01:00
Fixed for multi block placement bypass
This commit is contained in:
parent
a6035254b3
commit
86f24d306a
@ -10,6 +10,7 @@ import org.bukkit.entity.Player;
|
||||
import org.bukkit.event.Cancellable;
|
||||
import org.bukkit.event.block.BlockBreakEvent;
|
||||
import org.bukkit.event.block.BlockIgniteEvent;
|
||||
import org.bukkit.event.block.BlockMultiPlaceEvent;
|
||||
import org.bukkit.event.block.BlockPlaceEvent;
|
||||
import org.bukkit.event.entity.*;
|
||||
import org.bukkit.event.hanging.HangingBreakByEntityEvent;
|
||||
@ -37,6 +38,8 @@ public abstract class ListeningPermission extends BasicPermission {
|
||||
public void onBreak(BlockBreakEvent event) {}
|
||||
|
||||
public void onPlace(BlockPlaceEvent event) {}
|
||||
|
||||
public void onMultiPlace(BlockMultiPlaceEvent event) {}
|
||||
|
||||
public void onVehicleDamage(VehicleDamageEvent event) {}
|
||||
|
||||
|
@ -8,6 +8,7 @@ import com.songoda.skyblock.permission.PermissionHandler;
|
||||
import com.songoda.skyblock.permission.PermissionType;
|
||||
import org.bukkit.entity.Player;
|
||||
import org.bukkit.event.block.Action;
|
||||
import org.bukkit.event.block.BlockMultiPlaceEvent;
|
||||
import org.bukkit.event.block.BlockPlaceEvent;
|
||||
import org.bukkit.event.player.PlayerInteractEvent;
|
||||
|
||||
@ -37,4 +38,9 @@ public class PlacePermission extends ListeningPermission {
|
||||
public void onPlace(BlockPlaceEvent event) {
|
||||
cancelAndMessage(event, event.getPlayer(), plugin, messageManager);
|
||||
}
|
||||
|
||||
@PermissionHandler
|
||||
public void onMultiPlace(BlockMultiPlaceEvent event) {
|
||||
cancelAndMessage(event, event.getPlayer(), plugin, messageManager);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user