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.PacketType
The 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 TypeMethodDescriptionint
Retrieves entity id of the playerorg.bukkit.Location
getLocation
(org.bukkit.World world) Retrieves the unique id of the playerdouble
getX()
Retrieves the value of field 'x'byte
Retrieves the value of field 'xRot'double
getY()
Retrieves the value of field 'y'byte
Retrieves the discrete rotation around the y-axis (yaw)double
getZ()
Retrieves the value of field 'z'void
setEntityId
(int value) Sets the entity id of the playervoid
setLocation
(org.bukkit.Location location) void
setPlayerId
(UUID value) Sets the unique id of the playervoid
setX
(double value) Sets the value of field 'x'void
setXRotRaw
(byte value) Sets the discrete rotation around the x-axis (pitch)void
setY
(double value) Sets the value of field 'y'void
setYRotRaw
(byte value) Sets the discrete rotation around the y-axis (yaw)void
setZ
(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)
-