diff options
-rw-r--r-- | bigresult.py | 11 | ||||
-rw-r--r-- | main.py | 11 |
2 files changed, 17 insertions, 5 deletions
diff --git a/bigresult.py b/bigresult.py index 6a11d1b..67abf33 100644 --- a/bigresult.py +++ b/bigresult.py @@ -1,16 +1,21 @@ import discord from discord.ext import commands -class BotClient(discord.ext.commands.Bot): +class BotClient(commands.Bot): async def on_ready(self): print("The big result bot is ready!") for guild in self.guilds: break; await self.send_msg("Hurlo") + async def on_message(self, message): + await self.process_commands(message) + if message.author == self.user: + return + if ("1984" in message.content): + await message.channel.send("kys") + async def send_msg(self, msg): channel = self.get_channel(427176475406630914) await channel.send(msg) - - @@ -3,11 +3,18 @@ import os import discord from dotenv import load_dotenv from bigresult import BotClient +from discord.ext import commands load_dotenv() TOKEN = os.getenv('DISCORD_TOKEN') intents = discord.Intents.all() -client = BotClient(intents=intents, command_prefix='!') # This represents our connection with Discord -client.run(TOKEN) # This actually starts our bot
\ No newline at end of file +client = BotClient(intents=intents, command_prefix="!") # This represents our connection with Discord + + +@client.command(name="bigresult") +async def teach(ctx): + await ctx.send("https://cdn.discordapp.com/attachments/427176475406630914/1302392181448900649/image.png?ex=6727f2bd&is=6726a13d&hm=6092f4fba06412feac26a16a6900bf6e6122d66506f60bfcc0bc7101ecede4db&") + +client.run(TOKEN) # This actually starts our bot |