Mercurial > pyntnclick
comparison gamelib/scenes/cryo.py @ 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 | 829551aad0f1 |
children | 6c84eb5ff80a |
comparison
equal
deleted
inserted
replaced
188:aebd4fd5b561 | 189:c18ef647ffe6 |
---|---|
266 "Computer in the cryo room." | 266 "Computer in the cryo room." |
267 | 267 |
268 NAME = "cryo.computer" | 268 NAME = "cryo.computer" |
269 | 269 |
270 INTERACTS = { | 270 INTERACTS = { |
271 "info": InteractAnimated(416, 290, ["comp_info.png", "comp_warn.png"], | 271 "info": InteractAnimated(416, 290, ["comp_info.png", "comp_info2.png"], |
272 10), | 272 10), |
273 "warn": InteractImage(416, 290, "comp_warn.png"), | 273 "warn": InteractImage(416, 290, "comp_warn.png"), |
274 "error": InteractImage(416, 290, "comp_error.png"), | 274 "error": InteractImage(416, 290, "comp_error.png"), |
275 } | 275 } |
276 | 276 |
277 INITIAL = "info" | 277 INITIAL = "info" |
278 | |
279 def interact_without(self): | |
280 return Result(detail_view='cryo_comp_detail') | |
281 | |
282 def interact_with_titanium_leg(self, item): | |
283 return Result("Hitting it with the leg accomplishes nothing.") | |
284 | |
285 def get_description(self): | |
286 return "A computer terminal, with some text on it." | |
278 | 287 |
279 | 288 |
280 class TitaniumLegThing(Thing): | 289 class TitaniumLegThing(Thing): |
281 "Triangle in the cryo room." | 290 "Triangle in the cryo room." |
282 | 291 |
312 return Result("The plaque is welded to the unit. You can't shift it") | 321 return Result("The plaque is welded to the unit. You can't shift it") |
313 | 322 |
314 def get_description(self): | 323 def get_description(self): |
315 return "'Prisoner 98cc-764e646391ee. War crimes. 45 years." | 324 return "'Prisoner 98cc-764e646391ee. War crimes. 45 years." |
316 | 325 |
326 class CryoCompDetail(Scene): | |
327 | |
328 FOLDER = "cryo" | |
329 BACKGROUND = "comp_info_detail.png" | |
330 NAME = "cryo_comp_detail" | |
331 | |
332 SIZE = (640, 400) | |
333 | |
334 def __init__(self, state): | |
335 super(CryoCompDetail, self).__init__(state) | |
336 | |
317 | 337 |
318 class CryoUnitWithCorpse(Scene): | 338 class CryoUnitWithCorpse(Scene): |
319 | 339 |
320 FOLDER = "cryo" | 340 FOLDER = "cryo" |
321 BACKGROUND = "cryo_unit_detail.png" | 341 BACKGROUND = "cryo_unit_detail.png" |
328 self.add_thing(TitaniumLegThing()) | 348 self.add_thing(TitaniumLegThing()) |
329 self.add_thing(PlaqueThing()) | 349 self.add_thing(PlaqueThing()) |
330 | 350 |
331 | 351 |
332 SCENES = [Cryo] | 352 SCENES = [Cryo] |
333 DETAIL_VIEWS = [CryoUnitWithCorpse] | 353 DETAIL_VIEWS = [CryoUnitWithCorpse, CryoCompDetail] |