diff options
| author | 2019-04-26 18:06:02 -0400 | |
|---|---|---|
| committer | 2019-04-26 18:06:02 -0400 | |
| commit | 120fa538166eb6fbaa40579633c0d5694cb8199e (patch) | |
| tree | de76fac83e884cc7af14c9f83c50bc02e15bb8bc | |
| parent | added answer parsing and pining winner (diff) | |
finalized riddles and fixed various easter_riddle bugs
| -rw-r--r-- | bot/resources/easter/easter_riddle.json | 12 | ||||
| -rw-r--r-- | bot/seasons/easter/easter_riddle.py | 7 |
2 files changed, 10 insertions, 9 deletions
diff --git a/bot/resources/easter/easter_riddle.json b/bot/resources/easter/easter_riddle.json index f32b5258..e93f6dad 100644 --- a/bot/resources/easter/easter_riddle.json +++ b/bot/resources/easter/easter_riddle.json @@ -2,15 +2,15 @@ { "question": "What kind of music do bunnies like?", "riddles": [ - "two words", - "jump to the beat" + "Two words", + "Jump to the beat" ], "correct_answer": "Hip hop" }, { "question": "What kind of jewelry do rabbits wear?", "riddles": [ - "they can eat it too", + "They can eat it too", "14 ___ gold" ], "correct_answer": "14 carrot gold" @@ -59,7 +59,7 @@ "question": "What kind of bunny can't hop?", "riddles": [ "Might melt in the sun", - "Fragile and Yummy" + "Fragile and yummy" ], "correct_answer": "A chocolate one" }, @@ -74,8 +74,8 @@ { "question": "Why did the Easter Bunny have to fire the duck?", "riddles": [ - "quack", - "MY EGGS!!!" + "Quack", + "MY EGGS!!" ], "correct_answer": "He kept quacking the eggs" } diff --git a/bot/seasons/easter/easter_riddle.py b/bot/seasons/easter/easter_riddle.py index 18b4c31d..6b2ab5ca 100644 --- a/bot/seasons/easter/easter_riddle.py +++ b/bot/seasons/easter/easter_riddle.py @@ -60,7 +60,7 @@ class EasterRiddle(commands.Cog): await asyncio.sleep(TIMELIMIT) if self.winner != " ": - content = "Well done " + self.winner + " for getting it correct!" + content = "Well done " + self.winner + "for getting it correct!" else: content = "Nobody got it right..." @@ -75,8 +75,9 @@ class EasterRiddle(commands.Cog): @commands.Cog.listener() async def on_message(self, message): - if message.content.lower() == self.correct.lower(): - self.winner = message.author.mention + if self.bot.user != message.author: + if message.content.lower() == self.correct.lower(): + self.winner = self.winner + message.author.mention + " " |