Record Class WorldGenAttemptDebugPayload
java.lang.Object
java.lang.Record
net.minecraft.network.protocol.common.custom.WorldGenAttemptDebugPayload
- All Implemented Interfaces:
CustomPacketPayload
public record WorldGenAttemptDebugPayload(BlockPos pos, float scale, float red, float green, float blue, float alpha)
extends Record
implements CustomPacketPayload
-
Nested Class Summary
Nested classes/interfaces inherited from interface net.minecraft.network.protocol.common.custom.CustomPacketPayload
CustomPacketPayload.FallbackProvider<B extends FriendlyByteBuf>, CustomPacketPayload.Type<T extends CustomPacketPayload>, CustomPacketPayload.TypeAndCodec<B extends FriendlyByteBuf,
T extends CustomPacketPayload> -
Field Summary
Modifier and TypeFieldDescriptionprivate final float
The field for thealpha
record component.private final float
The field for theblue
record component.private final float
The field for thegreen
record component.private final BlockPos
The field for thepos
record component.private final float
The field for thered
record component.private final float
The field for thescale
record component.static final StreamCodec
<FriendlyByteBuf, WorldGenAttemptDebugPayload> static final CustomPacketPayload.Type
<WorldGenAttemptDebugPayload> -
Constructor Summary
ModifierConstructorDescriptionWorldGenAttemptDebugPayload
(BlockPos pos, float scale, float red, float green, float blue, float alpha) Creates an instance of aWorldGenAttemptDebugPayload
record class.private
WorldGenAttemptDebugPayload
(FriendlyByteBuf p_295574_) -
Method Summary
Modifier and TypeMethodDescriptionfloat
alpha()
Returns the value of thealpha
record component.float
blue()
Returns the value of theblue
record component.final boolean
Indicates whether some other object is "equal to" this one.float
green()
Returns the value of thegreen
record component.final int
hashCode()
Returns a hash code value for this object.pos()
Returns the value of thepos
record component.float
red()
Returns the value of thered
record component.float
scale()
Returns the value of thescale
record component.final String
toString()
Returns a string representation of this record class.type()
private void
write
(FriendlyByteBuf p_295822_)
-
Field Details
-
pos
The field for thepos
record component. -
scale
private final float scaleThe field for thescale
record component. -
red
private final float redThe field for thered
record component. -
green
private final float greenThe field for thegreen
record component. -
blue
private final float blueThe field for theblue
record component. -
alpha
private final float alphaThe field for thealpha
record component. -
STREAM_CODEC
-
TYPE
-
-
Constructor Details
-
WorldGenAttemptDebugPayload
-
WorldGenAttemptDebugPayload
public WorldGenAttemptDebugPayload(BlockPos pos, float scale, float red, float green, float blue, float alpha) Creates an instance of aWorldGenAttemptDebugPayload
record class.- Parameters:
pos
- the value for thepos
record componentscale
- the value for thescale
record componentred
- the value for thered
record componentgreen
- the value for thegreen
record componentblue
- the value for theblue
record componentalpha
- the value for thealpha
record component
-
-
Method Details
-
write
-
type
- Specified by:
type
in interfaceCustomPacketPayload
-
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. Reference components are compared withObjects::equals(Object,Object)
; primitive components are compared with '=='. -
pos
Returns the value of thepos
record component.- Returns:
- the value of the
pos
record component
-
scale
public float scale()Returns the value of thescale
record component.- Returns:
- the value of the
scale
record component
-
red
public float red()Returns the value of thered
record component.- Returns:
- the value of the
red
record component
-
green
public float green()Returns the value of thegreen
record component.- Returns:
- the value of the
green
record component
-
blue
public float blue()Returns the value of theblue
record component.- Returns:
- the value of the
blue
record component
-
alpha
public float alpha()Returns the value of thealpha
record component.- Returns:
- the value of the
alpha
record component
-