Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/library
diff options
context:
space:
mode:
Diffstat (limited to 'library')
-rw-r--r--library/pippy/scholar/scholar.py25
1 files changed, 25 insertions, 0 deletions
diff --git a/library/pippy/scholar/scholar.py b/library/pippy/scholar/scholar.py
index 7fba91c..c2c141b 100644
--- a/library/pippy/scholar/scholar.py
+++ b/library/pippy/scholar/scholar.py
@@ -69,4 +69,29 @@ def create_some_rooms():
return [starting, balcony]
+def opposite_exit(side):
+ if side == East:
+ return West
+ elif side == West:
+ return East
+ elif side == North:
+ return South
+ elif side == South:
+ return North
+ elif side == Northwest:
+ return Southeast
+ elif side == Southeast:
+ return Northwest
+ elif side == Northeast:
+ return Suthwest
+ elif side == Southwest:
+ return Northeast
+
+ elif side == Up:
+ return Down
+ elif side == Down:
+ return Up
+
+ else:
+ return side