From dda68706253ebfeb6113ab764670309e2b347411 Mon Sep 17 00:00:00 2001 From: Kleopatra Angelidi Date: Wed, 24 Apr 2013 01:59:58 +0300 Subject: added leave function for w(sea) and w(cave) --- weatbag/tiles/n3w1.py | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 weatbag/tiles/n3w1.py (limited to 'weatbag') diff --git a/weatbag/tiles/n3w1.py b/weatbag/tiles/n3w1.py new file mode 100644 index 0000000..5eb7d18 --- /dev/null +++ b/weatbag/tiles/n3w1.py @@ -0,0 +1,17 @@ +class Tile: + def describe(self): + print("The beach is quiet. You see on the south children playing.") + + def action(self, player, do): + print("Sorry, I don't understand") + + def leave(self, player, direction): + if direction=='w': + print("I'm afraid you can't go west.\nThe sea on that part is " + "fool of electric eels and you don't have a transport.") + return False + elif direction=='e': + print("There is the side of a cave in front of you.\nYou can't go " + "east.") + return False + return True -- cgit v1.3