Class QuestProgressEvent

java.lang.Object
org.bukkit.event.Event
com.ordwen.odailyquests.api.events.QuestProgressEvent
All Implemented Interfaces:
org.bukkit.event.Cancellable

public class QuestProgressEvent extends org.bukkit.event.Event implements org.bukkit.event.Cancellable
Called when a quest progress. This method advances the player's quest by the amount indicated. It first checks that the player is not in a world prohibited by the configuration.
Since:
2.2.4
  • Constructor Details

    • QuestProgressEvent

      public QuestProgressEvent(org.bukkit.entity.Player player, Progression progression, AbstractQuest quest, int amount)
      Constructor for the QuestProgressEvent.
      Parameters:
      player - player who progressed the quest
      progression - current progression of the quest
      quest - quest that was progressed
      amount - amount of progression
  • Method Details

    • isCancelled

      public boolean isCancelled()
      Specified by:
      isCancelled in interface org.bukkit.event.Cancellable
    • setCancelled

      public void setCancelled(boolean isCancelled)
      Specified by:
      setCancelled in interface org.bukkit.event.Cancellable
    • getHandlers

      @NotNull public org.bukkit.event.HandlerList getHandlers()
      Specified by:
      getHandlers in class org.bukkit.event.Event
    • getHandlerList

      public static org.bukkit.event.HandlerList getHandlerList()
    • getPlayer

      public org.bukkit.entity.Player getPlayer()
      Get the player who progressed the quest.
      Returns:
      Player object
    • getProgression

      public Progression getProgression()
      Get the current progression of the quest.
      Returns:
      Progression object
    • getQuest

      public AbstractQuest getQuest()
      Get the quest that was progressed.
      Returns:
      AbstractQuest object
    • getAmount

      public int getAmount()
      Get the amount of progression.
      Returns:
      int