fixes for selectable departure; generate statics for used units; raised RTB alt

This commit is contained in:
Vasyl Horbachenko
2018-11-05 03:17:06 +02:00
parent 355cd3e0e4
commit 9d0997624b
17 changed files with 57 additions and 26 deletions

View File

@@ -61,7 +61,8 @@ class BaseAttackEvent(Event):
op = BaseAttackOperation(game=self.game,
attacker_name=self.attacker_name,
defender_name=self.defender_name,
from_cp=self.departure_cp,
from_cp=self.from_cp,
departure_cp=self.departure_cp,
to_cp=self.to_cp)
op.setup(cas=assigned_units_from(cas),
@@ -79,7 +80,8 @@ class BaseAttackEvent(Event):
op = BaseAttackOperation(game=self.game,
attacker_name=self.attacker_name,
defender_name=self.defender_name,
from_cp=self.departure_cp,
from_cp=self.from_cp,
departure_cp=self.departure_cp,
to_cp=self.to_cp)
defenders = self.to_cp.base.scramble_sweep(self.game.settings.multiplier)

View File

@@ -68,6 +68,7 @@ class FrontlineAttackEvent(Event):
attacker_name=self.attacker_name,
defender_name=self.defender_name,
from_cp=self.from_cp,
departure_cp=self.departure_cp,
to_cp=self.to_cp)
defenders = self.to_cp.base.assemble_attack()

View File

@@ -64,6 +64,7 @@ class FrontlinePatrolEvent(Event):
attacker_name=self.attacker_name,
defender_name=self.defender_name,
from_cp=self.from_cp,
departure_cp=self.departure_cp,
to_cp=self.to_cp)
defenders = self.to_cp.base.assemble_attack()

View File

@@ -44,7 +44,8 @@ class InfantryTransportEvent(Event):
game=self.game,
attacker_name=self.attacker_name,
defender_name=self.defender_name,
from_cp=self.departure_cp,
from_cp=self.from_cp,
departure_cp=self.departure_cp,
to_cp=self.to_cp
)

View File

@@ -56,7 +56,8 @@ class InsurgentAttackEvent(Event):
op = InsurgentAttackOperation(game=self.game,
attacker_name=self.attacker_name,
defender_name=self.defender_name,
from_cp=self.departure_cp,
from_cp=self.from_cp,
departure_cp=self.departure_cp,
to_cp=self.to_cp)
op.setup(target=self.targets,
strikegroup=flights[CAS])

View File

@@ -76,7 +76,8 @@ class InterceptEvent(Event):
op = InterceptOperation(game=self.game,
attacker_name=self.attacker_name,
defender_name=self.defender_name,
from_cp=self.departure_cp,
from_cp=self.from_cp,
departure_cp=self.departure_cp,
to_cp=self.to_cp)
op.setup(location=self.location,
@@ -98,7 +99,8 @@ class InterceptEvent(Event):
op = InterceptOperation(game=self.game,
attacker_name=self.attacker_name,
defender_name=self.defender_name,
from_cp=self.departure_cp,
from_cp=self.from_cp,
departure_cp=self.departure_cp,
to_cp=self.to_cp)
op.setup(escort=flights[CAP],

View File

@@ -84,7 +84,8 @@ class NavalInterceptEvent(Event):
self.game,
attacker_name=self.attacker_name,
defender_name=self.defender_name,
from_cp=self.departure_cp,
from_cp=self.from_cp,
departure_cp=self.departure_cp,
to_cp=self.to_cp
)
@@ -106,7 +107,8 @@ class NavalInterceptEvent(Event):
self.game,
attacker_name=self.attacker_name,
defender_name=self.defender_name,
from_cp=self.departure_cp,
from_cp=self.from_cp,
departure_cp=self.departure_cp,
to_cp=self.to_cp
)

View File

@@ -49,7 +49,8 @@ class StrikeEvent(Event):
self.game,
attacker_name=self.attacker_name,
defender_name=self.defender_name,
from_cp=self.departure_cp,
from_cp=self.from_cp,
departure_cp=self.departure_cp,
to_cp=self.to_cp
)