Skip to content

Commit

Permalink
added ping replies
Browse files Browse the repository at this point in the history
  • Loading branch information
elouangrimm authored Oct 28, 2024
1 parent b7a4c19 commit 653dc9a
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions bot.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,13 @@
tips_file = "tips.txt"
tip_time = 9
user_points = {}
ping_responses = [
"Hello there! 👋",
"How can I help you today? 😊",
"What's up? 😄",
"Here to assist you! 🤖",
"Need anything? I'm just a ping away! 😎"
]

# ☲☲☲☲ BOT SETUP ☲☲☲☲

Expand Down Expand Up @@ -64,6 +71,16 @@ async def send_daily_tip():

# ☲☲☲☲ COMMANDS ☲☲☲☲

# Response to a Ping
@bot.event
async def on_message(message):
if bot.user.mentioned_in(message):
response = random.choice(responses)
await message.reply(response)

await bot.process_commands(message)


# Add Ping Command
@bot.command()
async def addping(ctx, role: discord.Role, member: discord.Member = None):
Expand Down

0 comments on commit 653dc9a

Please sign in to comment.