Package net.minecraft.util.text
Class ScoreTextComponent
- java.lang.Object
-
- net.minecraft.util.text.TextComponent
-
- net.minecraft.util.text.ScoreTextComponent
-
- All Implemented Interfaces:
com.mojang.brigadier.Message
,IFormattableTextComponent
,ITargetedTextComponent
,ITextComponent
,ITextProperties
public class ScoreTextComponent extends TextComponent implements ITargetedTextComponent
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface net.minecraft.util.text.ITextComponent
ITextComponent.Serializer
-
Nested classes/interfaces inherited from interface net.minecraft.util.text.ITextProperties
ITextProperties.IStyledTextAcceptor<T>, ITextProperties.ITextAcceptor<T>
-
-
Field Summary
Fields Modifier and Type Field Description private java.lang.String
name
private java.lang.String
objective
private EntitySelector
selector
-
Fields inherited from class net.minecraft.util.text.TextComponent
siblings
-
Fields inherited from interface net.minecraft.util.text.ITextProperties
EMPTY, STOP_ITERATION
-
-
Constructor Summary
Constructors Modifier Constructor Description ScoreTextComponent(java.lang.String p_i45997_1_, java.lang.String p_i45997_2_)
private
ScoreTextComponent(java.lang.String p_i232569_1_, EntitySelector p_i232569_2_, java.lang.String p_i232569_3_)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object p_equals_1_)
private java.lang.String
findTargetName(CommandSource p_240705_1_)
java.lang.String
getName()
java.lang.String
getObjective()
private java.lang.String
getScore(java.lang.String p_240706_1_, CommandSource p_240706_2_)
private static EntitySelector
parseSelector(java.lang.String p_240707_0_)
ScoreTextComponent
plainCopy()
IFormattableTextComponent
resolve(CommandSource p_230535_1_, Entity p_230535_2_, int p_230535_3_)
java.lang.String
toString()
-
Methods inherited from class net.minecraft.util.text.TextComponent
append, copy, getContents, getSiblings, getStyle, getVisualOrderText, hashCode, setStyle
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
-
-
-
Field Detail
-
name
private final java.lang.String name
-
selector
@Nullable private final EntitySelector selector
-
objective
private final java.lang.String objective
-
-
Constructor Detail
-
ScoreTextComponent
public ScoreTextComponent(java.lang.String p_i45997_1_, java.lang.String p_i45997_2_)
-
ScoreTextComponent
private ScoreTextComponent(java.lang.String p_i232569_1_, @Nullable EntitySelector p_i232569_2_, java.lang.String p_i232569_3_)
-
-
Method Detail
-
parseSelector
@Nullable private static EntitySelector parseSelector(java.lang.String p_240707_0_)
-
getName
public java.lang.String getName()
-
getObjective
public java.lang.String getObjective()
-
findTargetName
private java.lang.String findTargetName(CommandSource p_240705_1_) throws com.mojang.brigadier.exceptions.CommandSyntaxException
- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
getScore
private java.lang.String getScore(java.lang.String p_240706_1_, CommandSource p_240706_2_)
-
plainCopy
public ScoreTextComponent plainCopy()
- Specified by:
plainCopy
in interfaceITextComponent
- Specified by:
plainCopy
in classTextComponent
-
resolve
public IFormattableTextComponent resolve(@Nullable CommandSource p_230535_1_, @Nullable Entity p_230535_2_, int p_230535_3_) throws com.mojang.brigadier.exceptions.CommandSyntaxException
- Specified by:
resolve
in interfaceITargetedTextComponent
- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
equals
public boolean equals(java.lang.Object p_equals_1_)
- Overrides:
equals
in classTextComponent
-
toString
public java.lang.String toString()
- Overrides:
toString
in classTextComponent
-
-