add power ups collected score

This commit is contained in:
Vinzenz Schroeter 2024-04-29 13:54:29 +02:00
parent bf22fd6c85
commit 259d63d683
8 changed files with 45 additions and 32 deletions

View file

@ -20,8 +20,9 @@ internal sealed class CollectPowerUp(
position.Y < topLeft.Y || position.Y > bottomRight.Y)
continue;
// this works because now the tank overlaps the power up
// now the tank overlaps the power up by at least 0.5 tiles
tank.ExplosiveBullets += 10;
tank.Owner.Scores.PowerUpsCollected++;
return true;
}