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
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)
def __init__(*args): State.__init__(*args)
def enter(self): State.enter(self) self.jumping_time = 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)
def exit(self): State.exit(self) self.entity.rect.size = self.entity.default_size self.entity.rect.move_ip(0, -28)
def enter(self): State.enter(self) self.entity.rect.size = (42, 36) self.entity.rect.move_ip(0, 28)
def __init__(self, enemy): animations = { 'shell': Animation(assets.images.enemies.turtle, ('shell_front',)) } State.__init__(self, enemy, animations)