From 204fdf4eddd7414bef8a4d0d0ed1d5a043b76351 Mon Sep 17 00:00:00 2001 From: Luke Robles Date: Sun, 23 Apr 2023 16:46:14 -0700 Subject: [PATCH] update the message every time the bot connects so that way i can always have it updated in case we add more roles --- app/bot.py | 37 +++++++++++++++++++------------------ 1 file changed, 19 insertions(+), 18 deletions(-) diff --git a/app/bot.py b/app/bot.py index 0c99f952..793f23ae 100755 --- a/app/bot.py +++ b/app/bot.py @@ -33,32 +33,33 @@ async def on_ready(): ) if os.getenv("DRAGON_ENV") == "prod": - # for guild in bot.guilds: - # await bot.register_commands(guild_id=guild.id, force=True) await bot.get_channel(152921472304676865).send("I have reconnected") - # else: - # # force register commands in test server on launch - # await bot.register_commands(guild_id=826547484632678450, force=True) + # Waiting-room in zoid's server + channel_id = 1026281775984549958 + message_id = 1099374735428681758 -# @bot.event -# async def on_ready(): -# # Waiting-room in zoid's server -# # channel = bot.get_channel('1026281775984549958') -# blurb = """Welcome to our server! -# We have lots of roles you can select based on what kind of games you're here to play. + # for testing, bot-testing server's channel + # channel_id = 932476007439552522 + # message_id = 1099841144218722324 -# Please react to this message with one of the following emojis to be granted the appropriate role: + blurb = """Welcome to our server! +We have lots of roles you can select based on what kind of games you're here to play. -# 🔫 for Tarkov +Please react to this message with one of the following emojis to be granted the appropriate role: -# 👹 for Darktide or Vermintide +🔫 for Tarkov -# 🪖 for Battlefield +👹 for Darktide or Vermintide -# 🚀 for Star Citizen -# """ -# message = await bot.get_channel(1026281775984549958).send(blurb) +🪖 for Battlefield + +🚀 for Star Citizen + """ + # message = await bot.get_channel(channel_id).send(blurb) + # Update the message on_ready to match the content we always want to be there + message = await bot.get_channel(channel_id).fetch_message(message_id) + await message.edit(content=blurb) @bot.event