diff options
Diffstat (limited to 'server/src/commands/bot/Ping.ts')
| -rw-r--r-- | server/src/commands/bot/Ping.ts | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/server/src/commands/bot/Ping.ts b/server/src/commands/bot/Ping.ts new file mode 100644 index 0000000..d7857c7 --- /dev/null +++ b/server/src/commands/bot/Ping.ts @@ -0,0 +1,23 @@ +import { Command } from 'discord-akairo'; +import { Message } from 'discord.js'; + +export default class PingBot extends Command { + public constructor() { + super('ping', { + aliases: ['ping'], + category: 'bot', + description: { + content: 'Check the latency of the ping to the Discord API.', + usage: '', + examples: [ + '' + ] + }, + ratelimit: 3 + }); + } + + public exec(msg: Message): Promise<Message> { + return msg.channel.send(`Pong! \`${this.client.ws.ping}ms\`.`); + } +}
\ No newline at end of file |