Mercurial > touhou
comparison pytouhou/game/laser.pxd @ 617:a6af3ff86612
Change all “void except *” function into “bint except True”, to prevent PyErr_Occurred() from being called at each call.
author | Emmanuel Gil Peyrot <linkmauve@linkmauve.fr> |
---|---|
date | Sun, 29 Mar 2015 00:08:20 +0100 |
parents | 53fa73932e9a |
children |
comparison
equal
deleted
inserted
replaced
616:4ce3ef053a25 | 617:a6af3ff86612 |
---|---|
21 cdef double base_pos[2] | 21 cdef double base_pos[2] |
22 cdef double speed, start_offset, end_offset, max_length, width | 22 cdef double speed, start_offset, end_offset, max_length, width |
23 cdef State state | 23 cdef State state |
24 cdef LaserType _laser_type | 24 cdef LaserType _laser_type |
25 | 25 |
26 cdef void set_anim(self, long sprite_idx_offset=*) except * | 26 cdef bint set_anim(self, long sprite_idx_offset=*) except True |
27 cpdef set_base_pos(self, double x, double y) | 27 cpdef set_base_pos(self, double x, double y) |
28 cdef bint _check_collision(self, double point[2], double border_size) | 28 cdef bint _check_collision(self, double point[2], double border_size) |
29 cdef bint check_collision(self, double point[2]) | 29 cdef bint check_collision(self, double point[2]) |
30 cdef bint check_grazing(self, double point[2]) | 30 cdef bint check_grazing(self, double point[2]) |
31 #def get_bullets_pos(self) | 31 #def get_bullets_pos(self) |
38 cdef double angle, offset | 38 cdef double angle, offset |
39 cdef unsigned long frame, duration, sprite_idx_offset, damage | 39 cdef unsigned long frame, duration, sprite_idx_offset, damage |
40 cdef Element origin | 40 cdef Element origin |
41 cdef LaserType _laser_type | 41 cdef LaserType _laser_type |
42 | 42 |
43 cdef void set_anim(self, long sprite_idx_offset=*) except * | 43 cdef bint set_anim(self, long sprite_idx_offset=*) except True |
44 cdef void cancel(self) except * | 44 cdef bint cancel(self) except True |
45 cdef void update(self) except * | 45 cdef bint update(self) except True |