Class HandInteractionPacket
java.lang.Object
net.timtaran.interactivemc.body.player.packet.HandInteractionPacket
- All Implemented Interfaces:
net.xmx.velthoric.network.IVxNetPacket
- Direct Known Subclasses:
C2SGrabPacket,C2SReleasePacket,C2STriggerStatePacket,S2CGrabResultPacket
public abstract class HandInteractionPacket
extends Object
implements net.xmx.velthoric.network.IVxNetPacket
Base class for packets that involve player body parts interactions.
This abstract class provides common functionality for packets that need to specify which body part is performing the action.
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedHandInteractionPacket(PlayerBodyPart playerBodyPart) Constructs a new hand interaction packet. -
Method Summary
Modifier and TypeMethodDescriptionvoidencode(net.xmx.velthoric.network.VxByteBuf buf) Encodes the packet data into a network buffer.Gets the player body part for this packet.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.xmx.velthoric.network.IVxNetPacket
handle, release
-
Constructor Details
-
HandInteractionPacket
Constructs a new hand interaction packet.- Parameters:
playerBodyPart- the body part performing the interaction
-
-
Method Details
-
encode
public void encode(net.xmx.velthoric.network.VxByteBuf buf) Encodes the packet data into a network buffer.- Specified by:
encodein interfacenet.xmx.velthoric.network.IVxNetPacket- Parameters:
buf- the buffer to write to
-
getPlayerBodyPart
Gets the player body part for this packet.- Returns:
- the player body part
-