Interface NpcRegistry


public interface NpcRegistry
Base class for all NPC registries
  • Method Details

    • getAll

      Collection<? extends NpcEntry> getAll()
      Gets all NPC entries
      Returns:
      All NPC entries
    • getAllIds

      Collection<String> getAllIds()
      Gets all NPC IDs
      Returns:
      All NPC IDs
    • getAllPlayerMade

      Collection<? extends NpcEntry> getAllPlayerMade()
      Gets all NPC entries that are player made
      Returns:
      All player made NPC entries
    • getAllPlayerMadeIds

      Collection<String> getAllPlayerMadeIds()
      Gets IDs of all player made NPCs
      Returns:
      IDs of all player made NPCs
    • create

      NpcEntry create(String id, org.bukkit.World world, NpcType type, NpcLocation location)
      Creates a new NPC entry
      Parameters:
      id - The ID of the NPC entry
      world - The World of the NPC entry
      type - The NpcType of the NPC entry
      location - The NpcLocation of the NPC entry
      Returns:
      The entry of the newly created npc
    • getById

      NpcEntry getById(String id)
      Gets an NPC entry by its ID
      Parameters:
      id - The ID of the NPC entry
      Returns:
      The NPC entry
    • getByUuid

      NpcEntry getByUuid(UUID uuid)
      Gets an NPC entry by its UUID
      Parameters:
      uuid - The UUID of the NPC entry
      Returns:
      The NPC entry
    • delete

      void delete(String id)
      Deletes an NPC entry by its ID
      Parameters:
      id - The ID of the NPC entry