src/Repositories/Character/Skills.php
public function getCharacterSkillsAmountPerLevel(int $character_id): array
    {

        $skills = CharacterSkill::where('character_id', $character_id)
            ->get();

        return [
            $skills->where('trained_skill_level', 0)->count(),
            $skills->where('trained_skill_level', 1)->count(),
            $skills->where('trained_skill_level', 2)->count(),
            $skills->where('trained_skill_level', 3)->count(),
            $skills->where('trained_skill_level', 4)->count(),
            $skills->where('trained_skill_level', 5)->count(),
        ];
    }
public function getCharacterSkillsAmountPerLevel(int $character_id): array
    {

        $skills = CharacterSkill::where('character_id', $character_id)
            ->get();

        return [
            $skills->where('trained_skill_level', 0)->count(),
            $skills->where('trained_skill_level', 1)->count(),
            $skills->where('trained_skill_level', 2)->count(),
            $skills->where('trained_skill_level', 3)->count(),
            $skills->where('trained_skill_level', 4)->count(),
            $skills->where('trained_skill_level', 5)->count(),
        ];
    }
public function getCharacterSkillsAmountPerLevel ( int $ character_id ) : array { $ skills = CharacterSkill :: where ( 'character_id' , $ character_id ) -> get ( ) ; return [ $ skills -> where ( 'trained_skill_level' , 0 ) -> count ( ) , $ skills -> where ( 'trained_skill_level' , 1 ) -> count ( ) , $ skills -> where ( 'trained_skill_level' , 2 ) -> count ( ) , $ skills -> where ( 'trained_skill_level' , 3 ) -> count ( ) , $ skills -> where ( 'trained_skill_level' , 4 ) -> count ( ) , $ skills -> where ( 'trained_skill_level' , 5 ) -> count ( ) , ] ; }
Get the numer of skills per Level for a character.

@param int $character_id

@return array
Get the numer of skills per Level for a character .