mirror of
https://github.com/JonnyBro/JaBa.git
synced 2024-11-22 13:14:58 +05:00
06a5fbd724
Фиксики, поддерка контекстных команд
23 lines
No EOL
1.1 KiB
JavaScript
23 lines
No EOL
1.1 KiB
JavaScript
require("./helpers/extenders");
|
|
|
|
const { GatewayIntentBits } = require("discord.js"),
|
|
JaBa = require("./base/JaBa");
|
|
|
|
const client = new JaBa({
|
|
intents: [ GatewayIntentBits.Guilds, GatewayIntentBits.GuildMembers, GatewayIntentBits.GuildBans, GatewayIntentBits.GuildEmojisAndStickers, GatewayIntentBits.GuildIntegrations, GatewayIntentBits.GuildInvites, GatewayIntentBits.GuildVoiceStates, GatewayIntentBits.GuildPresences, GatewayIntentBits.GuildMessages, GatewayIntentBits.GuildMessageReactions, GatewayIntentBits.GuildMessageTyping, GatewayIntentBits.MessageContent ],
|
|
allowedMentions: { parse: ["everyone", "roles", "users"] }
|
|
});
|
|
|
|
(async () => {
|
|
client.translations = await require("./helpers/languages")();
|
|
|
|
await client.loadEvents("../events");
|
|
await client.loadCommands("../commands");
|
|
await client.init();
|
|
})();
|
|
|
|
client.on("disconnect", () => client.logger.log("Bot is disconnecting...", "warn"))
|
|
.on("reconnecting", () => client.logger.log("Bot reconnecting...", "warn"))
|
|
.on("warn", (info) => client.logger.log(info, "warn"));
|
|
// .on("error", (e) => client.logger.log(e, "error"))
|
|
process.on("unhandledRejection", (err) => console.error(err)); |