#๐ Discord bot
48 messages ยท Page 1 of 1 (latest)
@coarse rivet
Remember to:
- Ask your Python question, not if you can ask or if there's an expert who can help.
- Show a code sample as text (rather than a screenshot) and the error message, if you've got one.
- Explain what you expect to happen and what actually happens.
:warning: Do not pip install anything that isn't related to your question, especially if asked to over DMs.
Okay, let me explain the type of bot i want you to make:
1.
I want this bot to be checking the MAZINKOOOO channel (id:1099175930188009583) for the message1 "Boosted: Bamboo" or the message2 "Boosted: Blue Flower".
2a. When the bot sees message1 I want the bot to send a command (?set FieldName1 Bamboo) to the POTMASTEROVER90000 channel (id:1260803844812570767). Then I want the bot to send 2 more commands to the same channel 5 seconds later (?stop) and another 5 seconds later send (?start).
2b. When the bot sees message2 I want the bot to send a command (?set FieldName1 Blue Flower) to the POTMASTEROVER90000 channel (id:1260803844812570767). Then I want the bot to send 2 more commands to the same channel 5 seconds later (?stop) and another 5 seconds later send (?start).
(message 1 and 2 are from anotherr bot)
- 15 minutes after the last command I want the bot to send the commands (?set FieldName1 Pine Tree), then 5 seconds later the command (?stop), then another 5 seconds later the command (?start).
- I want this bot to be scanning for "message1" and "message2" 24/7.
what have you tried so far? do you have an error? if so, paste your full code and traceback and we can help you fix it
and what is the problem?
It detects when my user id sends message 1 and 2
but not the bot
see it doesnt detect this
the code fully works apart from detecting the message from the other bot
this is the full code
the other one was my testing
i have no errors, and when debugging i found that it detected the the bot sending messages properly, it detected the right channel but it only doesnt detect the message
ive been trying to fix this for the past week and this my last resort lol
Change your discord bot token, if haven't already. Since you sent it in pastebin
Are you getting any prints from on_message event?
yeah
Is it form the bot?
Message is from the specific bot and in the correct channel.
and
No matching keyword found in the message:
yeah sent in the terminal
!d discord.Message.embeds
A list of embeds the message has. If Intents.message_content is not enabled this will always be an empty list unless the bot is mentioned or the message is a direct message.
You probably want the content of the embeds since the messages have no content
You are getting content of message with content = message.content
But you want content of embed from that message
That can be obtained by getting embeds attribute of message
You should try printing contents of embeds inside the if
embeds attribute of message will return you list of all embeds
The part of the embed you probably want is description
which if statement?
That one where you are checking if the message is from that bot and inside that channel
This help channel has been closed and it's no longer possible to send messages here. If your question wasn't answered, feel free to create a new post in #1035199133436354600. To maximize your chances of getting a response, check out this guide on asking good questions.