Rifat Azad commited on
Commit
ca908a9
·
1 Parent(s): 3bfbd5d

update 1.1.1

Browse files
Files changed (1) hide show
  1. pydvpl_bot.py +30 -2
pydvpl_bot.py CHANGED
@@ -21,7 +21,7 @@ load_dotenv()
21
  # DEFINES ------------------------------------------------------ START
22
 
23
 
24
- BOT_VERSION = '1.1.0'
25
 
26
  AUTHORIZED_USER_ID = os.getenv('AUTHORIZED_ID')
27
 
@@ -154,6 +154,34 @@ async def on_disconnect():
154
 
155
 
156
  # FUNCTION ------------------------------------------------------ SPLIT
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
157
 
158
 
159
  @bot.event
@@ -272,7 +300,7 @@ async def help(ctx):
272
  embed.add_field(name="Dvpl Commands:", value="`compress` - Compresses files.\n`decompress` - Decompresses files.", inline=False)
273
  embed.add_field(name="User Utility Commands:", value="`ping` - Checks the bot's latency.\n`invite` - Get the bot's invite link.\n`uptime` - Displays the bot's uptime.", inline=False)
274
  embed.add_field(name="Admin Utility Commands:", value="`stats` - Displays bot statistics.\n`list` - Lists server members.\n`say` - Make the bot say something.\n`announce` - Announces a message to a channel.\n`activity` - Sets bot activity status.\n`online` - Sets bot status to online.\n`dnd` - Sets bot status to Do Not Disturb.\n`offline` - Sets bot status to offline.\n`clean` - Cleans up bot's messages.", inline=False)
275
- embed.add_field(name="Feedback Commands:", value="`feedback` - Sends feedback to bot developers.(usage: >>feedback issues/requests <message>)", inline=False)
276
 
277
  # Customize based on your commands
278
 
 
21
  # DEFINES ------------------------------------------------------ START
22
 
23
 
24
+ BOT_VERSION = '1.1.1'
25
 
26
  AUTHORIZED_USER_ID = os.getenv('AUTHORIZED_ID')
27
 
 
154
 
155
 
156
  # FUNCTION ------------------------------------------------------ SPLIT
157
+
158
+
159
+ @bot.event
160
+ async def on_guild_join(guild):
161
+ embed = discord.Embed(
162
+ title="Thank You for Adding PyDVPL Bot! 💛",
163
+ description="We're excited to be a part of your server. If you have any questions or need assistance, feel free to reach out to us!",
164
+ color=discord.Color.yellow()
165
+ )
166
+
167
+ embed.add_field(name="Feedback Commands:", value="`feedback` - Sends feedback to bot developers. (usage: >>feedback issues/requests <message>)", inline=False)
168
+
169
+ embed.add_field(name="Help Commands:", value="Do `/help` or `>>help` to begin with PyDVPL!", inline=False)
170
+
171
+ # embed.set_footer(value="Do `/help` or `>>help` to begin with PyDVPL!")
172
+
173
+ # Check for a suitable channel to send the message
174
+ public_updates_channel = guild.public_updates_channel
175
+ default_channel = guild.system_channel or guild.text_channels[0] # Default to the first text channel
176
+
177
+ if public_updates_channel:
178
+ await public_updates_channel.send(embed=embed)
179
+ else:
180
+ if default_channel:
181
+ await default_channel.send(embed=embed)
182
+
183
+
184
+ # FUNCTION ------------------------------------------------------ SPLIT
185
 
186
 
187
  @bot.event
 
300
  embed.add_field(name="Dvpl Commands:", value="`compress` - Compresses files.\n`decompress` - Decompresses files.", inline=False)
301
  embed.add_field(name="User Utility Commands:", value="`ping` - Checks the bot's latency.\n`invite` - Get the bot's invite link.\n`uptime` - Displays the bot's uptime.", inline=False)
302
  embed.add_field(name="Admin Utility Commands:", value="`stats` - Displays bot statistics.\n`list` - Lists server members.\n`say` - Make the bot say something.\n`announce` - Announces a message to a channel.\n`activity` - Sets bot activity status.\n`online` - Sets bot status to online.\n`dnd` - Sets bot status to Do Not Disturb.\n`offline` - Sets bot status to offline.\n`clean` - Cleans up bot's messages.", inline=False)
303
+ embed.add_field(name="Feedback Commands:", value="`feedback` - Sends feedback to bot developers. (usage: >>feedback issues/requests <message>)", inline=False)
304
 
305
  # Customize based on your commands
306