From c3b028ef4ba42f3f4a980654616afe0f77a45fb3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ignacio=20Mu=C3=B1oz=20Fernandez?= Date: Fri, 20 Nov 2020 12:47:35 +0100 Subject: [PATCH] fix: fixes #325 for version 2.2.x --- game/game.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/game/game.py b/game/game.py index 7308a128..8895d405 100644 --- a/game/game.py +++ b/game/game.py @@ -154,7 +154,7 @@ class Game: reward = PLAYER_BUDGET_BASE * len(self.theater.player_points()) for cp in self.theater.player_points(): for g in cp.ground_objects: - if g.category in REWARDS.keys(): + if g.category in REWARDS.keys() and not g.is_dead: reward = reward + REWARDS[g.category] return reward else: @@ -277,7 +277,7 @@ class Game: production = 0.0 for enemy_point in self.theater.enemy_points(): for g in enemy_point.ground_objects: - if g.category in REWARDS.keys(): + if g.category in REWARDS.keys() and not g.is_dead: production = production + REWARDS[g.category] production = production * 0.75