summaryrefslogtreecommitdiffstats
path: root/weatbag/tiles/s1.py
diff options
context:
space:
mode:
authorThomas Kluyver <takowl@gmail.com>2013-04-24 14:31:55 -0700
committerThomas Kluyver <takowl@gmail.com>2013-04-24 14:31:55 -0700
commit0436b931c9941f5ac49198cffe4c88fd555ed67b (patch)
tree19d5bff7af4d5f3ca080a60774eb374f959b806c /weatbag/tiles/s1.py
parent32db2f567c844ece509a5001233606465474d18f (diff)
parent871d2649c85c56c6b092cffa91a42e2a3210706d (diff)
Merge pull request #18 from lathan/bug_quest
Bug quest
Diffstat (limited to 'weatbag/tiles/s1.py')
-rw-r--r--weatbag/tiles/s1.py14
1 files changed, 14 insertions, 0 deletions
diff --git a/weatbag/tiles/s1.py b/weatbag/tiles/s1.py
index 556a3f3..d1354ec 100644
--- a/weatbag/tiles/s1.py
+++ b/weatbag/tiles/s1.py
@@ -6,3 +6,17 @@ class Tile:
def action(self, player, do):
# Nothing to do here yet.
print("Sorry, I don't understand")
+
+ def leave(self, player, direction):
+ restricted_directions = { 'e' }
+
+ # I placed this restriction here to prevent
+ # early entrance to the bug quest
+ # which should be started by going South from e1
+ if direction in restricted_directions:
+ print("The undergrowth in that direction "
+ "is impassable. You turn back.")
+ return False
+ else:
+ return True
+