fi
xmlstarlet_meta_cmd="$xmlstarlet_meta_cmd -v \"//SongScores//Song[starts-with(@Dir, \\\"Songs/${persons_folder}\\\")][Steps//PercentDP]//@*\" -n"
- xmlstarlet_scores_cmd="$xmlstarlet_scores_cmd -o \"SCORES\" -n -v \"//SongScores//Song[starts-with(@Dir, \\\"Songs/${persons_folder}\\\")]//PercentDP\" -n -o \"NAMES\" -n -v \"//SongScores/Song[starts-with(@Dir, \\\"Songs/${persons_folder}\\\")]//Name\" -n"
+ xmlstarlet_scores_cmd="$xmlstarlet_scores_cmd -o \"SCORES\" -n -v \"//SongScores//Song[starts-with(@Dir, \\\"Songs/${persons_folder}\\\")]//HighScore[1]//PercentDP\" -n -o \"NAMES\" -n -v \"//SongScores/Song[starts-with(@Dir, \\\"Songs/${persons_folder}\\\")]//HighScore[1]//Name\" -n"
done < <(find "${DIR}"/*.favourites.txt -type f -print0)
meta=$(eval "xmlstarlet sel -I -t $xmlstarlet_meta_cmd -o \"Songs\" \"${path_to_stats}\"")
the_scorer=$(echo ${mmeta[$fuck]} | cut -sd : -f2)
just_hash=$(echo $fuck | cut -sd : -f1)
- if [ "$the_scorer" = "$me_highscore_name" ]; then
+ if [ "$the_scorer" = "$me_highscore_name" ] || [ "$the_scorer" = "EVNT" ]; then
writeout="$writeout\n${fuck}:${the_score}"
else
writeout="$writeout\n${just_hash}:NODATA"