java.lang.Object
eu.endercentral.crazy_advancements.advancement.criteria.Criteria

public class Criteria extends Object
Represents the Criteria that is required for an Advancement
Author:
Axel
  • Constructor Details

    • Criteria

      public Criteria(int requiredNumber)
      Constructor for creating CriteriaType NUMBER which will require a certain number
      Parameters:
      requiredNumber - The required number
    • Criteria

      public Criteria(String[] actionNames, String[][] requirements)
      Constructor for creating CriteriaType LIST which will require a list of actions that need to be completed
      For further details see Advancement/JSON Format on the Minecraft Wiki
      Parameters:
      actionNames - The names of all occuring actions
      requirements - The definition of which and how actions are required (AND grouping of OR groups)
  • Method Details

    • getType

      public CriteriaType getType()
      Gets the Criteria type
      Returns:
      The Criteria type
    • getRequiredNumber

      public int getRequiredNumber()
      Gets the required Number (only applies for CriteriaType NUMBER)
      Returns:
      The Required Number
    • getActionNames

      public String[] getActionNames()
      Gets the Action Names (auto-generated when using CriteriaType NUMBER)
      Returns:
      The Actions
    • getRequirements

      public String[][] getRequirements()
      Gets the Requirements (auto-generated when using CriteriaType NUMBER)
      Returns:
      The Requirements
    • getAdvancementRequirements

      public net.minecraft.advancements.AdvancementRequirements getAdvancementRequirements()
      Gets the Requirements (auto-generated when using CriteriaType NUMBER)
      Returns:
      The Requirements
    • getCriteria

      public HashMap<String,net.minecraft.advancements.Criterion<?>> getCriteria()
      Gets the generated Criteria
      Returns:
      The generated Criteria