Streamlining

This commit is contained in:
Raffson
2023-10-01 20:14:22 +02:00
parent 110866cd34
commit d4eefd0b55
15 changed files with 68 additions and 42 deletions

View File

@@ -275,7 +275,7 @@ class AircraftGenerator:
or flight.client_count
and (
not self.need_ecm
or flight.loadout.has_weapon_of_type(WeaponType.JAMMER)
or flight.any_member_has_weapon_of_type(WeaponType.JAMMER)
)
):
self.ewrj_package_dict[id(flight.package)].append(group)

View File

@@ -149,7 +149,7 @@ class FlightGroupSpawner:
raise RuntimeError(
f"Cannot spawn fixed-wing aircraft at {cp} because of insufficient ground spawn slots."
)
pilot_count = len(self.flight.roster.pilots)
pilot_count = len(self.flight.roster.members)
if (
not is_heli
and self.flight.roster.player_count != pilot_count