diff gamelib/scenes/cryo.py @ 63:3087be3463e0

Some framework support for better message handling
author Neil Muller <neil@dip.sun.ac.za>
date Mon, 23 Aug 2010 18:32:15 +0200
parents 75bf3d3689e9
children 6b0f7364f3bf
line wrap: on
line diff
--- a/gamelib/scenes/cryo.py	Mon Aug 23 18:13:57 2010 +0200
+++ b/gamelib/scenes/cryo.py	Mon Aug 23 18:32:15 2010 +0200
@@ -18,8 +18,8 @@
         super(Cryo, self).__init__(state)
         self.add_item(Triangle("triangle"))
         self.add_item(TitaniumLeg("titanium_leg"))
-        self.add_thing(CryoUnitAlpha("cryo.unit.1", (20, 20, 400, 500)))
-        self.add_thing(CryoRoomDoor("cryo.door", (30, 30, 400, 300)))
+        self.add_thing(CryoUnitAlpha("cryo.unit.1", (20, 20, 200, 200)))
+        self.add_thing(CryoRoomDoor("cryo.door", (200, 200, 400, 300)))
 
 
 class Triangle(Item):
@@ -69,5 +69,10 @@
         self.set_data('open', True)
         self.state.scenes['bridge'].set_data('accessible', True)
 
+    def get_description(self):
+        if self.get_data('open'):
+            return 'An open doorway leads to the rest of the ship'
+        return 'A rusty door. It is currently closed'
+
 
 SCENES = [Cryo]