Package lol.pyr.znpcsplus.api.npc
Interface NpcRegistry
public interface NpcRegistry
Base class for all NPC registries
-
Method Summary
Modifier and TypeMethodDescriptioncreate(String id, org.bukkit.World world, NpcType type, NpcLocation location) Creates a new NPC entryvoidDeletes an NPC entry by its IDCollection<? extends NpcEntry>getAll()Gets all NPC entriesGets all NPC IDsCollection<? extends NpcEntry>Gets all NPC entries that are player madeGets IDs of all player made NPCsGets an NPC entry by its IDGets an NPC entry by its UUID
-
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
Creates a new NPC entry- Parameters:
id- The ID of the NPC entryworld- TheWorldof the NPC entrytype- TheNpcTypeof the NPC entrylocation- TheNpcLocationof the NPC entry- Returns:
- The entry of the newly created npc
-
getById
Gets an NPC entry by its ID- Parameters:
id- The ID of the NPC entry- Returns:
- The NPC entry
-
getByUuid
Gets an NPC entry by its UUID- Parameters:
uuid- The UUID of the NPC entry- Returns:
- The NPC entry
-
delete
Deletes an NPC entry by its ID- Parameters:
id- The ID of the NPC entry
-