building: fix trophy manager sorting

This commit is contained in:
Hawkheart 2014-05-18 12:29:59 -06:00
parent c4bd53464c
commit b0506c03a2

View file

@ -49,7 +49,7 @@ class DistributedTrophyMgrAI(DistributedObjectAI):
scoreList = []
for avId, data in self.scores.items():
scoreList.append((avId, data[0], data[1]))
sorted(scoreList, key=itemgetter(2), reverse=True)
scoreList.sort(key=itemgetter(2), reverse=True)
avIds = []
names = []
scores = []
@ -62,4 +62,4 @@ class DistributedTrophyMgrAI(DistributedObjectAI):
self.scoreLists = (avIds, names, scores)
def getLeaderInfo(self):
return self.scoreLists
return self.scoreLists