#Intents
1 messages · Page 1 of 1 (latest)
This was just for me. It would say that FLAGS is not a property of undefined (Intents) I also had issues like MessageEmbed is not a constructor. I found workarounds to these though.
So should I define intents?
for intents I just put a number, like:
const client = new Client({
intents: 33283
});
Then I would use this to generate the number https://ziad87.net/intents/
It just worked for me, because none of the imports wanted to work.
Hopefully this solves your problem!
1, Do not use magic numbers.
2, that website is not up to date to current intents
3, Use the Enums..
Are you using GatewayIntentBits to represent this?
Yes
Ok, I guess I might not be doing it right then.
If you are using partials, import Partials from discord.js
Thanks for correcting me.
GatewayIntentBits.GUILD_Messages?
GatewayIntentBits.GuildMessages
yes u aren't. Use GatewayIntentBits.<Flags> Flags wud be PascalCased
PascalCase
thank you!
uh no
client.on("messageCreate", message => {
if (message.content == "ping") {
message.channel.send("pong")
}
})