Class EntitySpawnS2CPacket
java.lang.Object
net.minecraft.network.packet.s2c.play.EntitySpawnS2CPacket
- All Implemented Interfaces:
Packet<ClientPlayPacketListener>
public class EntitySpawnS2CPacket extends Object implements Packet<ClientPlayPacketListener>
-
Field Summary
Fields Modifier and Type Field Description private intentityDataprivate EntityType<?>entityTypeIdprivate intidprivate intpitchprivate UUIDuuidprivate intvelocityXprivate intvelocityYprivate intvelocityZprivate doublexprivate doubleyprivate intyawprivate doublez -
Constructor Summary
Constructors Constructor Description EntitySpawnS2CPacket()EntitySpawnS2CPacket(int id, UUID uuid, double x, double y, double z, float pitch, float yaw, EntityType<?> entityTypeId, int entityData, Vec3d velocity)EntitySpawnS2CPacket(Entity entity)EntitySpawnS2CPacket(Entity entity, int entityData)EntitySpawnS2CPacket(Entity entity, EntityType<?> entityType, int data, BlockPos pos) -
Method Summary
Modifier and Type Method Description voidapply(ClientPlayPacketListener clientPlayPacketListener)intgetEntityData()EntityType<?>getEntityTypeId()intgetId()intgetPitch()UUIDgetUuid()doublegetVelocityX()doublegetVelocityY()doublegetVelocityZ()doublegetX()doublegetY()intgetYaw()doublegetZ()voidread(PacketByteBuf buf)voidwrite(PacketByteBuf buf)Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.minecraft.network.Packet
isWritingErrorSkippable
-
Field Details
-
id
private int id -
uuid
-
x
private double x -
y
private double y -
z
private double z -
velocityX
private int velocityX -
velocityY
private int velocityY -
velocityZ
private int velocityZ -
pitch
private int pitch -
yaw
private int yaw -
entityTypeId
-
entityData
private int entityData
-
-
Constructor Details
-
EntitySpawnS2CPacket
public EntitySpawnS2CPacket() -
EntitySpawnS2CPacket
public EntitySpawnS2CPacket(int id, UUID uuid, double x, double y, double z, float pitch, float yaw, EntityType<?> entityTypeId, int entityData, Vec3d velocity) -
EntitySpawnS2CPacket
-
EntitySpawnS2CPacket
-
EntitySpawnS2CPacket
-
-
Method Details
-
read
- Specified by:
readin interfacePacket<ClientPlayPacketListener>- Throws:
IOException
-
write
- Specified by:
writein interfacePacket<ClientPlayPacketListener>- Throws:
IOException
-
apply
- Specified by:
applyin interfacePacket<ClientPlayPacketListener>
-
getId
@Environment(CLIENT) public int getId() -
getUuid
-
getX
@Environment(CLIENT) public double getX() -
getY
@Environment(CLIENT) public double getY() -
getZ
@Environment(CLIENT) public double getZ() -
getVelocityX
@Environment(CLIENT) public double getVelocityX() -
getVelocityY
@Environment(CLIENT) public double getVelocityY() -
getVelocityZ
@Environment(CLIENT) public double getVelocityZ() -
getPitch
@Environment(CLIENT) public int getPitch() -
getYaw
@Environment(CLIENT) public int getYaw() -
getEntityTypeId
-
getEntityData
@Environment(CLIENT) public int getEntityData()
-