Class AdvancementFunctionReward

java.lang.Object
eu.endercentral.crazy_advancements.advancement.AdvancementReward
eu.endercentral.crazy_advancements.advancement.AdvancementFunctionReward

public class AdvancementFunctionReward extends AdvancementReward
Represents a Reward in form of a .mcfunction function
Author:
Axel
  • Constructor Details

    • AdvancementFunctionReward

      public AdvancementFunctionReward(String function, int delay)
      Constructor for creating a Reward that is given through a function
      Parameters:
      function - The function name
      delay - The delay in ticks before the function is executed
  • Method Details

    • getName

      public String getName()
      Gets the Name of the function
      Returns:
      The Name of the function
    • getDelay

      public int getDelay()
      Gets the delay in ticks before the function is executed
      Returns:
      The delay in ticks
    • onGrant

      public final void onGrant(Player player)
      Description copied from class: AdvancementReward
      Gives the Reward
      Specified by:
      onGrant in class AdvancementReward
      Parameters:
      player - The Receiver