Record Class VanillaBlockCodecs.Stem
java.lang.Object
java.lang.Record
net.rebel459.unified.api.registry.VanillaBlockCodecs.Stem
- Enclosing class:
VanillaBlockCodecs
public static record VanillaBlockCodecs.Stem(net.minecraft.world.level.block.Block fruit, net.minecraft.world.level.block.Block attachedStem, net.minecraft.world.item.Item seed, net.minecraft.tags.TagKey<net.minecraft.world.level.block.Block> stemSupportBlocks, net.minecraft.tags.TagKey<net.minecraft.world.level.block.Block> fruitSupportBlocks)
extends Record
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final com.mojang.serialization.MapCodec<VanillaBlockCodecs.Stem> -
Constructor Summary
ConstructorsConstructorDescriptionStem(net.minecraft.world.level.block.Block fruit, net.minecraft.world.level.block.Block attachedStem, net.minecraft.world.item.Item seed, net.minecraft.tags.TagKey<net.minecraft.world.level.block.Block> stemSupportBlocks, net.minecraft.tags.TagKey<net.minecraft.world.level.block.Block> fruitSupportBlocks) Creates an instance of aStemrecord class. -
Method Summary
Modifier and TypeMethodDescriptionnet.minecraft.world.level.block.BlockReturns the value of theattachedStemrecord component.final booleanIndicates whether some other object is "equal to" this one.net.minecraft.world.level.block.Blockfruit()Returns the value of thefruitrecord component.net.minecraft.tags.TagKey<net.minecraft.world.level.block.Block> Returns the value of thefruitSupportBlocksrecord component.final inthashCode()Returns a hash code value for this object.net.minecraft.world.item.Itemseed()Returns the value of theseedrecord component.net.minecraft.tags.TagKey<net.minecraft.world.level.block.Block> Returns the value of thestemSupportBlocksrecord component.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
CODEC
-
-
Constructor Details
-
Stem
public Stem(net.minecraft.world.level.block.Block fruit, net.minecraft.world.level.block.Block attachedStem, net.minecraft.world.item.Item seed, net.minecraft.tags.TagKey<net.minecraft.world.level.block.Block> stemSupportBlocks, net.minecraft.tags.TagKey<net.minecraft.world.level.block.Block> fruitSupportBlocks) Creates an instance of aStemrecord class.- Parameters:
fruit- the value for thefruitrecord componentattachedStem- the value for theattachedStemrecord componentseed- the value for theseedrecord componentstemSupportBlocks- the value for thestemSupportBlocksrecord componentfruitSupportBlocks- the value for thefruitSupportBlocksrecord 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). -
fruit
public net.minecraft.world.level.block.Block fruit()Returns the value of thefruitrecord component.- Returns:
- the value of the
fruitrecord component
-
attachedStem
public net.minecraft.world.level.block.Block attachedStem()Returns the value of theattachedStemrecord component.- Returns:
- the value of the
attachedStemrecord component
-
seed
public net.minecraft.world.item.Item seed()Returns the value of theseedrecord component.- Returns:
- the value of the
seedrecord component
-
stemSupportBlocks
public net.minecraft.tags.TagKey<net.minecraft.world.level.block.Block> stemSupportBlocks()Returns the value of thestemSupportBlocksrecord component.- Returns:
- the value of the
stemSupportBlocksrecord component
-
fruitSupportBlocks
public net.minecraft.tags.TagKey<net.minecraft.world.level.block.Block> fruitSupportBlocks()Returns the value of thefruitSupportBlocksrecord component.- Returns:
- the value of the
fruitSupportBlocksrecord component
-