Fix crucial bug in getPlayerScores function (thanks mik1893 for report)