Class NbtComponent

java.lang.Object
net.minecraft.component.type.NbtComponent

public final class NbtComponent extends Object
Mappings:
Namespace Name
named net/minecraft/component/type/NbtComponent
intermediary net/minecraft/class_9279
official djy
  • Field Details

    • DEFAULT

      public static final NbtComponent DEFAULT
      Mappings:
      Namespace Name Mixin selector
      named DEFAULT Lnet/minecraft/component/type/NbtComponent;DEFAULT:Lnet/minecraft/component/type/NbtComponent;
      intermediary field_49302 Lnet/minecraft/class_9279;field_49302:Lnet/minecraft/class_9279;
      official a Ldjy;a:Ldjy;
    • COMPOUND_CODEC

      public static final com.mojang.serialization.Codec<NbtCompound> COMPOUND_CODEC
      Mappings:
      Namespace Name Mixin selector
      named COMPOUND_CODEC Lnet/minecraft/component/type/NbtComponent;COMPOUND_CODEC:Lcom/mojang/serialization/Codec;
      intermediary field_61351 Lnet/minecraft/class_9279;field_61351:Lcom/mojang/serialization/Codec;
      official b Ldjy;b:Lcom/mojang/serialization/Codec;
    • CODEC

      public static final com.mojang.serialization.Codec<NbtComponent> CODEC
      Mappings:
      Namespace Name Mixin selector
      named CODEC Lnet/minecraft/component/type/NbtComponent;CODEC:Lcom/mojang/serialization/Codec;
      intermediary field_49303 Lnet/minecraft/class_9279;field_49303:Lcom/mojang/serialization/Codec;
      official c Ldjy;c:Lcom/mojang/serialization/Codec;
    • PACKET_CODEC

      @Deprecated public static final PacketCodec<ByteBuf,NbtComponent> PACKET_CODEC
      Deprecated.
      Mappings:
      Namespace Name Mixin selector
      named PACKET_CODEC Lnet/minecraft/component/type/NbtComponent;PACKET_CODEC:Lnet/minecraft/network/codec/PacketCodec;
      intermediary field_49305 Lnet/minecraft/class_9279;field_49305:Lnet/minecraft/class_9139;
      official d Ldjy;d:Laae;
    • nbt

      private final NbtCompound nbt
      Mappings:
      Namespace Name Mixin selector
      named nbt Lnet/minecraft/component/type/NbtComponent;nbt:Lnet/minecraft/nbt/NbtCompound;
      intermediary field_49306 Lnet/minecraft/class_9279;field_49306:Lnet/minecraft/class_2487;
      official e Ldjy;e:Lup;
  • Constructor Details

    • NbtComponent

      private NbtComponent(NbtCompound nbt)
      Mappings:
      Namespace Name Mixin selector
      named <init> Lnet/minecraft/component/type/NbtComponent;<init>(Lnet/minecraft/nbt/NbtCompound;)V
      intermediary <init> Lnet/minecraft/class_9279;<init>(Lnet/minecraft/class_2487;)V
      official <init> Ldjy;<init>(Lup;)V
  • Method Details

    • of

      public static NbtComponent of(NbtCompound nbt)
      Mappings:
      Namespace Name Mixin selector
      named of Lnet/minecraft/component/type/NbtComponent;of(Lnet/minecraft/nbt/NbtCompound;)Lnet/minecraft/component/type/NbtComponent;
      intermediary method_57456 Lnet/minecraft/class_9279;method_57456(Lnet/minecraft/class_2487;)Lnet/minecraft/class_9279;
      official a Ldjy;a(Lup;)Ldjy;
    • matches

      public boolean matches(NbtCompound nbt)
      Mappings:
      Namespace Name Mixin selector
      named matches Lnet/minecraft/component/type/NbtComponent;matches(Lnet/minecraft/nbt/NbtCompound;)Z
      intermediary method_57460 Lnet/minecraft/class_9279;method_57460(Lnet/minecraft/class_2487;)Z
      official b Ldjy;b(Lup;)Z
    • set

      public static void set(ComponentType<NbtComponent> type, ItemStack stack, Consumer<NbtCompound> nbtSetter)
      Mappings:
      Namespace Name Mixin selector
      named set Lnet/minecraft/component/type/NbtComponent;set(Lnet/minecraft/component/ComponentType;Lnet/minecraft/item/ItemStack;Ljava/util/function/Consumer;)V
      intermediary method_57452 Lnet/minecraft/class_9279;method_57452(Lnet/minecraft/class_9331;Lnet/minecraft/class_1799;Ljava/util/function/Consumer;)V
      official a Ldjy;a(Lko;Ldhp;Ljava/util/function/Consumer;)V
    • set

      public static void set(ComponentType<NbtComponent> type, ItemStack stack, NbtCompound nbt)
      Mappings:
      Namespace Name Mixin selector
      named set Lnet/minecraft/component/type/NbtComponent;set(Lnet/minecraft/component/ComponentType;Lnet/minecraft/item/ItemStack;Lnet/minecraft/nbt/NbtCompound;)V
      intermediary method_57453 Lnet/minecraft/class_9279;method_57453(Lnet/minecraft/class_9331;Lnet/minecraft/class_1799;Lnet/minecraft/class_2487;)V
      official a Ldjy;a(Lko;Ldhp;Lup;)V
    • apply

      public NbtComponent apply(Consumer<NbtCompound> nbtConsumer)
      Mappings:
      Namespace Name Mixin selector
      named apply Lnet/minecraft/component/type/NbtComponent;apply(Ljava/util/function/Consumer;)Lnet/minecraft/component/type/NbtComponent;
      intermediary method_57451 Lnet/minecraft/class_9279;method_57451(Ljava/util/function/Consumer;)Lnet/minecraft/class_9279;
      official a Ldjy;a(Ljava/util/function/Consumer;)Ldjy;
    • isEmpty

      public boolean isEmpty()
      Mappings:
      Namespace Name Mixin selector
      named isEmpty Lnet/minecraft/component/type/NbtComponent;isEmpty()Z
      intermediary method_57458 Lnet/minecraft/class_9279;method_57458()Z
      official a Ldjy;a()Z
    • copyNbt

      public NbtCompound copyNbt()
      Mappings:
      Namespace Name Mixin selector
      named copyNbt Lnet/minecraft/component/type/NbtComponent;copyNbt()Lnet/minecraft/nbt/NbtCompound;
      intermediary method_57461 Lnet/minecraft/class_9279;method_57461()Lnet/minecraft/class_2487;
      official b Ldjy;b()Lup;
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
      Mappings:
      Namespace Name Mixin selector
      named equals Lnet/minecraft/component/type/NbtComponent;equals(Ljava/lang/Object;)Z
      intermediary equals Lnet/minecraft/class_9279;equals(Ljava/lang/Object;)Z
      official equals Ldjy;equals(Ljava/lang/Object;)Z
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object