Esempio n. 1
0
    def __init__(self, player):
        animations = {
            'left': Animation(assets.images.player, ('jump_left', )),
            'right': Animation(assets.images.player, ('jump_right', ))
        }
        State.__init__(self, player, animations, .3, .5)

        self.name = None

        self.jumping_time = 0
Esempio n. 2
0
 def __init__(self, player):
     animations = {
         'left':
         Animation(assets.images.player, ('walk_left_1', 'walk_left_2'),
                   200),
         'right':
         Animation(assets.images.player, ('walk_right_1', 'walk_right_2'),
                   200)
     }
     State.__init__(self, player, animations, .3, .5)
Esempio n. 3
0
 def __init__(*args):
     State.__init__(*args)
Esempio n. 4
0
    def enter(self):
        State.enter(self)

        self.jumping_time = 0
Esempio n. 5
0
 def __init__(self, player):
     animations = {
         'left': Animation(assets.images.player, ('stand_left', )),
         'right': Animation(assets.images.player, ('stand_right', ))
     }
     State.__init__(self, player, animations, .3, .5)
Esempio n. 6
0
 def exit(self):
     State.exit(self)
     
     self.entity.rect.size = self.entity.default_size
     self.entity.rect.move_ip(0, -28)
Esempio n. 7
0
 def enter(self):
     State.enter(self)
     
     self.entity.rect.size = (42, 36)
     self.entity.rect.move_ip(0, 28)
Esempio n. 8
0
 def __init__(self, enemy):
     animations = {
         'shell': Animation(assets.images.enemies.turtle, ('shell_front',))
     }
     
     State.__init__(self, enemy, animations)