Record Class FlipYInterpolation
java.lang.Object
java.lang.Record
dev.latvian.mods.klib.interpolation.FlipYInterpolation
- All Implemented Interfaces:
Interpolation
public record FlipYInterpolation(Interpolation interpolation)
extends Record
implements Interpolation
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final com.mojang.serialization.MapCodec<FlipYInterpolation> static final net.minecraft.network.codec.StreamCodec<io.netty.buffer.ByteBuf, FlipYInterpolation> static final InterpolationType<FlipYInterpolation> Fields inherited from interface Interpolation
CODEC, DATA_TYPE, DIRECT_CODEC, UNIT_CODEC -
Constructor Summary
ConstructorsConstructorDescriptionFlipYInterpolation(Interpolation interpolation) Creates an instance of aFlipYInterpolationrecord 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.doubleinterpolate(double t) floatinterpolate(float t) Returns the value of theinterpolationrecord component.@NotNull StringtoString()Returns a string representation of this record class.type()Methods inherited from interface Interpolation
composite, flipX, flipY, interpolate, interpolate, interpolate, interpolate, interpolateClamped, interpolateClamped, interpolateMirrored, interpolateMirrored, inverse, isLinear, join
-
Field Details
-
MAP_CODEC
-
STREAM_CODEC
public static final net.minecraft.network.codec.StreamCodec<io.netty.buffer.ByteBuf, FlipYInterpolation> STREAM_CODEC -
TYPE
-
-
Constructor Details
-
FlipYInterpolation
Creates an instance of aFlipYInterpolationrecord class.- Parameters:
interpolation- the value for theinterpolationrecord component
-
-
Method Details
-
type
- Specified by:
typein interfaceInterpolation
-
interpolate
public double interpolate(double t) - Specified by:
interpolatein interfaceInterpolation
-
interpolate
public float interpolate(float t) - Specified by:
interpolatein interfaceInterpolation
-
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). -
interpolation
Returns the value of theinterpolationrecord component.- Returns:
- the value of the
interpolationrecord component
-