diff --git a/requirements.txt b/requirements.txt index 1aa046d..0920360 100644 Binary files a/requirements.txt and b/requirements.txt differ diff --git a/the_prestige.py b/the_prestige.py index 99586bb..c49f3f3 100644 --- a/the_prestige.py +++ b/the_prestige.py @@ -1697,7 +1697,11 @@ commands = [ ] watching = False -client = discord.Client() + +intents = discord.Intents.default() +intents.message_content = True + +client = discord.Bot(intents=intents) gamesarray = [] active_tournaments = [] active_leagues = [] @@ -2807,4 +2811,8 @@ async def league_subscriber_update(league, start_channel, message): else: await channel.send(message) +@client.command(description="Sends the bot's latency.") # this decorator makes a slash command +async def ping(ctx): # a slash command will be created with the name "ping" + await ctx.respond(f"Pong! Latency is {client.latency}") + client.run(config()["token"])