Exemple #1
0
    def build_die_animation(self):
        base_name = self._character.name + 'Die'

        die_animation = SpriteSheet(base_sprite_path=os.path.join(
            self._character.get_sprite_path(), base_name),
                                    frames=6)

        die_animation.base_file_name = base_name
        die_animation.key_name = self._character.name.lower() + '_die'

        die_animation.load_images()

        self._character.add_sprite_sheet(FightingAnimation.DIE.value,
                                         die_animation)
        pass
Exemple #2
0
    def build_static_animation(self):
        base_name = self._character.name + 'Static'

        static_animation = SpriteSheet(base_sprite_path=os.path.join(
            self._character.get_sprite_path(), base_name),
                                       frames=8)

        static_animation.base_file_name = base_name
        static_animation.key_name = self._character.name.lower() + '_static'

        static_animation.load_images()

        self._character.add_sprite_sheet(MovingAnimation.STATIC.value,
                                         static_animation)
        pass
Exemple #3
0
    def build_fist_animation(self):
        base_name = self._character.name + 'Fist'

        fist_animation = SpriteSheet(base_sprite_path=os.path.join(
            self._character.get_sprite_path(), base_name),
                                     frames=8)

        fist_animation.base_file_name = base_name
        fist_animation.key_name = self._character.name.lower() + '_fist'

        fist_animation.load_images()

        self._character.add_sprite_sheet(FightingAnimation.FIST.value,
                                         fist_animation)
        pass
Exemple #4
0
    def build_jump_animation(self):
        base_name = self._character.name + 'Jump'

        jump_animation = SpriteSheet(base_sprite_path=os.path.join(
            self._character.get_sprite_path(), base_name),
                                     frames=8)

        jump_animation.base_file_name = base_name
        jump_animation.key_name = self._character.name.lower() + '_jump'

        jump_animation.load_images()

        self._character.add_sprite_sheet(MovingAnimation.JUMP.value,
                                         jump_animation)
        pass
Exemple #5
0
    def build_walk_animation(self):
        base_name = self._character.name + 'Walk'

        walk_animation = SpriteSheet(base_sprite_path=os.path.join(
            self._character.get_sprite_path(), base_name),
                                     frames=8)

        walk_animation.base_file_name = base_name
        walk_animation.key_name = self._character.name.lower() + '_walk'

        walk_animation.load_images()

        self._character.add_sprite_sheet(MovingAnimation.WALK.value,
                                         walk_animation)
        pass
Exemple #6
0
    def build_pro_defense_animation(self):
        base_name = self._character.name + 'ProDefense'

        pro_defense_animation = SpriteSheet(base_sprite_path=os.path.join(
            self._character.get_sprite_path(), base_name),
                                            frames=8)

        pro_defense_animation.base_file_name = base_name
        pro_defense_animation.key_name = self._character.name.lower(
        ) + '_pro_defense'

        pro_defense_animation.load_images()

        self._character.add_sprite_sheet(
            ProFightingAnimation.PRO_DEFENSE.value, pro_defense_animation)
        pass
Exemple #7
0
    def build_large_attack_animation(self):
        base_name = self._character.name + 'LargeAttack'

        large_attack_animation = SpriteSheet(base_sprite_path=os.path.join(
            self._character.get_sprite_path(), base_name),
                                             frames=8)

        large_attack_animation.base_file_name = base_name
        large_attack_animation.key_name = self._character.name.lower(
        ) + '_largeAttack'

        large_attack_animation.load_images()

        self._character.add_sprite_sheet(FightingAnimation.LARGE_ATTACK.value,
                                         large_attack_animation)
        pass