added some jokes

This commit is contained in:
jsl12
2022-02-02 13:28:42 -06:00
parent ec78038d28
commit fcbaef50ef
2 changed files with 36 additions and 5 deletions

View File

@@ -1,5 +1,6 @@
import logging
import re
from random import choice
from nextcord import Client, Message
from nextcord import utils
@@ -126,3 +127,33 @@ class ChiliJoke(base.GifJoke):
@property
def regex(self) -> re.Pattern:
return re.compile('chil(i|ly)', re.IGNORECASE)
class Jaccuse(base.Joke):
urls = [
'https://tenor.com/view/jaccuse-the-good-fight-i-accuse-im-accusing-you-paramount-plus-gif-21890096',
'https://tenor.com/view/glee-jaccuse-i-accuse-blame-shouting-gif-17122248',
'https://tenor.com/view/jaccuse-gif-5729034',
'https://tenor.com/view/jaccuse-frankie-lily-tomlin-grace-and-frankie-accuse-gif-17551378',
'https://tenor.com/view/michael-gove-gove-jaccuse-accuse-conservatives-gif-17652472'
]
@property
def regex(self) -> re.Pattern:
return re.compile('j\'?accuse', re.IGNORECASE)
async def respond(self, message: Message, client: Client, match: re.Match):
if message.reference is not None:
initial = await message.channel.fetch_message(message.reference.message_id)
await initial.reply(choice(self.urls))
else:
await message.reply(choice(self.urls))
class GoodBot(base.Joke):
@property
def regex(self) -> re.Pattern:
return re.compile('(\w+) bot', re.IGNORECASE)
async def respond(self, message: Message, client: Client, match: re.Match):
await message.add_reaction(utils.get(client.emojis, name='kaylon'))