comparison pytouhou/game/games.py @ 130:11ab06f4c4c6

Introduce characters!
author Thibaut Girka <thib@sitedethib.com>
date Sat, 10 Sep 2011 22:48:56 +0200
parents 174324a4da51
children 429de58498f9
comparison
equal deleted inserted replaced
129:284ac8f97a96 130:11ab06f4c4c6
11 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 11 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 ## GNU General Public License for more details. 12 ## GNU General Public License for more details.
13 ## 13 ##
14 14
15 from pytouhou.game.game import Game 15 from pytouhou.game.game import Game
16 from pytouhou.game.character import Character
16 from pytouhou.game.bullettype import BulletType 17 from pytouhou.game.bullettype import BulletType
17 18
18 class EoSDGame(Game): 19 class EoSDGame(Game):
19 def __init__(self, resource_loader, players, stage, rank, difficulty): 20 def __init__(self, resource_loader, players, stage, rank, difficulty):
20 etama3 = resource_loader.get_anm_wrapper(('etama3.anm',)) 21 etama3 = resource_loader.get_anm_wrapper(('etama3.anm',))
28 BulletType(etama3, 6, 13, 20, 20, 20), 29 BulletType(etama3, 6, 13, 20, 20, 20),
29 BulletType(etama3, 7, 13, 20, 20, 20), 30 BulletType(etama3, 7, 13, 20, 20, 20),
30 BulletType(etama3, 8, 13, 20, 20, 20), 31 BulletType(etama3, 8, 13, 20, 20, 20),
31 BulletType(etama4, 0, 1, 2, 2, 2)] 32 BulletType(etama4, 0, 1, 2, 2, 2)]
32 33
33 Game.__init__(self, resource_loader, players, stage, rank, difficulty, bullet_types) 34 player00 = resource_loader.get_anm_wrapper(('player00.anm',))
35 player01 = resource_loader.get_anm_wrapper(('player01.anm',))
36 characters = [Character(player00, 4., 2., 4.),
37 Character(player00, 4., 2., 4.),
38 Character(player01, 5., 2.5, 5.),
39 Character(player01, 5., 2.5, 5.)]
40
41 Game.__init__(self, resource_loader, players, stage, rank, difficulty,
42 bullet_types, characters)
43