Mercurial > touhou
diff pytouhou/game/player.pyx @ 457:4ccc47828002
Display the name of a spellcard and the face of its invoker.
author | Emmanuel Gil Peyrot <linkmauve@linkmauve.fr> |
---|---|
date | Sat, 10 Aug 2013 13:36:42 +0200 |
parents | 78e1c3864e73 |
children | 5f5955635d2c |
line wrap: on
line diff
--- a/pytouhou/game/player.pyx +++ b/pytouhou/game/player.pyx @@ -230,6 +230,14 @@ cdef class Player(Element): self.fire() self.fire_time -= 1 + if keystate & 2 and self.bomb_time == 0: + self._game.set_player_bomb() + self.bomb_time = 240 + if self.bomb_time > 0: + self.bomb_time -= 1 + if self.bomb_time == 0: + self._game.unset_player_bomb() + if self.death_time: time = self._game.frame - self.death_time if time == 6: # too late, you are dead :(