1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-01-26 03:52:01 +02:00

try to remove glitch

This commit is contained in:
Michael 2023-08-27 22:00:20 +02:00 committed by GitHub
parent 3960e5aa32
commit 3ce9d022d5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -156,8 +156,7 @@ void MapView::postSwipe(uint32_t msPassed)
}
}
swipeHistory.clear();
} else
postSwipeSpeed = 0.0;
}
if(postSwipeSpeed > postSwipeMinimalSpeed) {
double len = postSwipeSpeed * static_cast<double>(msPassed);
Point delta = Point(len * cos(postSwipeAngle), len * sin(postSwipeAngle));