#How to stop mob eggs from working
1 messages · Page 1 of 1 (latest)
Probably something like:
@EventHandler(priority = EventPriority.MONITOR)
public void onMobEggPlace(PlayerInteractEvent event) {
final Player player;
if((player = event.getPlayer()) != null && event.getAction() == Action.RIGHT_CLICK_BLOCK
&& event.hasItem() && event.getItem().getType() == Material.MONSTER_EGG) {
event.setCancelled(true);
player.sendMessage(ChatColor.RED + "You are not allowed to place mob eggs!");
}
}
create a script
I don't think so I do not know
i gave u the code that should achieve the effect you want
I had an idea to make a repository where I write plugins/example code/projects for people I help here, and the first thing I did was this, you can view the code, download the project yourself and or just download the compile jar from here that disables spawn eggs from being placed by people for you. however, if you want specific changes you'll probably have to deal with that yourself : https://github.com/sp0oOk/HelpChat
GitHub
A repository full of all the issues I've helped members of the HelpChat community solve! - sp0oOk/HelpChat
Thank you❤️