qcarpentier / lovelace

Lovelace is (not yet) the best Discord bot to bootstrap your Discord server.
1 stars 0 forks source link

Make CommandHandler in order to load the command files #10

Closed SirMishaa closed 4 years ago

SirMishaa commented 4 years ago

The goal is to make a class that automatically loads all the files in the Commands folder.

Warning, the format of a command should respect the CommandInterface:

interface CommandInterface {
    name: string;
    description: string;
    permissions: Array<string>;
    isEnabled: boolean;
    typeEffect: boolean;
    commandInterval: number;
    execute(...args: any[]): any;
}

ClassManager is a big class that is going to be in charge of a lot of things.