|
|
@@ -26,6 +26,10 @@ def sum_donations():
|
|
|
resources[resource][player] = 0
|
|
|
resources[resource][player] += amount
|
|
|
|
|
|
+ if 'total' not in resources[resource]:
|
|
|
+ resources[resource]['total'] = 0
|
|
|
+ resources[resource]['total'] += amount
|
|
|
+
|
|
|
except Exception as exception:
|
|
|
print('exception')
|
|
|
print('%s %s' % (line, exception))
|
|
|
@@ -64,6 +68,8 @@ def calc_reward(resources):
|
|
|
if resource not in reward:
|
|
|
continue
|
|
|
for player, amount in players.items():
|
|
|
+ if player == 'total':
|
|
|
+ continue
|
|
|
if player not in player_reward:
|
|
|
player_reward[player] = 0
|
|
|
player_reward[player] = reward[resource] * amount
|