Explorar o código

Fix freeze on moving through teleporters without set path

Ivan Savenko %!s(int64=2) %!d(string=hai) anos
pai
achega
c330998518
Modificáronse 1 ficheiros con 4 adicións e 7 borrados
  1. 4 7
      client/HeroMovementController.cpp

+ 4 - 7
client/HeroMovementController.cpp

@@ -203,15 +203,12 @@ void HeroMovementController::onTryMoveHero(const CGHeroInstance * hero, const Tr
 
 void HeroMovementController::onQueryReplyApplied()
 {
-	if(duringMovement)
-	{
-		// Server accepted our TeleportDialog query reply and moved hero
-		// Continue moving alongside our path, if any
+	waitingForQueryApplyReply = false;
 
-		assert(waitingForQueryApplyReply);
-		waitingForQueryApplyReply = false;
+	// Server accepted our TeleportDialog query reply and moved hero
+	// Continue moving alongside our path, if any
+	if(duringMovement)
 		onMoveHeroApplied();
-	}
 }
 
 void HeroMovementController::onMoveHeroApplied()