mirror of
https://github.com/dcs-retribution/dcs-retribution.git
synced 2025-11-10 15:41:24 +00:00
Separate combat as a distinct flight state.
Will be used later to simulate combat. https://github.com/dcs-liberation/dcs_liberation/issues/1680
This commit is contained in:
@@ -40,7 +40,11 @@ class AircraftSimulation:
|
||||
blue_a2a = AircraftEngagementZones.from_ato(self.game.blue.ato)
|
||||
red_a2a = AircraftEngagementZones.from_ato(self.game.red.ato)
|
||||
for flight in self.iter_flights():
|
||||
if flight.should_halt_sim(red_a2a if flight.squadron.player else blue_a2a):
|
||||
flight.check_for_combat(red_a2a if flight.squadron.player else blue_a2a)
|
||||
|
||||
# After updating all combat states, check for halts.
|
||||
for flight in self.iter_flights():
|
||||
if flight.should_halt_sim():
|
||||
return True
|
||||
return False
|
||||
|
||||
|
||||
Reference in New Issue
Block a user