diff options
author | SmallJoker <SmallJoker@users.noreply.github.com> | 2018-12-13 11:20:57 +0100 |
---|---|---|
committer | Loïc Blot <nerzhul@users.noreply.github.com> | 2018-12-13 11:20:57 +0100 |
commit | 839e935ba0572c592a791cc4dd4df4a9f6d2d260 (patch) | |
tree | 6a7d59e1804879dc24e9e4b1e9ce0294d681bedd /src/client/content_cao.cpp | |
parent | 8471d027b9896af74d2c1ab3b0068af4953e5ca0 (diff) | |
download | minetest-839e935ba0572c592a791cc4dd4df4a9f6d2d260.tar.gz minetest-839e935ba0572c592a791cc4dd4df4a9f6d2d260.tar.bz2 minetest-839e935ba0572c592a791cc4dd4df4a9f6d2d260.zip |
Network: Send IEEE floats (#7768)
Diffstat (limited to 'src/client/content_cao.cpp')
-rw-r--r-- | src/client/content_cao.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/client/content_cao.cpp b/src/client/content_cao.cpp index e2517f7ca..9e4725881 100644 --- a/src/client/content_cao.cpp +++ b/src/client/content_cao.cpp @@ -1347,19 +1347,19 @@ void GenericCAO::processMessage(const std::string &data) } else if (cmd == GENERIC_CMD_UPDATE_POSITION) { // Not sent by the server if this object is an attachment. // We might however get here if the server notices the object being detached before the client. - m_position = readV3F1000(is); - m_velocity = readV3F1000(is); - m_acceleration = readV3F1000(is); + m_position = readV3F32(is); + m_velocity = readV3F32(is); + m_acceleration = readV3F32(is); if (std::fabs(m_prop.automatic_rotate) < 0.001f) - m_rotation = readV3F1000(is); + m_rotation = readV3F32(is); else - readV3F1000(is); + readV3F32(is); m_rotation = wrapDegrees_0_360_v3f(m_rotation); bool do_interpolate = readU8(is); bool is_end_position = readU8(is); - float update_interval = readF1000(is); + float update_interval = readF32(is); // Place us a bit higher if we're physical, to not sink into // the ground due to sucky collision detection... |