Perform aircraft transfers at the end of the turn.

This commit is contained in:
Dan Albert
2020-11-22 18:42:33 -08:00
parent 7438c30885
commit 493e53c28f
2 changed files with 61 additions and 6 deletions

View File

@@ -61,6 +61,13 @@ class AirLosses:
losses_by_type[loss.flight.unit_type] += loss.flight.count
return losses_by_type
def surviving_flight_members(self, flight: Flight) -> int:
losses = 0
for loss in self.losses:
if loss.flight == flight:
losses += 1
return flight.count - losses
@dataclass(frozen=True)
class StateData: