From 4887fa9463fac79db716dac16724bf8008d306c4 Mon Sep 17 00:00:00 2001 From: Kleopatra Angelidi Date: Tue, 30 Apr 2013 18:22:59 +0300 Subject: merged two ifs on leave function in one --- weatbag/tiles/n3w4.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/weatbag/tiles/n3w4.py b/weatbag/tiles/n3w4.py index d4f238b..aeb58f9 100644 --- a/weatbag/tiles/n3w4.py +++ b/weatbag/tiles/n3w4.py @@ -10,10 +10,7 @@ class Tile: print("Sorry, I don't understand.\n") def leave(self, player, direction): - if direction == "n": - print("No trespasing. Violators will vanish without a trace.\n") - return False - elif direction == "w": + if direction in ('n', 'w'): print("No trespasing. Violators will vanish without a trace.\n") return False else: -- cgit v1.3