From 3576b6cfa39467478565b704de0160fc48c9a181 Mon Sep 17 00:00:00 2001 From: Christian Heller Date: Sat, 12 Jan 2019 22:40:32 +0100 Subject: [PATCH] Improve invisibility depiction. --- server.py | 2 +- server_/game.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/server.py b/server.py index c5fbff4..fc095b7 100755 --- a/server.py +++ b/server.py @@ -162,7 +162,7 @@ class CommandHandler(game_common.Commander, server_.game.Commander): self.send('MAP_SIZE ' + stringify_yx(self.world.map_.size)) visible_map = self.world.get_player().get_visible_map() for y in range(self.world.map_.size[0]): - self.send('VISIBLE_MAP_LINE %5s %s' % (y, visible_map.get_line(y))) + self.send('VISIBLE_MAP_LINE %5s "%s"' % (y, visible_map.get_line(y))) for thing in self.world.things: self.send('THING_TYPE %s %s' % (thing.id_, thing.type_)) self.send('THING_POS %s %s' % (thing.id_, diff --git a/server_/game.py b/server_/game.py index 7e15247..f6a5e9e 100644 --- a/server_/game.py +++ b/server_/game.py @@ -146,7 +146,7 @@ class Thing(game_common.Thing): def get_visible_map(self): size = self.world.map_.size - m = Map(size, '?'*size[0]*size[1]) + m = Map(size, ' '*size[0]*size[1]) y_me = self.position[0] x_me = self.position[1] for y in range(m.size[0]): -- 2.30.2