public override void Draw(float deltaTime, SpriteBatch spriteBatch) { tileMap.Draw(spriteBatch); foreach (var entity in entities) { entity.Draw(deltaTime, spriteBatch); } if (DebugConsole.ShowCollisionLines) { foreach (Sprite sprite in entities) { if (sprite.Collider is BoxCollider) { var r = ((BoxCollider)sprite.Collider).Rectangle; // Draw Outline DebugTools.DrawLine(spriteBatch, new Vector2(r.X, r.Y), new Vector2(r.X + r.Width, r.Y), Color.White, 1); DebugTools.DrawLine(spriteBatch, new Vector2(r.X + r.Width, r.Y), new Vector2(r.X + r.Width, r.Y + r.Height), Color.White, 1); DebugTools.DrawLine(spriteBatch, new Vector2(r.X + r.Width, r.Y + r.Height), new Vector2(r.X, r.Y + r.Height), Color.White, 1); DebugTools.DrawLine(spriteBatch, new Vector2(r.X, r.Y + r.Height), new Vector2(r.X, r.Y), Color.White, 1); } } } }