use of com.magmaguy.elitemobs.api.QuestCompleteEvent in project EliteMobs by MagmaGuy.
the class Quest method completeQuest.
public static Quest completeQuest(UUID questUUID, Player player) {
Quest quest = PlayerData.getQuest(player.getUniqueId(), questUUID);
if (quest == null)
return null;
if (!quest.getQuestID().equals(questUUID))
return null;
if (!quest.getQuestObjectives().isOver())
return null;
QuestCompleteEvent questCompleteEvent = new QuestCompleteEvent(player, quest);
new EventCaller(questCompleteEvent);
return quest;
}
Aggregations