Package net.minecraft.text.object
Record Class PlayerTextObjectContents
java.lang.Object
java.lang.Record
net.minecraft.text.object.PlayerTextObjectContents
- Record Components:
player-hat-
- All Implemented Interfaces:
TextObjectContents
public record PlayerTextObjectContents(ProfileComponent player, boolean hat)
extends Record
implements TextObjectContents
- Mappings:
Namespace Name named net/minecraft/text/object/PlayerTextObjectContentsintermediary net/minecraft/class_11885official zrnamed playerintermediary comp_4763official bnamed hatintermediary comp_4764official c
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final com.mojang.serialization.MapCodec<PlayerTextObjectContents> private final booleanThe field for thehatrecord component.private final ProfileComponentThe field for theplayerrecord component. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionasText()final booleanIndicates whether some other object is "equal to" this one.com.mojang.serialization.MapCodec<PlayerTextObjectContents> getCodec()final inthashCode()Returns a hash code value for this object.booleanhat()Returns the value of thehatrecord component.player()Returns the value of theplayerrecord component.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
player
The field for theplayerrecord component. -
hat
private final boolean hatThe field for thehatrecord component. -
CODEC
- Mappings:
Namespace Name Mixin selector named CODECLnet/minecraft/text/object/PlayerTextObjectContents;CODEC:Lcom/mojang/serialization/MapCodec;intermediary field_62500Lnet/minecraft/class_11885;field_62500:Lcom/mojang/serialization/MapCodec;official aLzr;a:Lcom/mojang/serialization/MapCodec;
-
-
Constructor Details
-
PlayerTextObjectContents
-
-
Method Details
-
spriteSource
- Specified by:
spriteSourcein interfaceTextObjectContents- Mappings:
Namespace Name Mixin selector named spriteSourceLnet/minecraft/text/object/TextObjectContents;spriteSource()Lnet/minecraft/text/StyleSpriteSource;intermediary method_74068Lnet/minecraft/class_11724;method_74068()Lnet/minecraft/class_11719;official bLzp;b()Lyc;
-
asText
- Specified by:
asTextin interfaceTextObjectContents- Mappings:
Namespace Name Mixin selector named asTextLnet/minecraft/text/object/TextObjectContents;asText()Ljava/lang/String;intermediary method_73178Lnet/minecraft/class_11724;method_73178()Ljava/lang/String;official cLzp;c()Ljava/lang/String;
-
getCodec
- Specified by:
getCodecin interfaceTextObjectContents- Mappings:
Namespace Name Mixin selector named getCodecLnet/minecraft/text/object/TextObjectContents;getCodec()Lcom/mojang/serialization/MapCodec;intermediary method_74067Lnet/minecraft/class_11724;method_74067()Lcom/mojang/serialization/MapCodec;official aLzp;a()Lcom/mojang/serialization/MapCodec;
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
player
Returns the value of theplayerrecord component.- Returns:
- the value of the
playerrecord component
-
hat
public boolean hat()Returns the value of thehatrecord component.- Returns:
- the value of the
hatrecord component
-