WorldGuard

WorldGuard

8M Downloads

Add option to block Villager(testificates) trading.

LadyCailinBot opened this issue ยท 1 comments

commented

WORLDGUARD-2594 - Reported by mozartripper

Ability to disable it per world or globally. This would be an awesome feature and its pretty easy to do only in a few lines.

@EventHandler(priority = EventPriority.HIGH)
public void onVillagerClick(PlayerInteractEntityEvent e) {
    if(e.getRightClicked() instanceof Villager) {
        Player player = e.getPlayer();
        player.sendMessage(ChatColor.RED + "Villager trading is disabled!");
        e.setCancelled(true);
        }
    }
commented

Comment by sk89q

Closing this issue due to age. If someone is still interested in this issue, please make a new one or ask this one to be re-opened.