discord.py has an extensive collection of features. Events are one of the most useful of these. Events are used for welcoming bots, reaction roles,...
For further actions, you may consider blocking this person and/or reporting abuse
hey, very helpful guide. I was wondering how to trigger an event only if a certain user triggers it? For example, if I wanted to kick a certain user that said 'hello', but not have that kick apply to anyone else who said 'hello', how would I do that?
Events are always sent through to the bot, no matter who it's from. However, you can filter them using an
if
statement. For example, this snippet would work:You'll want to make sure you use
.lower()
on the text, because if you don't, they can sendhEllo
or just change the case of other letters to dodge your system.Hi friend! very good post, and how I see you are also pythonist xD, I really like Python hehe, I have a bot in Discord.py, I do not know much every day I'm getting new things,For now Search by: YouTube, Google, Wikipedia, among other things :slight_smile: I plan to write more post and translate them so that everyone can read, to my bot also translates texts
That's actually really cool! So you're making a translation bot?
Hello, good exactly no, I mean my bot is of general purpose, translates and make searches also that if interacting with users and so, and good at discord.py because I really like python :p dev-to-uploads.s3.amazonaws.com/up...
Well your bot looks really nice!
HI,
Thanks for all this explanation.
I need to make a py script that only receive message from a server.
The server is not mine, how can I register to this server ?
Do you have tips to help me.
Thanks
You can see a guide created by the discord.py creator here to add the bot to the server, which is what you want to do. Make sure that you have the
Manage Server
permission.I haven't this permission , the channel is not mine that why I'm looking for another way
You'll need to ask a channel admin to add the bot.
hey can any can help how i can add backend trigger url in my code
@client.command(aliases=['AVN'])
async def AVN(ctx):
await ctx.send(f'@everyone Please all join AVN immediately!!!')