Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
About the pull request
Changes the
projectile
's visual position toanimate()
across its projected path, providing smoother visuals, especially at higher client framerates.Black squares: tiles actually traversed by the projectile object
Red line: visual path taken by the projectile
Purple marks: equidistant marks corresponding to number of traversed tiles (black squares)
Blue marks: closest points to center of traversed tiles (black squares)
The projectile's physical path (black squares) is unchanged. The system calculates how far along the physical path the projectile has travelled, draws a line from the start point to the end point (red line), then interpolates where along that line corresponds to that distance travelled (purple marks). This is slightly less accurate to the projectile's physical position than the closest point of the line (blue marks), but this slight potential offset is preferred for its smoother visuals.
This does not touch any code that actually effects the bullet's trajectory, this is purely cosmetic.
Tested:
@morrowwolf : this is PR'd upstream, should be safe to testmerge though
Explain why it's good for the game
Smoother apparent movement for projectiles gives a more appealing look.
Testing Photographs and Procedure
Screenshots & Videos
https://streamable.com/h6esir
Changelog
🆑
code: projectiles smoothly animate their movement
/:cl: