Mercurial > pyntnclick
changeset 189:c18ef647ffe6
Add detail view for cryo screen. Tweak animation
author | Neil Muller <neil@dip.sun.ac.za> |
---|---|
date | Wed, 25 Aug 2010 18:04:00 +0200 |
parents | aebd4fd5b561 |
children | 30f2308c1efc |
files | Resources/images/cryo/comp_info2.png Resources/images/cryo/comp_info_detail.png gamelib/scenes/cryo.py |
diffstat | 3 files changed, 22 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/gamelib/scenes/cryo.py Wed Aug 25 17:04:06 2010 +0200 +++ b/gamelib/scenes/cryo.py Wed Aug 25 18:04:00 2010 +0200 @@ -268,7 +268,7 @@ NAME = "cryo.computer" INTERACTS = { - "info": InteractAnimated(416, 290, ["comp_info.png", "comp_warn.png"], + "info": InteractAnimated(416, 290, ["comp_info.png", "comp_info2.png"], 10), "warn": InteractImage(416, 290, "comp_warn.png"), "error": InteractImage(416, 290, "comp_error.png"), @@ -276,6 +276,15 @@ INITIAL = "info" + def interact_without(self): + return Result(detail_view='cryo_comp_detail') + + def interact_with_titanium_leg(self, item): + return Result("Hitting it with the leg accomplishes nothing.") + + def get_description(self): + return "A computer terminal, with some text on it." + class TitaniumLegThing(Thing): "Triangle in the cryo room." @@ -314,6 +323,17 @@ def get_description(self): return "'Prisoner 98cc-764e646391ee. War crimes. 45 years." +class CryoCompDetail(Scene): + + FOLDER = "cryo" + BACKGROUND = "comp_info_detail.png" + NAME = "cryo_comp_detail" + + SIZE = (640, 400) + + def __init__(self, state): + super(CryoCompDetail, self).__init__(state) + class CryoUnitWithCorpse(Scene): @@ -330,4 +350,4 @@ SCENES = [Cryo] -DETAIL_VIEWS = [CryoUnitWithCorpse] +DETAIL_VIEWS = [CryoUnitWithCorpse, CryoCompDetail]