comparison pytouhou/games/eosd.py @ 465:5f5955635d2c

Move continues to PlayerState, and make sure they aren’t reinitialized before each stage.
author Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
date Wed, 11 Sep 2013 16:03:55 +0200
parents cae1ae9de430
children 98995d8ac744
comparison
equal deleted inserted replaced
464:36bc577b2392 465:5f5955635d2c
80 80
81 81
82 class EoSDGame(Game): 82 class EoSDGame(Game):
83 def __init__(self, resource_loader, player_states, stage, rank, difficulty, 83 def __init__(self, resource_loader, player_states, stage, rank, difficulty,
84 common, nb_bullets_max=640, width=384, height=448, prng=None, 84 common, nb_bullets_max=640, width=384, height=448, prng=None,
85 continues=0, hints=None): 85 hints=None):
86 86
87 self.etama = common.etama #XXX 87 self.etama = common.etama #XXX
88 try: 88 try:
89 self.enm_anm = resource_loader.get_multi_anm(('stg%denm.anm' % stage, 89 self.enm_anm = resource_loader.get_multi_anm(('stg%denm.anm' % stage,
90 'stg%denm2.anm' % stage)) 90 'stg%denm2.anm' % stage))
122 self.resource_loader = resource_loader #XXX: currently used for texture preload in pytouhou.ui.gamerunner. Wipe it! 122 self.resource_loader = resource_loader #XXX: currently used for texture preload in pytouhou.ui.gamerunner. Wipe it!
123 123
124 Game.__init__(self, players, stage, rank, difficulty, 124 Game.__init__(self, players, stage, rank, difficulty,
125 common.bullet_types, common.laser_types, 125 common.bullet_types, common.laser_types,
126 common.item_types, nb_bullets_max, width, height, prng, 126 common.item_types, nb_bullets_max, width, height, prng,
127 common.interface, continues, hints) 127 common.interface, hints)
128 128
129 129
130 130
131 class EoSDInterface(object): 131 class EoSDInterface(object):
132 def __init__(self, resource_loader): 132 def __init__(self, resource_loader):