wip client "secret"

This commit is contained in:
Vinzenz Schroeter 2024-04-13 18:35:36 +02:00
parent 698271ae9f
commit b192cd7da0
15 changed files with 117 additions and 71 deletions

View file

@ -32,12 +32,11 @@ internal sealed class DrawTanksStep : IDrawStep
foreach (var tank in _tanks)
{
var tankPosition = tank.Bounds.TopLeft;
var orientation = (int)Math.Round(tank.Rotation * 16d) % 16;
for (byte dy = 0; dy < MapService.TileSize; dy++)
for (byte dx = 0; dx < MapService.TileSize; dx++)
{
if (!TankSpriteAt(dx, dy, orientation))
if (!TankSpriteAt(dx, dy, tank.Orientation))
continue;
var (x, y) = tankPosition.GetPixelRelative(dx, dy);