mirror of
https://github.com/AuthMe/AuthMeReloaded.git
synced 2024-11-24 03:05:17 +01:00
should fix item usage issue
This commit is contained in:
parent
76b4f62e79
commit
3cbc7ab18f
@ -651,7 +651,7 @@ public class AuthMePlayerListener implements Listener {
|
||||
event.setCancelled(true);
|
||||
}
|
||||
|
||||
@EventHandler(ignoreCancelled = true, priority = EventPriority.LOWEST)
|
||||
@EventHandler(ignoreCancelled = true, priority = EventPriority.NORMAL)
|
||||
public void onPlayerInteract(PlayerInteractEvent event) {
|
||||
if (event.getPlayer() == null)
|
||||
return;
|
||||
@ -675,8 +675,9 @@ public class AuthMePlayerListener implements Listener {
|
||||
return;
|
||||
}
|
||||
}
|
||||
if (event.getClickedBlock() != null && event.getClickedBlock().getType() != Material.AIR)
|
||||
if (event.getClickedBlock() != null){
|
||||
event.setUseInteractedBlock(org.bukkit.event.Event.Result.DENY);
|
||||
}
|
||||
event.setUseItemInHand(org.bukkit.event.Event.Result.DENY);
|
||||
event.setCancelled(true);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user