Refunding unfulfilled orders on capture.

Fixes https://github.com/Khopa/dcs_liberation/issues/682
This commit is contained in:
Dan Albert
2020-12-28 00:47:42 -08:00
parent 802eff1faa
commit de325c1208
3 changed files with 26 additions and 2 deletions

View File

@@ -189,6 +189,12 @@ class Game:
front_line.control_point_a,
front_line.control_point_b)
def adjust_budget(self, amount: float, player: bool) -> None:
if player:
self.budget += amount
else:
self.enemy_budget += amount
def process_player_income(self):
self.budget += Income(self, player=True).total