Package devs.beer.nativepackets.api
Interface AddEntityPacketView
- All Superinterfaces:
PacketView
Lazy copy-on-write view of a clientbound entity spawn.
-
Method Summary
Modifier and TypeMethodDescriptionintdata()voiddata(int data) intentityId()voidentityId(int entityId) floatheadYaw()floatpitch()voidposition(double x, double y, double z) voidrotation(float pitch, float yaw, float headYaw) voidvelocity(double x, double y, double z) doubledoubledoubledoublex()doubley()floatyaw()doublez()Methods inherited from interface devs.beer.nativepackets.api.PacketView
isModified, nativeHandle, type
-
Method Details
-
entityId
int entityId()- Returns:
- native entity ID
-
entityUuid
UUID entityUuid()- Returns:
- native entity UUID
-
entityType
NativeValue entityType()- Returns:
- lazy native entity-type handle
-
x
double x()- Returns:
- X position
-
y
double y()- Returns:
- Y position
-
z
double z()- Returns:
- Z position
-
pitch
float pitch()- Returns:
- pitch in degrees
-
yaw
float yaw()- Returns:
- yaw in degrees
-
headYaw
float headYaw()- Returns:
- head yaw in degrees
-
data
int data()- Returns:
- native entity data value
-
velocityX
double velocityX()- Returns:
- X velocity
-
velocityY
double velocityY()- Returns:
- Y velocity
-
velocityZ
double velocityZ()- Returns:
- Z velocity
-
entityId
void entityId(int entityId) - Parameters:
entityId- replacement entity ID
-
position
void position(double x, double y, double z) - Parameters:
x- X positiony- Y positionz- Z position
-
rotation
void rotation(float pitch, float yaw, float headYaw) - Parameters:
pitch- pitch in degreesyaw- yaw in degreesheadYaw- head yaw in degrees
-
data
void data(int data) - Parameters:
data- replacement native entity data
-
velocity
void velocity(double x, double y, double z) - Parameters:
x- X velocityy- Y velocityz- Z velocity
-