summaryrefslogtreecommitdiffstats
path: root/src/Protocol/Protocol14x.cpp
diff options
context:
space:
mode:
authorTycho <work.tycho+git@gmail.com>2014-04-05 23:12:17 +0200
committerTycho <work.tycho+git@gmail.com>2014-04-05 23:12:17 +0200
commit23395a5ce1daab24465d607575c09e06e5b7c449 (patch)
tree18555c220fc6e602b071a935b190ef25444f18a9 /src/Protocol/Protocol14x.cpp
parentFixed tolua++ override support (diff)
parentFixed Endiannes conversion routines for floats and doubles. (diff)
downloadcuberite-23395a5ce1daab24465d607575c09e06e5b7c449.tar
cuberite-23395a5ce1daab24465d607575c09e06e5b7c449.tar.gz
cuberite-23395a5ce1daab24465d607575c09e06e5b7c449.tar.bz2
cuberite-23395a5ce1daab24465d607575c09e06e5b7c449.tar.lz
cuberite-23395a5ce1daab24465d607575c09e06e5b7c449.tar.xz
cuberite-23395a5ce1daab24465d607575c09e06e5b7c449.tar.zst
cuberite-23395a5ce1daab24465d607575c09e06e5b7c449.zip
Diffstat (limited to 'src/Protocol/Protocol14x.cpp')
-rw-r--r--src/Protocol/Protocol14x.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/Protocol/Protocol14x.cpp b/src/Protocol/Protocol14x.cpp
index 232b2718e..f694af1eb 100644
--- a/src/Protocol/Protocol14x.cpp
+++ b/src/Protocol/Protocol14x.cpp
@@ -103,9 +103,9 @@ void cProtocol142::SendPickupSpawn(const cPickup & a_Pickup)
WriteInt (a_Pickup.GetUniqueID());
WriteItem (a_Pickup.GetItem());
WriteVectorI((Vector3i)(a_Pickup.GetPosition() * 32));
- WriteByte ((char)(a_Pickup.GetSpeed().x * 8));
- WriteByte ((char)(a_Pickup.GetSpeed().y * 8));
- WriteByte ((char)(a_Pickup.GetSpeed().z * 8));
+ WriteChar ((char)(a_Pickup.GetSpeed().x * 8));
+ WriteChar ((char)(a_Pickup.GetSpeed().y * 8));
+ WriteChar ((char)(a_Pickup.GetSpeed().z * 8));
Flush();
}
@@ -119,7 +119,7 @@ void cProtocol142::SendSoundParticleEffect(int a_EffectID, int a_SrcX, int a_Src
WriteByte(PACKET_SOUND_PARTICLE_EFFECT);
WriteInt (a_EffectID);
WriteInt (a_SrcX);
- WriteByte(a_SrcY);
+ WriteByte((Byte)a_SrcY);
WriteInt (a_SrcZ);
WriteInt (a_Data);
WriteBool(0);
@@ -218,7 +218,7 @@ void cProtocol146::SendSpawnObject(const cEntity & a_Entity, char a_ObjectType,
cCSLock Lock(m_CSPacket);
WriteByte(PACKET_SPAWN_OBJECT);
WriteInt (a_Entity.GetUniqueID());
- WriteByte(a_ObjectType);
+ WriteChar(a_ObjectType);
WriteInt ((int)(a_Entity.GetPosX() * 32));
WriteInt ((int)(a_Entity.GetPosY() * 32));
WriteInt ((int)(a_Entity.GetPosZ() * 32));
@@ -243,7 +243,7 @@ void cProtocol146::SendSpawnVehicle(const cEntity & a_Vehicle, char a_VehicleTyp
cCSLock Lock(m_CSPacket);
WriteByte (PACKET_SPAWN_OBJECT);
WriteInt (a_Vehicle.GetUniqueID());
- WriteByte (a_VehicleType);
+ WriteChar (a_VehicleType);
WriteInt ((int)(a_Vehicle.GetPosX() * 32));
WriteInt ((int)(a_Vehicle.GetPosY() * 32));
WriteInt ((int)(a_Vehicle.GetPosZ() * 32));