comparison pytouhou/game/enemy.py @ 234:3cbfa2c11dec

Fix instructions 69 and 71.
author Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
date Sat, 31 Dec 2011 03:08:01 +0100
parents 0595315d3880
children 1d3c8c7473a2
comparison
equal deleted inserted replaced
233:067f6d9c562b 234:3cbfa2c11dec
123 123
124 if type_ in (67, 69, 71): 124 if type_ in (67, 69, 71):
125 launch_angle += self.get_player_angle(player, launch_pos) 125 launch_angle += self.get_player_angle(player, launch_pos)
126 if type_ in (69, 70, 71, 74): 126 if type_ in (69, 70, 71, 74):
127 angle = 2. * pi / bullets_per_shot 127 angle = 2. * pi / bullets_per_shot
128 if type_ == 71: 128 if type_ == 71 and bullets_per_shot % 2 or type_ == 69 and not bullets_per_shot % 2:
129 launch_angle += pi / bullets_per_shot 129 launch_angle += pi / bullets_per_shot
130 if type_ != 75: 130 if type_ != 75:
131 launch_angle -= angle * (bullets_per_shot - 1) / 2. 131 launch_angle -= angle * (bullets_per_shot - 1) / 2.
132 132
133 bullets = self._game.bullets 133 bullets = self._game.bullets