diff options
author | Mattes D <github@xoft.cz> | 2015-03-22 23:09:23 +0100 |
---|---|---|
committer | Mattes D <github@xoft.cz> | 2015-03-22 23:09:23 +0100 |
commit | b913c5da69f362abbb70de6e11baca4cbce2b919 (patch) | |
tree | 782854bd86c7165e38459e592fb81979270f732a /src/Protocol/Packetizer.cpp | |
parent | Unified cPacketizer across all protocols. (diff) | |
download | cuberite-b913c5da69f362abbb70de6e11baca4cbce2b919.tar cuberite-b913c5da69f362abbb70de6e11baca4cbce2b919.tar.gz cuberite-b913c5da69f362abbb70de6e11baca4cbce2b919.tar.bz2 cuberite-b913c5da69f362abbb70de6e11baca4cbce2b919.tar.lz cuberite-b913c5da69f362abbb70de6e11baca4cbce2b919.tar.xz cuberite-b913c5da69f362abbb70de6e11baca4cbce2b919.tar.zst cuberite-b913c5da69f362abbb70de6e11baca4cbce2b919.zip |
Diffstat (limited to 'src/Protocol/Packetizer.cpp')
-rw-r--r-- | src/Protocol/Packetizer.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/Protocol/Packetizer.cpp b/src/Protocol/Packetizer.cpp index 2b27f7b2f..0a84d4678 100644 --- a/src/Protocol/Packetizer.cpp +++ b/src/Protocol/Packetizer.cpp @@ -64,7 +64,7 @@ cPacketizer::~cPacketizer() void cPacketizer::WriteByteAngle(double a_Angle) { - WriteChar(static_cast<char>(255 * a_Angle / 360)); + WriteBEInt8(static_cast<Int8>(255 * a_Angle / 360)); } @@ -73,8 +73,7 @@ void cPacketizer::WriteByteAngle(double a_Angle) void cPacketizer::WriteFPInt(double a_Value) { - Int32 Value = static_cast<Int32>(a_Value * 32); - WriteInt(Value); + WriteBEInt32(static_cast<Int32>(a_Value * 32)); } |