Examples of NPCCreateEvent


Examples of net.citizensnpcs.api.event.NPCCreateEvent

        if (colour != null && colour != ChatColor.WHITE) {
            npcName = colour + name;
        }
        HumanNPC npc = NPCSpawner.spawnNPC(UID, npcName, loc);

        NPCCreateEvent event = new NPCCreateEvent(npc, reason, loc);
        Bukkit.getServer().getPluginManager().callEvent(event);

        npc.setNPCData(new NPCData(npcName, UID, loc, colour, PropertyManager.getBasic().getItems(UID),
                NPCDataManager.NPCTexts.get(UID), PropertyManager.getBasic().isTalk(UID), PropertyManager.getBasic()
                        .isLookWhenClose(UID), PropertyManager.getBasic().isTalkWhenClose(UID), owner));
View Full Code Here

Examples of net.citizensnpcs.api.event.NPCCreateEvent

          HumanNPC npc = NPCSpawner.spawnNPC(
              new Location(loc.getWorld(), x, y, z, random
                  .nextInt(360), 0), type);
          Bukkit.getPluginManager()
              .callEvent(
                  new NPCCreateEvent(npc,
                      NPCCreateReason.SPAWN, loc));
          return npc;
        }
      }
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.