Package dev.latvian.mods.klib.shape
Record Class ColoredShape
java.lang.Object
java.lang.Record
dev.latvian.mods.klib.shape.ColoredShape
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final com.mojang.serialization.Codec<ColoredShape> static final net.minecraft.network.codec.StreamCodec<io.netty.buffer.ByteBuf, ColoredShape> -
Constructor Summary
ConstructorsConstructorDescriptionColoredShape(Shape shape, Gradient quads, Gradient lines) Creates an instance of aColoredShaperecord class. -
Method Summary
Modifier and TypeMethodDescriptionat(double x, double y, double z) at(net.minecraft.world.phys.Vec3 pos) at(org.joml.Vector3dc pos) final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.lines()Returns the value of thelinesrecord component.static ColoredShapestatic ColoredShapequads()Returns the value of thequadsrecord component.static ColoredShapeshape()Returns the value of theshaperecord component.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
CODEC
-
STREAM_CODEC
public static final net.minecraft.network.codec.StreamCodec<io.netty.buffer.ByteBuf,ColoredShape> STREAM_CODEC
-
-
Constructor Details
-
ColoredShape
Creates an instance of aColoredShaperecord class.- Parameters:
shape- the value for theshaperecord componentquads- the value for thequadsrecord componentlines- the value for thelinesrecord component
-
-
Method Details
-
of
-
quads
-
lines
-
at
-
at
-
at
-
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. All components in this record class are compared withObjects::equals(Object,Object). -
shape
Returns the value of theshaperecord component.- Returns:
- the value of the
shaperecord component
-
quads
Returns the value of thequadsrecord component.- Returns:
- the value of the
quadsrecord component
-
lines
Returns the value of thelinesrecord component.- Returns:
- the value of the
linesrecord component
-