Package com.ordwen.odailyquests.api
Class ODailyQuestsAPI
java.lang.Object
com.ordwen.odailyquests.api.ODailyQuestsAPI
This class provides access to the ODailyQuests API, allowing interaction with quest types, player quests,
and command registries for both players and admins.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic void
Disables further registration of new quest types.Retrieves the AdminCommandRegistry used to manage admin commands.static Map
<String, Class<? extends AbstractQuest>> Retrieves a map of external quest types that have been registered.Retrieves the PlayerCommandRegistry used to manage player commands.static PlayerQuests
getPlayerQuests
(String playerName) Retrieves the active quests for a specific player.Retrieves the QuestTypeRegistry used to manage quest types.static void
registerQuestType
(String type, Class<? extends AbstractQuest> questClass) Registers a new quest type.
-
Constructor Details
-
ODailyQuestsAPI
public ODailyQuestsAPI()
-
-
Method Details
-
getPlayerQuests
Retrieves the active quests for a specific player.- Parameters:
playerName
- the name of the player- Returns:
- the PlayerQuests object representing the player's active quests
-
getQuestTypeRegistry
Retrieves the QuestTypeRegistry used to manage quest types.- Returns:
- the QuestTypeRegistry object
-
getPlayerCommandRegistry
Retrieves the PlayerCommandRegistry used to manage player commands.- Returns:
- the PlayerCommandRegistry object
-
getAdminCommandRegistry
Retrieves the AdminCommandRegistry used to manage admin commands.- Returns:
- the AdminCommandRegistry object
-
registerQuestType
Registers a new quest type. The registration is only allowed if the plugin is in a state that permits it.- Parameters:
type
- the type of the quest to be registeredquestClass
- the class of the quest type
-
disableRegistration
public static void disableRegistration()Disables further registration of new quest types. -
getExternalTypes
Retrieves a map of external quest types that have been registered.- Returns:
- a map of external quest types, where the key is the type name and the value is the quest class
-