2021-10-24 22:46:36 +01:00
|
|
|
// SupportBot | Emerald Services
|
|
|
|
|
// Ping Command
|
|
|
|
|
|
|
|
|
|
const fs = require("fs");
|
|
|
|
|
|
|
|
|
|
const Discord = require("discord.js");
|
|
|
|
|
const yaml = require("js-yaml");
|
2021-10-27 19:30:10 -05:00
|
|
|
const supportbot = yaml.load(
|
|
|
|
|
fs.readFileSync("./Configs/supportbot.yml", "utf8")
|
|
|
|
|
);
|
|
|
|
|
const cmdconfig = yaml.load(fs.readFileSync("./Configs/commands.yml", "utf8"));
|
2021-10-24 22:46:36 +01:00
|
|
|
|
|
|
|
|
const Command = require("../Structures/Command.js");
|
|
|
|
|
|
|
|
|
|
module.exports = new Command({
|
2022-07-23 07:50:12 +01:00
|
|
|
name: cmdconfig.Ping.Command,
|
|
|
|
|
description: cmdconfig.Ping.Description,
|
2021-12-18 18:57:26 -06:00
|
|
|
options: [],
|
2022-07-23 07:50:12 +01:00
|
|
|
permissions: cmdconfig.Ping.Permission,
|
2021-10-24 22:46:36 +01:00
|
|
|
|
|
|
|
|
async run(interaction) {
|
2022-07-23 07:50:12 +01:00
|
|
|
let disableCommand = true;
|
|
|
|
|
|
2022-07-22 13:19:05 +01:00
|
|
|
const PingEmbed = new Discord.EmbedBuilder()
|
2021-10-24 22:46:36 +01:00
|
|
|
.setDescription(
|
|
|
|
|
`:ping_pong: **Ping:** \`${interaction.client.ws.ping} ms\``
|
|
|
|
|
)
|
2022-08-12 01:35:36 +01:00
|
|
|
.setColor(supportbot.Embed.Colours.General);
|
2021-10-24 22:46:36 +01:00
|
|
|
|
|
|
|
|
interaction.reply({
|
|
|
|
|
embeds: [PingEmbed],
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
});
|