Welcome on Léonie GitHub Repo !
You can find all of information of Leonie in this README !
Consult NodeJS website if you does not have NodeJS.
When you have NodeJS and download files, run this command:
npm install
Dependencies are installed !
For configurate the bot, you must create a config folder.
mkdir config
And create an .env
file on config folder
cd config
touch .env
Now, when you have create .env
file, give information on your bot
LEONIE_TOKEN = "your_token_bot_here"
LEONIE_DEV_TOKEN = "your_token_dev_bot_here"
SCRET_SERVER_ID = "your_server_id_for_dev"
Nice ! Configuration are finish !
When you are ready, use this command:
npm run dev
Your bot is Online ! (Unless you did something wrong)
How Slash Commands does work on Léonie ? It's simple !
Go to SlashCommands folder !
Léonie use SlashCommandBuilder
class of discord.js !
So check the documentation if you want to create another slash commands !
A Slash Commands file looks like this:
import {
ChatInputCommandInteraction,
Client,
SlashCommandBuilder
} from 'discord.js';
export default {
data: new SlashCommandBuilder()
.setName('command')
.setDescription("Description of command")
run: async (client: Client, interaction: ChatInputCommandInteraction) => {
// Your code here
}
}
};
Nice ! You know how to create other slash commands !
How Message Commands does work on Léonie ? It's simple !
Go to Commands folder !
A Message Commands file looks like this:
import { Client, Message } from 'discord.js';
export default {
name: 'commands',
help: ['c'],
description: 'Description command',
run: (client: Client, message: Message) => {
// Your code here
}
};
Nice ! You know how to create other message commands !
This bot made by Mayo.