Record Class SetParticleDataPayload
java.lang.Object
java.lang.Record
com.mrbysco.particlemimicry.networking.SetParticleDataPayload
- All Implemented Interfaces:
net.minecraft.network.protocol.common.custom.CustomPacketPayload
public record SetParticleDataPayload(net.minecraft.core.BlockPos pos, net.minecraft.resources.Identifier dimension, String particleType, String offset, String specialParameters, String delta, String speed, String count, String interval)
extends Record
implements net.minecraft.network.protocol.common.custom.CustomPacketPayload
-
Nested Class Summary
Nested classes/interfaces inherited from interface net.minecraft.network.protocol.common.custom.CustomPacketPayload
net.minecraft.network.protocol.common.custom.CustomPacketPayload.FallbackProvider<B>, net.minecraft.network.protocol.common.custom.CustomPacketPayload.Type<T>, net.minecraft.network.protocol.common.custom.CustomPacketPayload.TypeAndCodec<B,T> -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final net.minecraft.network.codec.StreamCodec<net.minecraft.network.FriendlyByteBuf, SetParticleDataPayload> static final net.minecraft.network.protocol.common.custom.CustomPacketPayload.Type<SetParticleDataPayload> -
Constructor Summary
ConstructorsConstructorDescriptionSetParticleDataPayload(net.minecraft.core.BlockPos pos, net.minecraft.resources.Identifier dimension, String particleType, String offset, String specialParameters, String delta, String speed, String count, String interval) Creates an instance of aSetParticleDataPayloadrecord class.SetParticleDataPayload(net.minecraft.network.FriendlyByteBuf packetBuffer) -
Method Summary
Modifier and TypeMethodDescriptioncount()Returns the value of thecountrecord component.delta()Returns the value of thedeltarecord component.net.minecraft.resources.IdentifierReturns the value of thedimensionrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.interval()Returns the value of theintervalrecord component.offset()Returns the value of theoffsetrecord component.Returns the value of theparticleTyperecord component.net.minecraft.core.BlockPospos()Returns the value of theposrecord component.Returns the value of thespecialParametersrecord component.speed()Returns the value of thespeedrecord component.final StringtoString()Returns a string representation of this record class.net.minecraft.network.protocol.common.custom.CustomPacketPayload.Type<? extends net.minecraft.network.protocol.common.custom.CustomPacketPayload> type()voidwrite(net.minecraft.network.FriendlyByteBuf buf)
-
Field Details
-
CODEC
public static final net.minecraft.network.codec.StreamCodec<net.minecraft.network.FriendlyByteBuf, SetParticleDataPayload> CODEC -
ID
public static final net.minecraft.network.protocol.common.custom.CustomPacketPayload.Type<SetParticleDataPayload> ID
-
-
Constructor Details
-
SetParticleDataPayload
public SetParticleDataPayload(net.minecraft.network.FriendlyByteBuf packetBuffer) -
SetParticleDataPayload
public SetParticleDataPayload(net.minecraft.core.BlockPos pos, net.minecraft.resources.Identifier dimension, String particleType, String offset, String specialParameters, String delta, String speed, String count, String interval) Creates an instance of aSetParticleDataPayloadrecord class.- Parameters:
pos- the value for theposrecord componentdimension- the value for thedimensionrecord componentparticleType- the value for theparticleTyperecord componentoffset- the value for theoffsetrecord componentspecialParameters- the value for thespecialParametersrecord componentdelta- the value for thedeltarecord componentspeed- the value for thespeedrecord componentcount- the value for thecountrecord componentinterval- the value for theintervalrecord component
-
-
Method Details
-
write
public void write(net.minecraft.network.FriendlyByteBuf buf) -
type
public net.minecraft.network.protocol.common.custom.CustomPacketPayload.Type<? extends net.minecraft.network.protocol.common.custom.CustomPacketPayload> type()- Specified by:
typein interfacenet.minecraft.network.protocol.common.custom.CustomPacketPayload
-
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). -
pos
public net.minecraft.core.BlockPos pos()Returns the value of theposrecord component.- Returns:
- the value of the
posrecord component
-
dimension
public net.minecraft.resources.Identifier dimension()Returns the value of thedimensionrecord component.- Returns:
- the value of the
dimensionrecord component
-
particleType
Returns the value of theparticleTyperecord component.- Returns:
- the value of the
particleTyperecord component
-
offset
Returns the value of theoffsetrecord component.- Returns:
- the value of the
offsetrecord component
-
specialParameters
Returns the value of thespecialParametersrecord component.- Returns:
- the value of the
specialParametersrecord component
-
delta
Returns the value of thedeltarecord component.- Returns:
- the value of the
deltarecord component
-
speed
Returns the value of thespeedrecord component.- Returns:
- the value of the
speedrecord component
-
count
Returns the value of thecountrecord component.- Returns:
- the value of the
countrecord component
-
interval
Returns the value of theintervalrecord component.- Returns:
- the value of the
intervalrecord component
-