From 3a285da67dde4359fa77a3c2cd7ef13d6bc5b0c1 Mon Sep 17 00:00:00 2001 From: Matthias Meusburger Date: Mon, 17 Sep 2012 17:20:33 +0200 Subject: [PATCH] Fix wrong week displayed in weekscores --- plugin.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/plugin.py b/plugin.py index 9616c9c..4cb666b 100644 --- a/plugin.py +++ b/plugin.py @@ -634,7 +634,7 @@ class DuckHunt(callbacks.Plugin): if msgstring != "": - irc.reply("Scores for week " + str(self.woy) + ": " + msgstring) + irc.reply("Scores for week " + str(week) + ": " + msgstring) # Who's the winner at this point? winnernick, winnerscore = max(weekscores.iteritems(), key=lambda (k,v):(v,k)) irc.reply("Leader: x%sx with %i points." % (winnernick, winnerscore)) @@ -1039,7 +1039,7 @@ class DuckHunt(callbacks.Plugin): weekscores[player] = self.channelweek[currentChannel][self.woy][i][player] winnernick, winnerscore = max(weekscores.iteritems(), key=lambda (k,v):(v,k)) if (winnernick != self.leader[currentChannel]): - irc.reply("x%sx has the lead for the week with %i points." % (winnernick, winnerscore)) + irc.reply("%s has the lead for the week with %i points." % (winnernick, winnerscore)) self.leader[currentChannel] = winnernick