comparison gamelib/scenes/engine.py @ 519:8f3c82c685a4

Fix is_interactive() by adding tool param.
author Jeremy Thurgood <firxen@gmail.com>
date Tue, 07 Sep 2010 18:13:35 +0200
parents 3e91c82c2240
children 821b322e903b
comparison
equal deleted inserted replaced
518:3e91c82c2240 519:8f3c82c685a4
144 'on': InteractImage(334, 253, 'engine_on.png'), 144 'on': InteractImage(334, 253, 'engine_on.png'),
145 } 145 }
146 146
147 INITIAL = 'on' 147 INITIAL = 'on'
148 148
149 def is_interactive(self): 149 def is_interactive(self, tool=None):
150 return False 150 return False
151 151
152 def get_description(self): 152 def get_description(self):
153 return "All systems are go! Or at least the engines are." 153 return "All systems are go! Or at least the engines are."
154 154
254 def get_description(self): 254 def get_description(self):
255 if not self.get_data('filled'): 255 if not self.get_data('filled'):
256 return "Those are coolant reservoirs. They look empty." 256 return "Those are coolant reservoirs. They look empty."
257 return "The coolant reservoirs are full." 257 return "The coolant reservoirs are full."
258 258
259 def is_interactive(self): 259 def is_interactive(self, tool=None):
260 return False 260 return False
261 261
262 262
263 class CryoContainerReceptacle(Thing): 263 class CryoContainerReceptacle(Thing):
264 NAME = 'engine.cryo_container_receptacle' 264 NAME = 'engine.cryo_container_receptacle'
338 return "These pipes carry coolant to the superconductors. " \ 338 return "These pipes carry coolant to the superconductors. " \
339 "They feel warm." 339 "They feel warm."
340 return "These pipes carry coolant to the superconductors. " \ 340 return "These pipes carry coolant to the superconductors. " \
341 "They are very cold." 341 "They are very cold."
342 342
343 def is_interactive(self): 343 def is_interactive(self, tool=None):
344 return False 344 return False
345 345
346 346
347 class PowerLines(Thing): 347 class PowerLines(Thing):
348 NAME = 'engine.powerlines' 348 NAME = 'engine.powerlines'
364 def get_description(self): 364 def get_description(self):
365 if self.scene.things['engine.superconductor'].get_data('working'): 365 if self.scene.things['engine.superconductor'].get_data('working'):
366 return "Power lines. They are delivering power to the engines." 366 return "Power lines. They are delivering power to the engines."
367 return "Power lines. It looks like they aren't working correctly." 367 return "Power lines. It looks like they aren't working correctly."
368 368
369 def is_interactive(self): 369 def is_interactive(self, tool=None):
370 return False 370 return False
371 371
372 372
373 class ArrowsTopLeft(Thing): 373 class ArrowsTopLeft(Thing):
374 NAME = 'engine.arrows_top_left' 374 NAME = 'engine.arrows_top_left'
381 ) 381 )
382 } 382 }
383 383
384 INITIAL = 'arrows' 384 INITIAL = 'arrows'
385 385
386 def is_interactive(self): 386 def is_interactive(self, tool=None):
387 return False 387 return False
388 388
389 389
390 class ArrowsBottomLeft(Thing): 390 class ArrowsBottomLeft(Thing):
391 NAME = 'engine.arrows_bottom_left' 391 NAME = 'engine.arrows_bottom_left'
398 ) 398 )
399 } 399 }
400 400
401 INITIAL = 'arrows' 401 INITIAL = 'arrows'
402 402
403 def is_interactive(self): 403 def is_interactive(self, tool=None):
404 return False 404 return False
405 405
406 406
407 class ArrowsRight(Thing): 407 class ArrowsRight(Thing):
408 NAME = 'engine.arrows_right' 408 NAME = 'engine.arrows_right'
415 ) 415 )
416 } 416 }
417 417
418 INITIAL = 'arrows' 418 INITIAL = 'arrows'
419 419
420 def is_interactive(self): 420 def is_interactive(self, tool=None):
421 return False 421 return False
422 422
423 423
424 class DangerSign(Thing): 424 class DangerSign(Thing):
425 NAME = 'engine.danger_sign' 425 NAME = 'engine.danger_sign'
431 ) 431 )
432 } 432 }
433 433
434 INITIAL = 'sign' 434 INITIAL = 'sign'
435 435
436 def is_interactive(self): 436 def is_interactive(self, tool=None):
437 return False 437 return False
438 438
439 439
440 class Stars(Thing): 440 class Stars(Thing):
441 NAME = 'engine.stars' 441 NAME = 'engine.stars'
447 ) 447 )
448 } 448 }
449 449
450 INITIAL = 'stars' 450 INITIAL = 'stars'
451 451
452 def is_interactive(self): 452 def is_interactive(self, tool=None):
453 return False 453 return False
454 454
455 def get_description(self): 455 def get_description(self):
456 return "A gaping hole in the floor of the room. You're guessing" \ 456 return "A gaping hole in the floor of the room. You're guessing" \
457 " that's why there's a vacuum in here." 457 " that's why there's a vacuum in here."