Wrap to positive degree values (#5106)
authorraymoo <raymoo@users.noreply.github.com>
Tue, 24 Jan 2017 16:25:11 +0000 (08:25 -0800)
committerLoïc Blot <nerzhul@users.noreply.github.com>
Tue, 24 Jan 2017 16:25:11 +0000 (17:25 +0100)
src/network/serverpackethandler.cpp

index 408fe770671eb94acff684721c0c31c237c98f0c..ac428e8edf6bb7205368fd70d844a689187e0b5f 100644 (file)
@@ -811,7 +811,7 @@ void Server::process_PlayerPos(RemotePlayer *player, PlayerSAO *playersao,
        v3f speed((f32)ss.X / 100.0, (f32)ss.Y / 100.0, (f32)ss.Z / 100.0);
 
        pitch = modulo360f(pitch);
-       yaw = modulo360f(yaw);
+       yaw = wrapDegrees_0_360(yaw);
 
        playersao->setBasePosition(position);
        player->setSpeed(speed);