[mage.rating.plugin] Bug in Elo rating system (losers gained points instead of loosing them).

This commit is contained in:
magenoxx 2010-12-02 16:37:10 +00:00
parent 592ba955f0
commit a913be4bc1
2 changed files with 3 additions and 3 deletions

View file

@ -94,9 +94,9 @@ public class ResultHandler {
if (loserRating == null)
loserRating = 1000;
Integer newWinnerRating = coundEloRating(winnerRating, loserRating, true);
Integer newLoserRating = coundEloRating(winnerRating, loserRating, false);
log.info("Winner: " + winnerRating + " >> " + newWinnerRating);
log.info("Loser: " + loserRating + " >> " + newLoserRating);
Integer newLoserRating = coundEloRating(loserRating, winnerRating, false);
log.info("Winner(" + winner + "): " + winnerRating + " >> " + newWinnerRating);
log.info("Loser(" + loser + "): " + loserRating + " >> " + newLoserRating);
ratings.put(winner, newWinnerRating);
ratings.put(loser, newLoserRating);
} else {