diff --git a/Jumpy.Shared/Player.cs b/Jumpy.Shared/Player.cs index c03b8fc..241ea99 100644 --- a/Jumpy.Shared/Player.cs +++ b/Jumpy.Shared/Player.cs @@ -38,6 +38,8 @@ namespace Jumpy { Rectangle oldBbox = new Rectangle(oldPosition.X - spriteWidth, oldPosition.Y - 7, spriteWidth * 2, 26); Rectangle playerBbox = new Rectangle(position.X - spriteWidth, position.Y - 7, spriteWidth * 2, 26); bool standingOnGround = false; + // TODO: implement https://en.wikipedia.org/wiki/Bresenham%27s_line_algorithm + // e.g. http://members.chello.at/~easyfilter/bresenham.html foreach (var rect in collisionTargets) { playerBbox = new Rectangle(position.X - spriteWidth, position.Y - 7, spriteWidth * 2, 26);