Mercurial > touhou
annotate pytouhou/game/game.pxd @ 469:58b47e788c59
Move SDL context-manager and Window creation outside of main.
author | Emmanuel Gil Peyrot <linkmauve@linkmauve.fr> |
---|---|
date | Sat, 14 Sep 2013 01:05:42 +0200 |
parents | feecdb4a8928 |
children | 06f0eeb519bb |
rev | line source |
---|---|
447
78e1c3864e73
Make pytouhou.game.game an extension type.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff
changeset
|
1 from pytouhou.game.effect cimport Effect |
78e1c3864e73
Make pytouhou.game.game an extension type.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff
changeset
|
2 from pytouhou.game.player cimport Player |
78e1c3864e73
Make pytouhou.game.game an extension type.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff
changeset
|
3 |
78e1c3864e73
Make pytouhou.game.game an extension type.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff
changeset
|
4 cdef class Game: |
78e1c3864e73
Make pytouhou.game.game an extension type.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff
changeset
|
5 cdef public long width, height, nb_bullets_max, stage, rank, difficulty, difficulty_counter, difficulty_min, difficulty_max, frame, last_keystate |
78e1c3864e73
Make pytouhou.game.game an extension type.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff
changeset
|
6 cdef public list bullet_types, laser_types, item_types, players, enemies, effects, bullets, lasers, cancelled_bullets, players_bullets, players_lasers, items, labels, faces, texts, hints, bonus_list |
78e1c3864e73
Make pytouhou.game.game an extension type.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff
changeset
|
7 cdef public object interface, boss, msg_runner, prng, sfx_player |
78e1c3864e73
Make pytouhou.game.game an extension type.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff
changeset
|
8 cdef public double continues |
78e1c3864e73
Make pytouhou.game.game an extension type.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff
changeset
|
9 cdef public Effect spellcard_effect |
78e1c3864e73
Make pytouhou.game.game an extension type.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff
changeset
|
10 cdef public tuple spellcard |
78e1c3864e73
Make pytouhou.game.game an extension type.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff
changeset
|
11 cdef public bint time_stop, msg_wait |
78e1c3864e73
Make pytouhou.game.game an extension type.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff
changeset
|
12 cdef public unsigned short deaths_count, next_bonus |
78e1c3864e73
Make pytouhou.game.game an extension type.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff
changeset
|
13 |
468
feecdb4a8928
Add “except *” to cdef void functions, and type some more.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
466
diff
changeset
|
14 cdef list msg_sprites(self) |
feecdb4a8928
Add “except *” to cdef void functions, and type some more.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
466
diff
changeset
|
15 cdef list lasers_sprites(self) |
feecdb4a8928
Add “except *” to cdef void functions, and type some more.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
466
diff
changeset
|
16 cdef void modify_difficulty(self, long diff) except * |
feecdb4a8928
Add “except *” to cdef void functions, and type some more.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
466
diff
changeset
|
17 cpdef enable_spellcard_effect(self) |
feecdb4a8928
Add “except *” to cdef void functions, and type some more.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
466
diff
changeset
|
18 cpdef disable_spellcard_effect(self) |
feecdb4a8928
Add “except *” to cdef void functions, and type some more.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
466
diff
changeset
|
19 cdef void set_player_bomb(self) except * |
feecdb4a8928
Add “except *” to cdef void functions, and type some more.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
466
diff
changeset
|
20 cdef void unset_player_bomb(self) except * |
447
78e1c3864e73
Make pytouhou.game.game an extension type.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff
changeset
|
21 cpdef drop_bonus(self, double x, double y, long _type, end_pos=*) |
468
feecdb4a8928
Add “except *” to cdef void functions, and type some more.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
466
diff
changeset
|
22 cdef void autocollect(self, Player player) except * |
feecdb4a8928
Add “except *” to cdef void functions, and type some more.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
466
diff
changeset
|
23 cdef void cancel_bullets(self) except * |
feecdb4a8928
Add “except *” to cdef void functions, and type some more.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
466
diff
changeset
|
24 cpdef change_bullets_into_star_items(self) |
feecdb4a8928
Add “except *” to cdef void functions, and type some more.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
466
diff
changeset
|
25 cpdef change_bullets_into_bonus(self) |
feecdb4a8928
Add “except *” to cdef void functions, and type some more.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
466
diff
changeset
|
26 cpdef kill_enemies(self) |
feecdb4a8928
Add “except *” to cdef void functions, and type some more.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
466
diff
changeset
|
27 cpdef new_effect(self, pos, long anim, anm=*, long number=*) |
447
78e1c3864e73
Make pytouhou.game.game an extension type.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff
changeset
|
28 cpdef new_particle(self, pos, long anim, long amp, long number=*, bint reverse=*, long duration=*) |
468
feecdb4a8928
Add “except *” to cdef void functions, and type some more.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
466
diff
changeset
|
29 cpdef new_enemy(self, pos, life, instr_type, bonus_dropped, die_score) |
feecdb4a8928
Add “except *” to cdef void functions, and type some more.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
466
diff
changeset
|
30 cpdef new_msg(self, sub) |
feecdb4a8928
Add “except *” to cdef void functions, and type some more.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
466
diff
changeset
|
31 cdef new_label(self, pos, str text) |
feecdb4a8928
Add “except *” to cdef void functions, and type some more.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
466
diff
changeset
|
32 cpdef new_native_text(self, pos, text, align=*) |
feecdb4a8928
Add “except *” to cdef void functions, and type some more.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
466
diff
changeset
|
33 cpdef new_hint(self, hint) |
feecdb4a8928
Add “except *” to cdef void functions, and type some more.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
466
diff
changeset
|
34 cpdef new_face(self, side, effect) |
feecdb4a8928
Add “except *” to cdef void functions, and type some more.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
466
diff
changeset
|
35 cpdef run_iter(self, long keystate) |
feecdb4a8928
Add “except *” to cdef void functions, and type some more.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
466
diff
changeset
|
36 cdef void update_background(self) except * |
feecdb4a8928
Add “except *” to cdef void functions, and type some more.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
466
diff
changeset
|
37 cdef void update_enemies(self) except * |
447
78e1c3864e73
Make pytouhou.game.game an extension type.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff
changeset
|
38 cdef void update_msg(self, long keystate) except * |
78e1c3864e73
Make pytouhou.game.game an extension type.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff
changeset
|
39 cdef void update_players(self, long keystate) except * |
468
feecdb4a8928
Add “except *” to cdef void functions, and type some more.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
466
diff
changeset
|
40 cdef void update_effects(self) except * |
feecdb4a8928
Add “except *” to cdef void functions, and type some more.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
466
diff
changeset
|
41 cdef void update_hints(self) except * |
feecdb4a8928
Add “except *” to cdef void functions, and type some more.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
466
diff
changeset
|
42 cdef void update_faces(self) except * |
feecdb4a8928
Add “except *” to cdef void functions, and type some more.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
466
diff
changeset
|
43 cdef void update_bullets(self) except * |
466
b16d34fca5b4
Revert a change in 78e1c3864e73, causing boss rush to not destroy any standard enemy.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
447
diff
changeset
|
44 cpdef cleanup(self) |