Mercurial > boomslang
comparison gamelib/scenes/cryo.py @ 433:6b7b08d67233
Hook up fixed ETA screen
author | Neil Muller <neil@dip.sun.ac.za> |
---|---|
date | Sat, 28 Aug 2010 23:45:11 +0200 |
parents | 785bceda2f4f |
children | 19aff54b2e73 |
comparison
equal
deleted
inserted
replaced
432:e64f32e13b90 | 433:6b7b08d67233 |
---|---|
1 """Cryo room where the prisoner starts out.""" | 1 """Cryo room where the prisoner starts out.""" |
2 | 2 |
3 import random | 3 import random |
4 | |
4 from albow.music import change_playlist, get_music, PlayList | 5 from albow.music import change_playlist, get_music, PlayList |
6 from albow.resource import get_image | |
5 | 7 |
6 from gamelib import speech | 8 from gamelib import speech |
7 from gamelib.sound import get_sound | 9 from gamelib.sound import get_sound |
8 from gamelib.cursor import CursorSprite | 10 from gamelib.cursor import CursorSprite |
9 from gamelib.state import Scene, Item, CloneableItem, Thing, Result | 11 from gamelib.state import Scene, Item, CloneableItem, Thing, Result |
480 | 482 |
481 class CryoCompDetail(Scene): | 483 class CryoCompDetail(Scene): |
482 | 484 |
483 FOLDER = "cryo" | 485 FOLDER = "cryo" |
484 BACKGROUND = "comp_info_detail.png" | 486 BACKGROUND = "comp_info_detail.png" |
487 BACKGROUND_FIXED = "comp_info_detail_fixed.png" | |
485 NAME = "cryo_comp_detail" | 488 NAME = "cryo_comp_detail" |
486 | 489 |
487 SIZE = (640, 400) | 490 SIZE = (640, 400) |
488 | 491 |
489 def __init__(self, state): | 492 def __init__(self, state): |
490 super(CryoCompDetail, self).__init__(state) | 493 super(CryoCompDetail, self).__init__(state) |
494 self._background_fixed = get_image(self.FOLDER, self.BACKGROUND_FIXED) | |
495 | |
496 def draw_background(self, surface): | |
497 if self.state.scenes['engine'].get_data('engine online'): | |
498 surface.blit(self._background_fixed, self.OFFSET, None) | |
499 else: | |
500 surface.blit(self._background, self.OFFSET, None) | |
491 | 501 |
492 | 502 |
493 class CryoUnitWithCorpse(Scene): | 503 class CryoUnitWithCorpse(Scene): |
494 | 504 |
495 FOLDER = "cryo" | 505 FOLDER = "cryo" |