Record Class BarricadePalette
java.lang.Object
java.lang.Record
net.modgarden.barricade.attachment.BarricadePalette
public record BarricadePalette(net.minecraft.world.level.chunk.PalettedContainer<net.minecraft.core.Holder<BarricadeData>> palettedContainer)
extends Record
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final com.mojang.serialization.Codec<BarricadePalette> static final com.mojang.serialization.Codec<net.minecraft.world.level.chunk.PalettedContainer<net.minecraft.core.Holder<BarricadeData>>> static final net.minecraft.network.codec.StreamCodec<net.minecraft.network.RegistryFriendlyByteBuf, BarricadePalette> -
Constructor Summary
ConstructorsConstructorDescriptionBarricadePalette(net.minecraft.world.level.chunk.PalettedContainer<net.minecraft.core.Holder<BarricadeData>> palettedContainer) Creates an instance of aBarricadePaletterecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.net.minecraft.world.level.chunk.PalettedContainer<net.minecraft.core.Holder<BarricadeData>> Returns the value of thepalettedContainerrecord component.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
PALETTED_CONTAINER_CODEC
public static final com.mojang.serialization.Codec<net.minecraft.world.level.chunk.PalettedContainer<net.minecraft.core.Holder<BarricadeData>>> PALETTED_CONTAINER_CODEC -
CODEC
-
STREAM_CODEC
public static final net.minecraft.network.codec.StreamCodec<net.minecraft.network.RegistryFriendlyByteBuf, BarricadePalette> STREAM_CODEC
-
-
Constructor Details
-
BarricadePalette
public BarricadePalette(net.minecraft.world.level.chunk.PalettedContainer<net.minecraft.core.Holder<BarricadeData>> palettedContainer) Creates an instance of aBarricadePaletterecord class.- Parameters:
palettedContainer- the value for thepalettedContainerrecord component
-
-
Method Details
-
toString
-
hashCode
-
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. All components in this record class are compared withObjects::equals(Object,Object). -
palettedContainer
public net.minecraft.world.level.chunk.PalettedContainer<net.minecraft.core.Holder<BarricadeData>> palettedContainer()Returns the value of thepalettedContainerrecord component.- Returns:
- the value of the
palettedContainerrecord component
-