Class WrapperPlayServerNamedEntitySpawn
java.lang.Object
com.comphenix.packetwrapper.wrappers.AbstractPacket
com.comphenix.packetwrapper.wrappers.play.clientbound.WrapperPlayServerNamedEntitySpawn
This packet is sent by the server when a player comes into visible range, not when a player joins.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final com.comphenix.protocol.PacketTypeThe packet type that is wrapped by this wrapper.Fields inherited from class com.comphenix.packetwrapper.wrappers.AbstractPacket
handle -
Constructor Summary
ConstructorsConstructorDescriptionConstructs a new wrapper and initialize it with a packet handle with default valuesWrapperPlayServerNamedEntitySpawn(com.comphenix.protocol.events.PacketContainer packet) Constructors a new wrapper for the specified packet -
Method Summary
Modifier and TypeMethodDescriptionintRetrieves entity id of the playerorg.bukkit.LocationgetLocation(org.bukkit.World world) Retrieves the unique id of the playerdoublegetX()Retrieves the value of field 'x'byteRetrieves the value of field 'xRot'doublegetY()Retrieves the value of field 'y'byteRetrieves the discrete rotation around the y-axis (yaw)doublegetZ()Retrieves the value of field 'z'voidsetEntityId(int value) Sets the entity id of the playervoidsetLocation(org.bukkit.Location location) voidsetPlayerId(UUID value) Sets the unique id of the playervoidsetX(double value) Sets the value of field 'x'voidsetXRotRaw(byte value) Sets the discrete rotation around the x-axis (pitch)voidsetY(double value) Sets the value of field 'y'voidsetYRotRaw(byte value) Sets the discrete rotation around the y-axis (yaw)voidsetZ(double value) Sets the value of field 'z'Methods inherited from class com.comphenix.packetwrapper.wrappers.AbstractPacket
broadcastPacket, equals, getHandle, hashCode, receivePacket, sendPacket
-
Field Details
-
TYPE
public static final com.comphenix.protocol.PacketType TYPEThe packet type that is wrapped by this wrapper.
-
-
Constructor Details
-
WrapperPlayServerNamedEntitySpawn
public WrapperPlayServerNamedEntitySpawn()Constructs a new wrapper and initialize it with a packet handle with default values -
WrapperPlayServerNamedEntitySpawn
public WrapperPlayServerNamedEntitySpawn(com.comphenix.protocol.events.PacketContainer packet) Constructors a new wrapper for the specified packet- Parameters:
packet- the packet to wrap
-
-
Method Details
-
getEntityId
public int getEntityId()Retrieves entity id of the player- Returns:
- 'entityId'
-
setEntityId
public void setEntityId(int value) Sets the entity id of the player- Parameters:
value- New value for field 'entityId'
-
getPlayerId
Retrieves the unique id of the player- Returns:
- 'playerId'
-
setPlayerId
Sets the unique id of the player- Parameters:
value- New value for field 'playerId'
-
getX
public double getX()Retrieves the value of field 'x'- Returns:
- 'x'
-
setX
public void setX(double value) Sets the value of field 'x'- Parameters:
value- New value for field 'x'
-
getY
public double getY()Retrieves the value of field 'y'- Returns:
- 'y'
-
setY
public void setY(double value) Sets the value of field 'y'- Parameters:
value- New value for field 'y'
-
getZ
public double getZ()Retrieves the value of field 'z'- Returns:
- 'z'
-
setZ
public void setZ(double value) Sets the value of field 'z'- Parameters:
value- New value for field 'z'
-
getYRotRaw
public byte getYRotRaw()Retrieves the discrete rotation around the y-axis (yaw)- Returns:
- 'yRot'
-
setYRotRaw
public void setYRotRaw(byte value) Sets the discrete rotation around the y-axis (yaw)- Parameters:
value- New value for field 'yRot'
-
getXRotRaw
public byte getXRotRaw()Retrieves the value of field 'xRot'- Returns:
- 'xRot'
-
setXRotRaw
public void setXRotRaw(byte value) Sets the discrete rotation around the x-axis (pitch)- Parameters:
value- New value for field 'xRot'
-
getLocation
public org.bukkit.Location getLocation(@Nullable org.bukkit.World world) -
setLocation
public void setLocation(@Nonnull org.bukkit.Location location)
-