[API] TruenoNPC | Creates easy NPCs [1.8-1.12] 1.3

Simple API to create NPCs with skin and without nametag

  1. el_trueno
    Tested Minecraft Versions:
    • 1.8
    • 1.9
    • 1.10
    • 1.11
    • 1.12
    Source Code:
    https://github.com/eltrueno/TruenoNPC
    Contributors:
    aadnk, Yonas, dmulloy2, MartinGamer_Es
    TruenoNPC
    API for create NPCs without nametags in Spigot/Bukkit. It's compatible with 1.8 to 1.12 versions

    Please if you are going to use this api, give me credits. Just a simple mention is welcome c:

    Donate me
    If you like my work, please, consider donating

    [​IMG]

    Features:
    • 1.8-1.12 support.
    • NPCs with skin (and with second layer).
    • Automatic render/unrender system. Create the npc and will be visible for all the players incluided incoming players.
    • NPCs without nametag, so you can create an hologram obove without character restriction.
    • Incluided packetlistening and events:
      • Spawn Event
      • Despawn Event
      • Interact Event
    Usage:
    1. Clone the repo and integrate it in your proyect.
    2. Remove nms classes that you don't be using from .nms package and TruenoNPCApi (If your plugin is not compatible 1.8 - 1.12).
    3. Create your npcs!
    Plugins using it:
    Servers using it:
    • (Official) mc.linvio.net
    • mc.comugamers.com
    • gravenmc.fr

    Examples:
    • Create NPC:
      Code (Text):

      //First create the skin
      TruenoNPCSkin skin = TruenoNPCSkinBuilder.fromUsername(this.plugin, p.getName());
      TruenoNPCSkin skin = TruenoNPCSkinBuilder.fromUUID(this.plugin, p.getUniqueId().toString());
      TruenoNPCSkin skin = TruenoNPCSkinBuilder.fromMineskin(this.plugin, 131234);

      //Now create the NPC ussing the skin
      TruenoNPC npc = TruenoNPCApi.createNPC(main.getPlugin(), p.getLocation(), skin);
       
    • NPC methods:
      Code (Text):
      TruenoNPC npc = TruenoNPCApi.createNPC(main.getPlugin(), p.getLocation(), "el_trueno");
      npc.delete(); // Delete the npc
      npc.getLocation(); // Returns npc location
      npc.getEntityID(Player); // Return entity id (int)
      npc.isDeleted(); // Returns if the npc has been deleted;
    • NPC Events Listening:
      Code (Text):
          @EventHandler
          public void OnInteract(TruenoNPCInteractEvent ev){
              TruenoNPC npc = ev.getNPC();
              Player player = ev.getPlayer();
          }

          @EventHandler
          public void onSpawn(TruenoNPCSpawnEvent ev){
              TruenoNPC npc = ev.getNPC();
              Player player = ev.getPlayer();
          }

          @EventHandler
          public void onDespawn(TruenoNPCDespawnEvent ev){
              TruenoNPC npc = ev.getNPC();
              Player player = ev.getPlayer();
          }

    Screenshots:
    [​IMG]

    Thanks to:

    Donate me
    If you like my work, please, consider donating

    [​IMG]

    Contact me

    [​IMG]

    Bitbucket fallback repository: https://bitbucket.org/el_trueno/truenonpc
    Dr4cc, HazeDev, YouTube0099 and 5 others like this.

Recent Updates

  1. Added ProtocolLib Support
  2. Update 1.2
  3. Update 1.1.1

Recent Reviews

  1. Raul_gamer
    Raul_gamer
    5/5,
    Version: 1.3
    Muy buena api, pero al cerrar y abrir el servidor los npc desaparecen, no se si estoy haciendo algo mal, en esa caso digame si tengo que añadir en el metodo de onEnable algo.
    1. el_trueno
      Author's Response
      Si quieres que se guarden tienes que hacerte tu el sistema para ello, que lo guarde en un .json o lo que sea
  2. Ariouz
    Ariouz
    5/5,
    Version: 1.3
    Ok, thanks for your answer, and can you make an update to know if it's right or left click in interactEvent ?
    1. el_trueno
      Author's Response
      Maybye in a future rework but not now
  3. EvilWolwerINC
    EvilWolwerINC
    5/5,
    Version: 1.3
    Oh my god! This API is excellent! Thanks a lot for this amazing plugin <3
    ........
    1. el_trueno
  4. gabbo200
    gabbo200
    5/5,
    Version: 1.3
    Great API!!! Are you going to release a 1.14 update any time soon?
    Keep the great work!
    1. el_trueno
      Author's Response
      not 1.13+ at the moment
  5. elrobtossohn
    elrobtossohn
    3/5,
    Version: 1.3
    I like your NPCAPI but if a Player die the NPC will be invisible for the player and must rejoin to see it again.

    How to fix it?
    1. el_trueno
      Author's Response
      i didnt consider that, thanks for tell me the bug! i will fix it soon
  6. iSnakeBuzz
    iSnakeBuzz
    5/5,
    Version: 1.3
    Everything nice!, good work.

    Todo bien, buen trabajo
    1. el_trueno
      Author's Response
      Es parte de tu trabajo también, así que gracias a ti también <3
  7. Tellkung
    Tellkung
    5/5,
    Version: 1.2
    I Don't Know How To Use
    Pls tell me how to use <3 <3 <3
    Pls Pls Pls -_- -_- -_-
    1. el_trueno
      Author's Response
  8. funmc
    funmc
    5/5,
    Version: 1.2
    Excellent API!
    Very good support
    It just misses an integrated hologram system <3
    1. el_trueno
      Author's Response
  9. CleusGamer201
    CleusGamer201
    5/5,
    Version: 1.2
    Muy buena api, pero compa al respawnear a un jugador con player.spigot().respawn(); desaparece el npc, no se si es al hacerle tp o que se yo pero desaparece y aveces no desaparece. no da ningún error.

    ¿Alguna forma de actualizar el npc a ese jugador para que le vuelva a aparecer?

    Agradecería tu ayuda ya que estoy con un plugin y eso me está limitando bastante con el progreso.
    1. el_trueno
      Author's Response
      En teoria no deberia pasar. Tengo que hacerle algunas revisiones
  10. HazeDev
    HazeDev
    5/5,
    Version: 1.2
    This is exactly what I've been looking for!
    However could you update it for version v1_13_R2 please
    1. el_trueno
      Author's Response
      thanks <3. when I can I will update it