diff gamelib/scenes/bridge.py @ 242:12c4f87ea424

Unify doors a bit
author Neil Muller <neil@dip.sun.ac.za>
date Fri, 27 Aug 2010 11:32:49 +0200
parents ae01c10497b3
children 37f892b59c4b
line wrap: on
line diff
--- a/gamelib/scenes/bridge.py	Fri Aug 27 10:37:47 2010 +0200
+++ b/gamelib/scenes/bridge.py	Fri Aug 27 11:32:49 2010 +0200
@@ -4,6 +4,7 @@
 from gamelib.state import Scene, Item, Thing, Result, InteractText, \
                           InteractNoImage, InteractRectUnion
 from gamelib.statehelpers import GenericDescThing
+from gamelib.scenes.scene_widgets import Door
 
 class Bridge(Scene):
 
@@ -27,11 +28,9 @@
         return Result("The bridge is in a sorry, shabby state")
 
 
-class ToMap(Thing):
-    "Way to map."
+class ToMap(Door):
 
     NAME = "bridge.tomap"
-    DEST = "map"
 
     INTERACTS = {
         "door": InteractNoImage(707, 344, 84, 245),
@@ -39,10 +38,6 @@
 
     INITIAL = "door"
 
-    def interact_without(self):
-        """Go to map."""
-        self.state.set_current_scene("map")
-
 
 class BridgeComputer(Thing):
     """The bridge computer. Gives status updates"""