Attack detecting radars with low priority.

IADS that are in detection range (but not attack range) of missions will
be targeted at very low priority. These will typically only be planned
when no other targets are in range.
This commit is contained in:
Dan Albert
2021-07-12 17:33:45 -07:00
parent 78514b6c2e
commit c0cc5657a7
5 changed files with 62 additions and 26 deletions

View File

@@ -14,7 +14,6 @@ from game.theater import (
Airfield,
)
from game.theater.theatergroundobject import (
VehicleGroupGroundObject,
NavalGroundObject,
BuildingGroundObject,
IadsGroundObject,
@@ -50,18 +49,6 @@ class ObjectiveFinder:
if isinstance(ground_object, IadsGroundObject):
yield ground_object
def enemy_vehicle_groups(self) -> Iterator[VehicleGroupGroundObject]:
"""Iterates over all enemy vehicle groups."""
for cp in self.enemy_control_points():
for ground_object in cp.ground_objects:
if not isinstance(ground_object, VehicleGroupGroundObject):
continue
if ground_object.is_dead:
continue
yield ground_object
def enemy_ships(self) -> Iterator[NavalGroundObject]:
for cp in self.enemy_control_points():
for ground_object in cp.ground_objects: