Package net.minecraft.component.type
Record Class FireworkExplosionComponent
java.lang.Object
java.lang.Record
net.minecraft.component.type.FireworkExplosionComponent
- Record Components:
shape-colors-fadeColors-hasTrail-hasTwinkle-
- All Implemented Interfaces:
TooltipAppender
public record FireworkExplosionComponent(FireworkExplosionComponent.Type shape, IntList colors, IntList fadeColors, boolean hasTrail, boolean hasTwinkle)
extends Record
implements TooltipAppender
- Mappings:
Namespace Name official ctxintermediary net/minecraft/class_9283named net/minecraft/component/type/FireworkExplosionComponentofficial dintermediary comp_2386named shapeofficial eintermediary comp_2387named colorsofficial fintermediary comp_2388named fadeColorsofficial gintermediary comp_2389named hasTrailofficial hintermediary comp_2390named hasTwinkle
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final com.mojang.serialization.Codec<FireworkExplosionComponent> private final IntListThe field for thecolorsrecord component.private static final com.mojang.serialization.Codec<IntList> private static final PacketCodec<ByteBuf, IntList> private static final Textstatic final FireworkExplosionComponentprivate final IntListThe field for thefadeColorsrecord component.private final booleanThe field for thehasTrailrecord component.private final booleanThe field for thehasTwinklerecord component.static final PacketCodec<ByteBuf, FireworkExplosionComponent> private final FireworkExplosionComponent.TypeThe field for theshaperecord component. -
Constructor Summary
ConstructorsConstructorDescriptionFireworkExplosionComponent(FireworkExplosionComponent.Type type, IntList intList, IntList intList2, boolean bool, boolean bool2) -
Method Summary
Modifier and TypeMethodDescriptionprivate static TextappendColorsTooltipText(MutableText text, IntList colors) voidappendOptionalTooltip(Consumer<Text> textConsumer) voidappendShapeTooltip(Consumer<Text> textConsumer) voidappendTooltip(Consumer<Text> textConsumer, TooltipContext context) colors()Returns the value of thecolorsrecord component.final booleanIndicates whether some other object is "equal to" this one.Returns the value of thefadeColorsrecord component.private static TextgetColorText(int color) final inthashCode()Returns a hash code value for this object.booleanhasTrail()Returns the value of thehasTrailrecord component.booleanReturns the value of thehasTwinklerecord component.shape()Returns the value of theshaperecord component.final StringtoString()Returns a string representation of this record class.withFadeColors(IntList fadeColors)
-
Field Details
-
shape
The field for theshaperecord component. -
colors
The field for thecolorsrecord component. -
fadeColors
The field for thefadeColorsrecord component. -
hasTrail
private final boolean hasTrailThe field for thehasTrailrecord component. -
hasTwinkle
private final boolean hasTwinkleThe field for thehasTwinklerecord component. -
DEFAULT
- Mappings:
Namespace Name Mixin selector official aLctx;a:Lctx;intermediary field_49315Lnet/minecraft/class_9283;field_49315:Lnet/minecraft/class_9283;named DEFAULTLnet/minecraft/component/type/FireworkExplosionComponent;DEFAULT:Lnet/minecraft/component/type/FireworkExplosionComponent;
-
COLORS_CODEC
- Mappings:
Namespace Name Mixin selector official iLctx;i:Lcom/mojang/serialization/Codec;intermediary field_49318Lnet/minecraft/class_9283;field_49318:Lcom/mojang/serialization/Codec;named COLORS_CODECLnet/minecraft/component/type/FireworkExplosionComponent;COLORS_CODEC:Lcom/mojang/serialization/Codec;
-
CODEC
- Mappings:
Namespace Name Mixin selector official bLctx;b:Lcom/mojang/serialization/Codec;intermediary field_49316Lnet/minecraft/class_9283;field_49316:Lcom/mojang/serialization/Codec;named CODECLnet/minecraft/component/type/FireworkExplosionComponent;CODEC:Lcom/mojang/serialization/Codec;
-
COLORS_PACKET_CODEC
- Mappings:
Namespace Name Mixin selector official jLctx;j:Lye;intermediary field_49319Lnet/minecraft/class_9283;field_49319:Lnet/minecraft/class_9139;named COLORS_PACKET_CODECLnet/minecraft/component/type/FireworkExplosionComponent;COLORS_PACKET_CODEC:Lnet/minecraft/network/codec/PacketCodec;
-
PACKET_CODEC
- Mappings:
Namespace Name Mixin selector official cLctx;c:Lye;intermediary field_49317Lnet/minecraft/class_9283;field_49317:Lnet/minecraft/class_9139;named PACKET_CODECLnet/minecraft/component/type/FireworkExplosionComponent;PACKET_CODEC:Lnet/minecraft/network/codec/PacketCodec;
-
CUSTOM_COLOR_TEXT
- Mappings:
Namespace Name Mixin selector official kLctx;k:Lwg;intermediary field_49320Lnet/minecraft/class_9283;field_49320:Lnet/minecraft/class_2561;named CUSTOM_COLOR_TEXTLnet/minecraft/component/type/FireworkExplosionComponent;CUSTOM_COLOR_TEXT:Lnet/minecraft/text/Text;
-
-
Constructor Details
-
FireworkExplosionComponent
public FireworkExplosionComponent(FireworkExplosionComponent.Type type, IntList intList, IntList intList2, boolean bool, boolean bool2)
-
-
Method Details
-
appendTooltip
- Specified by:
appendTooltipin interfaceTooltipAppender- Mappings:
Namespace Name Mixin selector official aLcuj;a(Ljava/util/function/Consumer;Lcsz;)Vintermediary method_57409Lnet/minecraft/class_9299;method_57409(Ljava/util/function/Consumer;Lnet/minecraft/class_1836;)Vnamed appendTooltipLnet/minecraft/item/TooltipAppender;appendTooltip(Ljava/util/function/Consumer;Lnet/minecraft/client/item/TooltipContext;)V
-
appendShapeTooltip
- Mappings:
Namespace Name Mixin selector official aLctx;a(Ljava/util/function/Consumer;)Vintermediary method_57475Lnet/minecraft/class_9283;method_57475(Ljava/util/function/Consumer;)Vnamed appendShapeTooltipLnet/minecraft/component/type/FireworkExplosionComponent;appendShapeTooltip(Ljava/util/function/Consumer;)V
-
appendOptionalTooltip
- Mappings:
Namespace Name Mixin selector official bLctx;b(Ljava/util/function/Consumer;)Vintermediary method_57477Lnet/minecraft/class_9283;method_57477(Ljava/util/function/Consumer;)Vnamed appendOptionalTooltipLnet/minecraft/component/type/FireworkExplosionComponent;appendOptionalTooltip(Ljava/util/function/Consumer;)V
-
appendColorsTooltipText
- Mappings:
Namespace Name Mixin selector official aLctx;a(Lwu;Lit/unimi/dsi/fastutil/ints/IntList;)Lwg;intermediary method_57476Lnet/minecraft/class_9283;method_57476(Lnet/minecraft/class_5250;Lit/unimi/dsi/fastutil/ints/IntList;)Lnet/minecraft/class_2561;named appendColorsTooltipTextLnet/minecraft/component/type/FireworkExplosionComponent;appendColorsTooltipText(Lnet/minecraft/text/MutableText;Lit/unimi/dsi/fastutil/ints/IntList;)Lnet/minecraft/text/Text;
-
getColorText
- Mappings:
Namespace Name Mixin selector official aLctx;a(I)Lwg;intermediary method_57472Lnet/minecraft/class_9283;method_57472(I)Lnet/minecraft/class_2561;named getColorTextLnet/minecraft/component/type/FireworkExplosionComponent;getColorText(I)Lnet/minecraft/text/Text;
-
withFadeColors
- Mappings:
Namespace Name Mixin selector official aLctx;a(Lit/unimi/dsi/fastutil/ints/IntList;)Lctx;intermediary method_57474Lnet/minecraft/class_9283;method_57474(Lit/unimi/dsi/fastutil/ints/IntList;)Lnet/minecraft/class_9283;named withFadeColorsLnet/minecraft/component/type/FireworkExplosionComponent;withFadeColors(Lit/unimi/dsi/fastutil/ints/IntList;)Lnet/minecraft/component/type/FireworkExplosionComponent;
-
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 '=='. -
shape
Returns the value of theshaperecord component.- Returns:
- the value of the
shaperecord component
-
colors
Returns the value of thecolorsrecord component.- Returns:
- the value of the
colorsrecord component
-
fadeColors
Returns the value of thefadeColorsrecord component.- Returns:
- the value of the
fadeColorsrecord component
-
hasTrail
public boolean hasTrail()Returns the value of thehasTrailrecord component.- Returns:
- the value of the
hasTrailrecord component
-
hasTwinkle
public boolean hasTwinkle()Returns the value of thehasTwinklerecord component.- Returns:
- the value of the
hasTwinklerecord component
-