Tag discord.js

[Solved] Get the word, from a sentence that the user is talking about [closed]

Credit: ThuverX let word if(content.indexOf(“what”) !== -1 && content[content.indexOf(“what”)+1] !== “is”) word = content[content.indexOf(“what”)+1] else if(content.indexOf(“meaning”) !== -1) word = content[content.indexOf(“meaning”)+2] else if(content.indexOf(“means”) !== -1) word = content[content.indexOf(“means”)-1] 0 solved Get the word, from a sentence that the user is…

[Solved] how do i send two messages in one? [closed]

You Could Use \n To Make a New Line or You Can Use this code to make the text a link const embed = new Discord.MessageEmbed() embed.setTitle(“BOT INVITE LINK”) embed.setColor(“BLACK”) embed.setURL(“INVITE LINK”) embed.setDescription(“**Click On The Blue Title Above to Invite…

[Solved] discord.js var token unexpected

The problem is on the second line. var = mentionlycan = message.mentions.users.first() You’re defining a variable wrong. Change it to: var mentionlycan = message.mentions.users.first(); 2 solved discord.js var token unexpected

[Solved] Unable to use await in an if function

Your issue starts with question 4. You are trying to run code without waiting for the return. if (positionInput.content.toLowerCase() === ‘community agent’) { // Won’t wait call.prompt(question5CommunityString, { time: 50000, channel: usersDMs }).then(question5CMsg => { question5Answer = question5CMsg.content; // Won’t…

[Solved] What does this if-statement exactly do?

The first if statement if(command.name) checks, whether the property name of commands is empty or not. If it’s empty, it will **not execute the code inside the brackets and jump straight to the else block If not, it will execute…

[Solved] How can I add Embed message from an array discord.js?

Well You just need to use embeds like in the help command. Here the code: if (command === “t”) { // Truth const truth = t[Math.floor(Math.random() * t.length)]; message.channel.send(new Discord.MessageEmbed() .setTitle(“Truth”) .setDescription(truth)); } else if (command === “d”) { //…