Round tweened positions to avoid bumping up and down

This commit is contained in:
Michał Janiszewski 2018-03-01 14:09:14 +01:00 committed by Michael Steenbeek
parent 7ce67bea95
commit ad059a540b
1 changed files with 3 additions and 3 deletions

View File

@ -782,9 +782,9 @@ void sprite_position_tween_all(float alpha)
continue;
}
sprite_set_coordinates(
posB.x * alpha + posA.x * inv,
posB.y * alpha + posA.y * inv,
posB.z * alpha + posA.z * inv,
std::round(posB.x * alpha + posA.x * inv),
std::round(posB.y * alpha + posA.y * inv),
std::round(posB.z * alpha + posA.z * inv),
sprite
);
invalidate_sprite_2(sprite);