public static class Text.Score extends Text
Text
displaying the current score of a player.TextBuilder.Score
Text.Literal, Text.Placeholder, Text.Score, Text.Selector, Text.Translatable
Modifier and Type | Field and Description |
---|---|
protected Optional<String> |
override |
protected Score |
score |
children, childrenIterable, clickAction, format, hoverAction, shiftClickAction
Modifier and Type | Method and Description |
---|---|
TextBuilder.Score |
builder()
Returns a new
TextBuilder with the content, formatting and
actions of this text. |
boolean |
equals(Object o) |
Optional<String> |
getOverride()
Returns a value that is displayed instead of the real score.
|
Score |
getScore()
Returns the score displayed by this
Text . |
int |
hashCode() |
String |
toString() |
getChildren, getClickAction, getColor, getFormat, getHoverAction, getShiftClickAction, getStyle, toText, withChildren
public final Score getScore()
Text
.public final Optional<String> getOverride()
Optional.empty()
if the real score will be displayed
insteadpublic TextBuilder.Score builder()
Text
TextBuilder
with the content, formatting and
actions of this text. This can be used to edit an otherwise immutable
Text
instance.