From c2e70e28b9b2da3a495b536215391e786d65a34d Mon Sep 17 00:00:00 2001 From: Quentin Bazin Date: Sun, 26 Jan 2020 15:38:25 +0900 Subject: [PATCH] [ClientPlayer] Slightly reduce velocity in X/Z while jumping/falling. --- client/source/world/ClientPlayer.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/client/source/world/ClientPlayer.cpp b/client/source/world/ClientPlayer.cpp index 04772beb0..93866ed35 100644 --- a/client/source/world/ClientPlayer.cpp +++ b/client/source/world/ClientPlayer.cpp @@ -112,6 +112,11 @@ void ClientPlayer::updatePosition(const ClientWorld &world) { if (!Config::isNoClipEnabled) checkCollisions(world); + if (!Config::isFlyModeEnabled && m_velocity.y != 0) { + m_velocity.x *= 0.75f; + m_velocity.z *= 0.75f; + } + m_x += m_velocity.x; m_y += m_velocity.y; m_z += m_velocity.z;