changeset 435:19aff54b2e73

Many small fixes.
author Jeremy Thurgood <firxen@gmail.com>
date Sat, 28 Aug 2010 23:48:50 +0200
parents 9bcb6148fc6b
children 6e1ad25a7db5
files gamelib/scenes/bridge.py gamelib/scenes/cryo.py gamelib/scenes/engine.py gamelib/scenes/machine.py gamelib/scenes/map.py gamelib/scenes/mess.py gamelib/scenes/scene_widgets.py gamelib/state.py
diffstat 8 files changed, 29 insertions(+), 30 deletions(-) [+]
line wrap: on
line diff
--- a/gamelib/scenes/bridge.py	Sat Aug 28 23:48:21 2010 +0200
+++ b/gamelib/scenes/bridge.py	Sat Aug 28 23:48:50 2010 +0200
@@ -320,7 +320,7 @@
 
     def get_description(self):
         if self.scene.get_data('ai panel') == 'closed':
-            return "The sign reads 'Warning: Authorized Techinicians Only'"
+            return "The sign reads 'Warning: Authorized Techinicians Only'."
 
     def interact_without(self):
         if self.scene.get_data('ai status') == 'online':
@@ -454,7 +454,7 @@
             return Result("You could change the destination, but when JIM recovers, it'll just get reset.")
         if self.state.scenes['bridge'].get_data('ai status') == 'dead':
             self.state.set_current_scene('won')
-            return Result("You change the destination.", soundfile="beep550.png", close_detail=True)
+            return Result("You change the destination.", soundfile="beep550.ogg", close_detail=True)
 
 class CompUpButton(Thing):
     """Up button on log screen"""
@@ -592,7 +592,7 @@
         super(BridgeCompDetail, self).draw_background(surface)
 
     def _clear_navigation(self):
-        "Remove navigation things inf nessecary"
+        "Remove navigation things if necessary"
         for thing in self._nav_lines:
             if thing.name in self.things.keys():
                 # Much fiddling to do the right thing when we reinsert it
--- a/gamelib/scenes/cryo.py	Sat Aug 28 23:48:21 2010 +0200
+++ b/gamelib/scenes/cryo.py	Sat Aug 28 23:48:50 2010 +0200
@@ -55,13 +55,9 @@
             "These pipes carry cooling fluid to the cryo units.",
             (
                 (552, 145, 129, 66),
-                # (643, 199, 38, 233),
                 (636, 82, 165, 60),
                 (140, 135, 112, 73),
-                # (125, 192, 27, 258),
                 (11, 63, 140, 67),
-                #(2, 130, 44, 394),
-                #(756, 127, 52, 393),
                 )))
         self.add_thing(UncuttableCryoPipes())
 
@@ -105,7 +101,7 @@
 
         self.add_thing(GenericCryoUnit(6,
             "An empty cryo unit. Recently filled by you.",
-            "Prisoner %s. Safe cracker. 30 years." % PLAYER_ID,
+            "Prisoner %s. Safecracking, grand larceny. 30 years." % PLAYER_ID,
             (
                 (399, 426, 70, 56),
                 (404, 455, 69, 120),
@@ -113,7 +109,7 @@
 
         self.add_thing(GenericCryoUnit(7,
             "An empty cryo unit.",
-            "Prisoner 83F1-CE32D3234749. Spammer. 5 years",
+            "Prisoner 83F1-CE32D3234749. Spamming. 5 years",
             (
                 (472, 432, 58, 51),
                 (488, 455, 41, 134),
@@ -344,7 +340,6 @@
             return Result("You wedge the titanium femur into the chain and twist. With a satisfying *snap*, the chain breaks and the door opens.", soundfile='break.ogg')
         elif self.get_data('door') == "shut":
             text = "You bang on the door with the titanium femur. It makes a clanging sound."
-            speech.say(self.name, text)
             return Result(text, soundfile='clang.ogg')
         else:
             return Result("You wave the femur in the doorway. Nothing happens.")
@@ -359,11 +354,7 @@
             return None
 
     def interact_default(self, item):
-        return Result(random.choice([
-                    "Sadly, this isn't that sort of game.",
-                    "Your valiant efforts are foiled by the Evil Game Designer.",
-                    "The door resists. Try something else, perhaps?",
-                    ]))
+        return self.interact_without()
 
     def half_open_door(self):
         self.set_data('door', "ajar")
--- a/gamelib/scenes/engine.py	Sat Aug 28 23:48:21 2010 +0200
+++ b/gamelib/scenes/engine.py	Sat Aug 28 23:48:50 2010 +0200
@@ -36,7 +36,7 @@
         self.add_thing(CrackedPipe())
         self.add_thing(ToMap())
         self.add_thing(GenericDescThing('engine.body', 1,
-            "Dead. I think those cans were past their sell-by date.",
+            "Dead. Those cans must have been past their sell-by date.",
             (
                 (594, 387, 45, 109),
                 (549, 479, 60, 55),
@@ -288,7 +288,7 @@
 
     def interact_with_full_detergent_bottle(self, item):
         if not self.scene.things['engine.cracked_pipe'].get_data('fixed'):
-            return Result("You think pouring the precious cryo fluid into a"
+            return Result("Pouring the precious cryo fluid into a"
                     " container connected to a cracked pipe would be a waste.")
         self.state.remove_inventory_item(item.name)
         self.scene.things['engine.cryo_containers'].set_data('filled', True)
--- a/gamelib/scenes/machine.py	Sat Aug 28 23:48:21 2010 +0200
+++ b/gamelib/scenes/machine.py	Sat Aug 28 23:48:50 2010 +0200
@@ -190,7 +190,7 @@
             else:
                 self.state.add_inventory_item("cryo_pipes_one")
             return Result("With high-precision spitzensparken, the can and tube are welded"
-                        " into a whole greater than the parts.",
+                        " into a whole greater than the sum of the parts.",
                         soundfile='laser.ogg')
 
 
--- a/gamelib/scenes/map.py	Sat Aug 28 23:48:21 2010 +0200
+++ b/gamelib/scenes/map.py	Sat Aug 28 23:48:50 2010 +0200
@@ -45,10 +45,10 @@
                 "neural implant to help you navigate around the ship.",
                 self.state)
             if ai1:
-                return ai1, make_jim_dialog("Prisoner %s, you are classed "
-                "as a class 1 felon. Obtaining access to the ship's schematics "
+                return ai1, make_jim_dialog("Prisoner %s, you are a "
+                "class 1 felon. Obtaining access to the ship's schematics "
                 "constitutes a level 2 offence and carries a minimal penalty "
-                "of an additional 3 years on your sentence.'" % PLAYER_ID, self.state)
+                "of an additional 3 years on your sentence." % PLAYER_ID, self.state)
 
 
 class DoorThing(Thing):
--- a/gamelib/scenes/mess.py	Sat Aug 28 23:48:21 2010 +0200
+++ b/gamelib/scenes/mess.py	Sat Aug 28 23:48:50 2010 +0200
@@ -11,6 +11,7 @@
 
 from gamelib.sound import get_sound
 from gamelib import constants
+from gamelib.scenes.game_constants import PLAYER_ID
 
 
 class Mess(Scene):
@@ -198,7 +199,7 @@
             self.scene.set_data('life support status', 'replaced')
             return Result(
                 "The pipes slot neatly into place, but don't make an airtight seal. "
-                "You think one of the pipes has cracked slightly as well."
+                "One of the pipes has cracked slightly as well."
             )
 
     def interact_with_duct_tape(self, item):
@@ -216,6 +217,17 @@
                           " airtight and ready to hold pressure. Who'd've thought duct"
                           " tape could actually be used to tape ducts?")
 
+    def interact_without(self):
+        if self.get_data("status") == "blocked":
+            return Result("The mutant broccoli resists your best efforts.")
+        elif self.get_data("status") == "broken":
+            return Result("Shoving the broken pipes around doesn't help much.")
+        elif self.get_data("status") == "replaced":
+            return Result("Do you really want to hold it together for the "
+                          "rest of the voyage?")
+        else:
+            return Result("You don't find any leaks. Good job, Prisoner %s." % PLAYER_ID)
+
 
 class Boomslang(Thing):
     NAME = 'mess.boomslang'
@@ -273,11 +285,11 @@
 
     def interact_without(self):
         if self.get_data('taken'):
-            return Result("I think one dishwashing liquid bottle is enough for now")
+            return Result("The remaining bottles leak.")
         self.set_data('taken', True)
         self.set_interact('taken')
         self.state.add_inventory_item('detergent_bottle')
-        return Result("You pick up an empty dishwashing liquid bottle. You can't find any sponges")
+        return Result("You pick up an empty dishwashing liquid bottle. You can't find any sponges.")
 
     def get_description(self):
         return "Empty plastic containers. They used to hold dishwasher soap."
--- a/gamelib/scenes/scene_widgets.py	Sat Aug 28 23:48:21 2010 +0200
+++ b/gamelib/scenes/scene_widgets.py	Sat Aug 28 23:48:50 2010 +0200
@@ -171,11 +171,7 @@
         return 'An open doorway leads to the rest of the ship.'
 
     def interact_default(self, item):
-        return Result(random.choice([
-            "Sadly, this isn't that sort of game.",
-            "Your valiant efforts are foiled by the Evil Game Designer.",
-            "Waving that in the doorway does nothing. Try something else, perhaps?",
-            ]))
+        return self.interact_without()
 
 
 def make_jim_dialog(mesg, state):
--- a/gamelib/state.py	Sat Aug 28 23:48:21 2010 +0200
+++ b/gamelib/state.py	Sat Aug 28 23:48:50 2010 +0200
@@ -474,7 +474,7 @@
         return self.interact_default(None)
 
     def interact_default(self, item):
-        return Result("It doesn't work.")
+        return None
 
     def draw(self, surface):
         old_rect = self.current_interact.rect