├── README.md ├── embed.js ├── ping.js └── say.js /README.md: -------------------------------------------------------------------------------- 1 | # Ruben 2 | Discord Bot Development 3 | -------------------------------------------------------------------------------- /embed.js: -------------------------------------------------------------------------------- 1 | if (msg.content.startsWith(`${prefix}embed`)) { 2 | const embed = new Discord.RichEmbed(); 3 | const context = msg.content.split(' ').splice(1).join(' '); 4 | if (context.length <= 2 || context.length >= 1200) return msg.channel.send('**Usage:** `!embed `'); 5 | embed.setTitle(' ') 6 | .setDescription(context) 7 | .setColor(0x1480C3); 8 | if (msg.member.permissions.has("ADMINISTRATOR")) return msg.channel.send(embed); 9 | } 10 | -------------------------------------------------------------------------------- /ping.js: -------------------------------------------------------------------------------- 1 | if(msg.content.startsWith(`${prefix}ping`)) { 2 | const embed = new Discord.RichEmbed() 3 | .addField(`** **`, `Please use the command **!commands**` + `\n` + `**Pong!** Bot is connected and online!` + `\n` + `** **`) 4 | .setThumbnail(`${client.user.avatarURL}`) 5 | .setFooter(`${msg.author.tag}`, msg.author.avatarURL) 6 | .setTimestamp() 7 | .setColor(0x61bb46); 8 | msg.channel.send(embed); 9 | } 10 | -------------------------------------------------------------------------------- /say.js: -------------------------------------------------------------------------------- 1 | if (msg.content.startsWith(`${prefix}say`)) { 2 | 3 | const embed = new Discord.RichEmbed() 4 | .setDescription(`${msg.author} used the command **!say**`) 5 | .setColor(0x1480C3); 6 | client.channels.get('505560920819499019').send({ 7 | embed 8 | }); 9 | 10 | 11 | const context = msg.content.split(' ').splice(1).join(' '); 12 | if (context.length <= 2 || context.length >= 1200) return msg.channel.send('**Usage:** `!say `'); 13 | if (msg.member.permissions.has("MANAGE_MESSAGES")) return msg.channel.send(context); 14 | msg.delete() 15 | } 16 | --------------------------------------------------------------------------------