This repository has been archived on 2026-07-13. You can view files and clone it, but you cannot make any changes to its state, such as pushing and creating new issues, pull requests or comments.
servicepoint-tanks/TanksServer/Graphics/DrawBulletsStep.cs
2024-04-13 14:07:14 +02:00

13 lines
358 B
C#

using DisplayCommands;
using TanksServer.GameLogic;
namespace TanksServer.Graphics;
internal sealed class DrawBulletsStep(BulletManager bullets) : IDrawStep
{
public void Draw(PixelGrid buffer)
{
foreach (var position in bullets.GetAll().Select(b => b.Position.ToPixelPosition()))
buffer[position.X, position.Y] = true;
}
}