public class Advancement
extends java.lang.Object
| Modifier and Type | Class and Description |
|---|---|
static class |
Advancement.Builder |
| Constructor and Description |
|---|
Advancement(ResourceLocation id,
Advancement parentIn,
DisplayInfo displayIn,
AdvancementRewards rewardsIn,
java.util.Map<java.lang.String,Criterion> criteriaIn,
java.lang.String[][] requirementsIn) |
| Modifier and Type | Method and Description |
|---|---|
void |
addChild(Advancement advancementIn)
Add the given
Advancement as a child of this Advancement. |
Advancement.Builder |
copy()
Creates a new advancement builder with the data from this advancement
|
boolean |
equals(java.lang.Object p_equals_1_) |
java.lang.Iterable<Advancement> |
getChildren()
Get the children of this
Advancement. |
java.util.Map<java.lang.String,Criterion> |
getCriteria()
Get the
Criteria used to decide the completion of this Advancement. |
DisplayInfo |
getDisplay()
Get information that defines this
Advancement's appearance in GUIs. |
ITextComponent |
getDisplayText()
Returns the
ITextComponent that is shown in the chat message sent after this Advancement is
completed. |
ResourceLocation |
getId()
Get this
Advancement's unique identifier. |
Advancement |
getParent()
Get the
Advancement that is this Advancement's parent. |
int |
getRequirementCount()
Get how many requirements this
Advancement has. |
java.lang.String[][] |
getRequirements() |
AdvancementRewards |
getRewards() |
int |
hashCode() |
java.lang.String |
toString() |
public Advancement(ResourceLocation id, Advancement parentIn, DisplayInfo displayIn, AdvancementRewards rewardsIn, java.util.Map<java.lang.String,Criterion> criteriaIn, java.lang.String[][] requirementsIn)
public Advancement.Builder copy()
public Advancement getParent()
Advancement that is this Advancement's parent. This determines the tree structure that
appears in the GUI.Advancement of this Advancement, or null to signify that this Advancement is a root with no parent.public DisplayInfo getDisplay()
Advancement's appearance in GUIs.Advancement's appearance in GUIs. If null, signifies an
invisible Advancement.public AdvancementRewards getRewards()
public java.lang.String toString()
toString in class java.lang.Objectpublic java.lang.Iterable<Advancement> getChildren()
Advancement.Iterable of this Advancement's children.getParent()public java.util.Map<java.lang.String,Criterion> getCriteria()
Criteria used to decide the completion of this Advancement. Each key-value pair
consists of a Criterion and its name.AdvancementgetRequirements()public int getRequirementCount()
Advancement has.this.getRequirements().lengthgetRequirements()public void addChild(Advancement advancementIn)
Advancement as a child of this Advancement.getParent()public ResourceLocation getId()
Advancement's unique identifier.Advancement's unique identifierpublic boolean equals(java.lang.Object p_equals_1_)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectpublic java.lang.String[][] getRequirements()
public ITextComponent getDisplayText()
ITextComponent that is shown in the chat message sent after this Advancement is
completed.ITextComponent that is shown in the chat message sent after this Advancement is
completed. If this Advancement is invisible, then it consists simply of getId(). Otherwise, it is the title inside square brackets, colored by the
frame type, and hovering over it shows the
description.