📜  让 wen 玩家右键单击实体 spigot - 任何代码示例

📅  最后修改于: 2022-03-11 14:58:55.709000             🧑  作者: Mango

代码示例1
@EventHandler(priority=EventPriority.NORMAL, ignoreCancelled=true)
      public void onRightClick(PlayerInteractEntityEvent event) {
        Player player = event.getPlayer();
            if (event.getRightClicked().getType()==EntityType.VILLAGER) {
            event.setCancelled(true);
            //continued code