Mercurial > touhou
comparison pytouhou/vm/eclrunner.py @ 178:0bd5e5f19a73
Fix Patchouli’s 日符「ロイヤルフレア」 spellcard.
author | Emmanuel Gil Peyrot <linkmauve@linkmauve.fr> |
---|---|
date | Sun, 23 Oct 2011 05:11:48 -0700 |
parents | 6e8653ff2b23 |
children | 5a1533677a9a |
comparison
equal
deleted
inserted
replaced
177:6e8653ff2b23 | 178:0bd5e5f19a73 |
---|---|
874 self._enemy.bullet_launch_offset = offset | 874 self._enemy.bullet_launch_offset = offset |
875 elif function == 13: | 875 elif function == 13: |
876 if self._enemy.bullet_attributes is None: | 876 if self._enemy.bullet_attributes is None: |
877 return | 877 return |
878 | 878 |
879 if self._enemy.frame % 6: | |
880 return | |
881 | |
879 offset = self._enemy.bullet_launch_offset | 882 offset = self._enemy.bullet_launch_offset |
880 pos = self._enemy.x, self._enemy.y | 883 pos = self._enemy.x, self._enemy.y |
881 attributes = self._enemy.bullet_attributes | 884 attributes = self._enemy.bullet_attributes |
882 | 885 |
883 self._enemy.x, self._enemy.y = (0, 0) | 886 self._enemy.x, self._enemy.y = (192, 224) |
884 self._enemy.bullet_launch_offset = (192, 224) | |
885 type_, anim, sprite_idx_offset, bullets_per_shot, number_of_shots, speed, speed2, launch_angle, angle, flags = attributes | 887 type_, anim, sprite_idx_offset, bullets_per_shot, number_of_shots, speed, speed2, launch_angle, angle, flags = attributes |
886 self._enemy.bullet_attributes = (69, anim, sprite_idx_offset, arg, number_of_shots, speed, speed2, launch_angle, angle, flags) | 888 for i in range(arg): |
887 self._enemy.fire() | 889 _angle = i*2*pi/arg |
890 _angle2 = _angle + self._getval(-10007) | |
891 _distance = self._getval(-10008) | |
892 self._enemy.bullet_launch_offset = (cos(_angle2) * _distance, sin(_angle2) * _distance) | |
893 self._enemy.bullet_attributes = (type_, anim, sprite_idx_offset, bullets_per_shot, number_of_shots, speed, speed2, self._getval(-10006) + _angle, angle, flags) | |
894 self._enemy.fire() | |
888 | 895 |
889 self._enemy.bullet_attributes = attributes | 896 self._enemy.bullet_attributes = attributes |
890 self._enemy.x, self._enemy.y = pos | 897 self._enemy.x, self._enemy.y = pos |
891 self._enemy.bullet_launch_offset = offset | 898 self._enemy.bullet_launch_offset = offset |
892 else: | 899 else: |