mirror of
https://gitlab.bixilon.de/bixilon/minosoft.git
synced 2025-09-19 12:25:12 -04:00
network: fix entity spawn packet reading (22w14a+)
This commit is contained in:
parent
ef53f03080
commit
6646abd553
@ -50,11 +50,11 @@ class EntityObjectSpawnS2CP(buffer: PlayInByteBuffer) : PlayS2CPacket {
|
||||
} else {
|
||||
buffer.readVec3d()
|
||||
}
|
||||
val rotation = EntityRotation(buffer.readAngle().toDouble(), buffer.readAngle().toDouble())
|
||||
val rotation = EntityRotation(buffer.readAngle().toDouble(), buffer.readAngle().toDouble()) // ToDo: Is yaw/pitch swapped?
|
||||
if (buffer.versionId >= ProtocolVersions.V_22W14A) {
|
||||
val headYaw = buffer.readAngle()
|
||||
}
|
||||
val data = buffer.readInt()
|
||||
val data = if (buffer.versionId >= ProtocolVersions.V_22W14A) buffer.readVarInt() else buffer.readInt()
|
||||
|
||||
if (buffer.versionId >= ProtocolVersions.V_15W31A || data != 0) {
|
||||
velocity = buffer.readVelocity()
|
||||
|
Loading…
x
Reference in New Issue
Block a user