diff options
Diffstat (limited to 'src/localplayer.cpp')
-rw-r--r-- | src/localplayer.cpp | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/localplayer.cpp b/src/localplayer.cpp index a4560030..7d427b82 100644 --- a/src/localplayer.cpp +++ b/src/localplayer.cpp @@ -745,13 +745,10 @@ void LocalPlayer::setWalkingDir(int dir) // Else, he is not pressing a key, // and the current path hasn't been sent by mouse, - // then, stop (sending to server). + // then let the path die (1/2 tile after that.) + // This permit to avoid desyncs with other clients. else if (!dir) - { - if (!mPathSetByMouse) - player_node->stopWalking(true); return; - } // If the delay to send another walk message to the server hasn't expired, // don't do anything or we could get disconnected for spamming the server @@ -802,6 +799,10 @@ void LocalPlayer::startWalking(unsigned char dir) if (dir & RIGHT) dx++; + // Update the direction when the walk just start + if (Net::getNetworkType() == ServerInfo::MANASERV) + setDirection(dir); + if (Net::getNetworkType() == ServerInfo::TMWATHENA) { // Prevent skipping corners over colliding tiles |