Skip to content
This repository has been archived by the owner on Nov 9, 2024. It is now read-only.

Latest commit

 

History

History
executable file
·
26 lines (25 loc) · 552 Bytes

messageCommands.md

File metadata and controls

executable file
·
26 lines (25 loc) · 552 Bytes

MessageCommands (With Aliases)

Format

export const MsgCommand = {
    name: "commandName",
    // Other Command Options
    aliases: ["commandName2", "commandName3"], // Optional to be provided.
    run: async(client, message, args) => {
        // Code Here
    }
};

Example Code

export const MsgCommand = {
    name: "ping",
    // Other Command Options
    aliases: ["pong"],
    run: (client, message, args) => {
        message.channel.send({
            content: `My ping is ${client.ws.ping}ms.`
        });
    }
};