summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--robots/cursesviewer.py9
1 files changed, 6 insertions, 3 deletions
diff --git a/robots/cursesviewer.py b/robots/cursesviewer.py
index af0b87a..4221117 100644
--- a/robots/cursesviewer.py
+++ b/robots/cursesviewer.py
@@ -24,7 +24,7 @@ class CursesViewer:
game.state.players,
colours,
))
- self.player_colours['*'] = 'white'
+ self.player_colours[City.GHOST] = 'white'
def draw_board(self, state):
print(self.terminal.clear, end='')
@@ -37,7 +37,10 @@ class CursesViewer:
for x, cell in enumerate(row):
value = ' '
- background = self.player_colours.get(cell['allegiance'])
+ if cell['city'] == City.GHOST:
+ background = 'white'
+ else:
+ background = self.player_colours.get(cell['allegiance'])
if cell['robots']:
(robot_owner, energy), = cell['robots']
@@ -67,7 +70,7 @@ class CursesViewer:
print(Box.BL + Box.H * width + Box.BR)
def run(self):
- limiter = rate_limit(20)
+ limiter = rate_limit(10)
for state in self.game:
next(limiter)