summaryrefslogtreecommitdiffstats
path: root/source/Protocol/Protocol14x.cpp
diff options
context:
space:
mode:
authormadmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6>2013-02-21 22:55:36 +0100
committermadmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6>2013-02-21 22:55:36 +0100
commit4ce0c5a983bbb82a0a8091ad735c6ec494c912e2 (patch)
treee87c7544799ce5fd0e54e50caf2b4d909f6e4ca9 /source/Protocol/Protocol14x.cpp
parentAdded HOOK_EXECUTE_COMMAND for intercepting executed commands and console commands. (diff)
downloadcuberite-4ce0c5a983bbb82a0a8091ad735c6ec494c912e2.tar
cuberite-4ce0c5a983bbb82a0a8091ad735c6ec494c912e2.tar.gz
cuberite-4ce0c5a983bbb82a0a8091ad735c6ec494c912e2.tar.bz2
cuberite-4ce0c5a983bbb82a0a8091ad735c6ec494c912e2.tar.lz
cuberite-4ce0c5a983bbb82a0a8091ad735c6ec494c912e2.tar.xz
cuberite-4ce0c5a983bbb82a0a8091ad735c6ec494c912e2.tar.zst
cuberite-4ce0c5a983bbb82a0a8091ad735c6ec494c912e2.zip
Diffstat (limited to '')
-rw-r--r--source/Protocol/Protocol14x.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/source/Protocol/Protocol14x.cpp b/source/Protocol/Protocol14x.cpp
index b70d6e0aa..d19768c5c 100644
--- a/source/Protocol/Protocol14x.cpp
+++ b/source/Protocol/Protocol14x.cpp
@@ -210,7 +210,7 @@ void cProtocol146::SendSpawnFallingBlock(const cFallingBlock & a_FallingBlock)
-void cProtocol146::SendSpawnObject(const cEntity & a_Entity, char a_ObjectType, int a_ObjectData, short a_SpeedX, short a_SpeedY, short a_SpeedZ, Byte a_Yaw, Byte a_Pitch)
+void cProtocol146::SendSpawnObject(const cEntity & a_Entity, char a_ObjectType, int a_ObjectData, Byte a_Yaw, Byte a_Pitch)
{
cCSLock Lock(m_CSPacket);
WriteByte(PACKET_SPAWN_OBJECT);
@@ -222,9 +222,10 @@ void cProtocol146::SendSpawnObject(const cEntity & a_Entity, char a_ObjectType,
WriteInt (a_ObjectData);
if (a_ObjectData != 0)
{
- WriteShort(a_SpeedX);
- WriteShort(a_SpeedY);
- WriteShort(a_SpeedZ);
+ // TODO: Proper speed units
+ WriteShort((short)a_Entity.GetSpeedX());
+ WriteShort((short)a_Entity.GetSpeedY());
+ WriteShort((short)a_Entity.GetSpeedZ());
WriteByte(a_Yaw);
WriteByte(a_Pitch);
}