Package net.minecraft.network.chat
Class ScoreComponent
java.lang.Object
net.minecraft.network.chat.BaseComponent
net.minecraft.network.chat.ScoreComponent
- All Implemented Interfaces:
com.mojang.brigadier.Message
,Component
,ContextAwareComponent
,FormattedText
,MutableComponent
-
Nested Class Summary
Nested classes/interfaces inherited from interface net.minecraft.network.chat.Component
Component.Serializer
Nested classes/interfaces inherited from interface net.minecraft.network.chat.FormattedText
FormattedText.ContentConsumer<T>, FormattedText.StyledContentConsumer<T>
-
Field Summary
Modifier and TypeFieldDescriptionprivate String
private String
private static String
private EntitySelector
Fields inherited from class net.minecraft.network.chat.BaseComponent
siblings
Fields inherited from interface net.minecraft.network.chat.FormattedText
EMPTY, STOP_ITERATION
-
Constructor Summary
ModifierConstructorDescriptionScoreComponent(String p_131054_, String p_131055_)
private
ScoreComponent(String p_131050_, EntitySelector p_131051_, String p_131052_)
-
Method Summary
Modifier and TypeMethodDescriptionboolean
private String
findTargetName(CommandSourceStack p_131057_)
getName()
private String
getScore(String p_131063_, CommandSourceStack p_131064_)
private static EntitySelector
parseSelector(String p_131067_)
resolve(CommandSourceStack p_131059_, Entity p_131060_, int p_131061_)
toString()
Methods inherited from class net.minecraft.network.chat.BaseComponent
append, copy, getContents, getSiblings, getStyle, getVisualOrderText, hashCode, setStyle
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Field Details
-
SCORER_PLACEHOLDER
- See Also:
- Constant Field Values
-
name
-
selector
-
objective
-
-
Constructor Details
-
ScoreComponent
-
ScoreComponent
-
-
Method Details
-
parseSelector
-
getName
-
getSelector
-
getObjective
-
findTargetName
private String findTargetName(CommandSourceStack p_131057_) throws com.mojang.brigadier.exceptions.CommandSyntaxException- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
getScore
-
plainCopy
- Specified by:
plainCopy
in interfaceComponent
- Specified by:
plainCopy
in classBaseComponent
-
resolve
public MutableComponent resolve(@Nullable CommandSourceStack p_131059_, @Nullable Entity p_131060_, int p_131061_) throws com.mojang.brigadier.exceptions.CommandSyntaxException- Specified by:
resolve
in interfaceContextAwareComponent
- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
equals
- Overrides:
equals
in classBaseComponent
-
toString
- Overrides:
toString
in classBaseComponent
-