1

So what I did is a bot with interaction commands, example:

@client.command(case_insensitive=True)
async def handhold(ctx, user: discord.Member):
    embed = discord.Embed(
        description=
        f'**{ctx.author.name}** is holding hands with **{user.display_name}**',
        colour=discord.Colour.blue())

    embed.set_footer(icon_url=ctx.author.avatar_url,
                     text=f'Requested by {ctx.author.name} | So lewd.')

    random_link = random.choice(hands)
    embed.set_image(url=random_link)

    await ctx.send(embed=embed)

Now, if I wanted the bot to send not the embed but a different message whenever someone tags a specific member, how would I do that?

What I tried, out of ignorance, was this:

Owner = guild.get_member([my own id])
  if user is Owner:
    await ctx.send(f"Nah fam")
  else:

To have it say "nah fam" if someone tags me. I receive no error, the command simply doesn't run.

ghes
  • 11
  • 1
  • In python, `is` should be used to check to variables point to the exact same instance of a class. It is different from `==` operator. Check [this](https://stackoverflow.com/a/133024/13688761) answer. Instead, you could probably compare user ids – Miguel Alorda Aug 06 '21 at 14:51

0 Answers0