comparison pytouhou/vm/eclrunner.py @ 358:488c094ed51d

Make bosses clean their mess when timeouting
author Thibaut Girka <thib@sitedethib.com>
date Sun, 08 Jul 2012 01:23:47 +0200
parents b150ed7188a2
children 130d258217f3
comparison
equal deleted inserted replaced
357:26f78fc7acea 358:488c094ed51d
759 life, bonus_dropped, die_score) 759 life, bonus_dropped, die_score)
760 760
761 761
762 @instruction(96) 762 @instruction(96)
763 def kill_enemies(self): 763 def kill_enemies(self):
764 for enemy in self._game.enemies: 764 self.game.kill_enemies()
765 if enemy.boss:
766 pass # Bosses are immune to 96
767 elif enemy.touchable:
768 enemy.life = 0
769 elif enemy.death_callback > 0:
770 #TODO: check
771 enemy.process.switch_to_sub(enemy.death_callback)
772 enemy.death_callback = -1
773 765
774 766
775 @instruction(97) 767 @instruction(97)
776 def set_anim(self, script): 768 def set_anim(self, script):
777 self._enemy.set_anim(script) 769 self._enemy.set_anim(script)