first commit
This commit is contained in:
16
commands/Info/ping.js
Normal file
16
commands/Info/ping.js
Normal file
@ -0,0 +1,16 @@
|
||||
const { EmbedBuilder } = require('discord.js');
|
||||
|
||||
module.exports = {
|
||||
name: "ping",
|
||||
description: "Returns websocket latency",
|
||||
|
||||
run: async (client, interaction) => {
|
||||
const embed = new EmbedBuilder()
|
||||
.setColor("#FF0000")
|
||||
.setTitle("🏓 Pong!")
|
||||
.setDescription(`Latency : ${client.ws.ping}ms`)
|
||||
.setTimestamp()
|
||||
.setFooter({ text: `Requested by ${interaction.user.tag}`, iconURL: `${interaction.user.displayAvatarURL()}` });
|
||||
interaction.followUp({ embeds: [embed] });
|
||||
},
|
||||
};
|
12
commands/general/tmoji.js
Normal file
12
commands/general/tmoji.js
Normal file
@ -0,0 +1,12 @@
|
||||
const { EmbedBuilder } = require('discord.js');
|
||||
const { getEmoji, getAllEmoji, getThemes } = require('random-text-meme');
|
||||
|
||||
|
||||
module.exports = {
|
||||
name: "tmoji",
|
||||
description: "Returns a random Text Emoji",
|
||||
|
||||
run: async (client, interaction) => {
|
||||
await interaction.editReply(getEmoji());
|
||||
},
|
||||
};
|
47
commands/general/urban.js
Normal file
47
commands/general/urban.js
Normal file
@ -0,0 +1,47 @@
|
||||
const {
|
||||
EmbedBuilder
|
||||
} = require('discord.js');
|
||||
var urban = require('urban')
|
||||
const isNotDefined = require("is-not-defined");
|
||||
|
||||
module.exports = {
|
||||
name: "urban",
|
||||
description: "Searches Urban Dictionary",
|
||||
options: [{
|
||||
"name": "query",
|
||||
"description": "The thing you want to search for",
|
||||
"required": true,
|
||||
"type": 3 // 6 is type USER
|
||||
}],
|
||||
|
||||
run: async (client, interaction) => {
|
||||
|
||||
let searchWord = interaction.options._hoistedOptions[0].value
|
||||
search = urban(searchWord);
|
||||
|
||||
search.first(function(data) {
|
||||
|
||||
if (!isNotDefined(data)) {
|
||||
|
||||
const embed = new EmbedBuilder()
|
||||
.setColor("#FF0000")
|
||||
.setTitle("Results for: " + searchWord)
|
||||
.setDescription("Definition: " + data.definition)
|
||||
.addFields({
|
||||
name: 'Example',
|
||||
value: data.example
|
||||
})
|
||||
.setTimestamp()
|
||||
.setFooter({
|
||||
text: `Requested by ${interaction.user.tag}`,
|
||||
iconURL: `${interaction.user.displayAvatarURL()}`
|
||||
});
|
||||
interaction.editReply({
|
||||
embeds: [embed]
|
||||
});
|
||||
} else {
|
||||
return interaction.editReply("Sorry, no results were found!")
|
||||
}
|
||||
});
|
||||
},
|
||||
};
|
Reference in New Issue
Block a user