Mercurial > pyntnclick
comparison gamelib/scenes/scene_widgets.py @ 500:e49e4fe76241
Alter security camera description and is_interactive to match JIM's state
author | Stefano Rivera <stefano@rivera.za.net> |
---|---|
date | Tue, 31 Aug 2010 14:33:00 +0200 |
parents | cfd9c2bb4474 |
children | 8f3c82c685a4 |
comparison
equal
deleted
inserted
replaced
499:cfd9c2bb4474 | 500:e49e4fe76241 |
---|---|
189 INITIAL_DATA = { | 189 INITIAL_DATA = { |
190 'state': 'online', | 190 'state': 'online', |
191 } | 191 } |
192 | 192 |
193 def get_description(self): | 193 def get_description(self): |
194 return "A security camera watches over the room" | 194 status = self.state.scenes['bridge'].get_data('ai status') |
195 if status == 'online': | |
196 return "A security camera watches over the room" | |
197 elif status == 'looping': | |
198 return "The security camera is currently offline but should be working soon" | |
199 else: | |
200 return "The security camera is powered down" | |
201 | |
202 def is_interactive(self): | |
203 return self.state.scenes['bridge'].get_data('ai status') == 'online' | |
195 | 204 |
196 def interact_with_escher_poster(self, item): | 205 def interact_with_escher_poster(self, item): |
197 # Order matters here, because of helper function | 206 # Order matters here, because of helper function |
198 if self.state.scenes['bridge'].get_data('ai status') == 'online': | 207 if self.state.scenes['bridge'].get_data('ai status') == 'online': |
199 ai_response = make_jim_dialog("3D scene reconstruction failed. Critical error. Entering emergency shutdown.", self.state) | 208 ai_response = make_jim_dialog("3D scene reconstruction failed. Critical error. Entering emergency shutdown.", self.state) |