From 9df568d22db6eb2f6239eaa1ca5368f2501627c7 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Fri, 12 Apr 2013 22:48:01 +0300 Subject: fix warp issue after playerhandler class changes. --- src/net/ea/playerhandler.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/net/ea/playerhandler.cpp b/src/net/ea/playerhandler.cpp index 1073d5075..ed49b7ae5 100644 --- a/src/net/ea/playerhandler.cpp +++ b/src/net/ea/playerhandler.cpp @@ -238,11 +238,11 @@ void PlayerHandler::processPlayerWarp(Net::MessageIn &msg) const scrollOffsetY = (y - player_node->getTileY()) * map->getTileHeight(); } - scrollOffsetX = (x - player_node->getTileX()) - * map->getTileWidth(); - scrollOffsetY = (y - player_node->getTileY()) - * map->getTileHeight(); } + + player_node->setAction(Being::STAND); + player_node->setTileCoords(x, y); + player_node->navigateClean(); } logger->log("Adjust scrolling by %d:%d", scrollOffsetX, scrollOffsetY); -- cgit v1.2.3-70-g09d2