-
Notifications
You must be signed in to change notification settings - Fork 2
/
index.js
23 lines (19 loc) · 1.32 KB
/
index.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
const moment = require('moment')
const { Intents } = require('discord.js')
require('dotenv').config();
const {OneForAll} = require('./structures/Client/OneForAll')
const { dev, botperso } = require('./config')
if(!dev && !botperso) {
const Cluster = require("discord-hybrid-sharding");
new OneForAll({
partials: ['MESSAGE', 'CHANNEL', 'REACTION'],
restTimeOffset: 0,
shards: Cluster.data.SHARD_LIST,
intents: [Intents.FLAGS.GUILDS, Intents.FLAGS.GUILD_MESSAGE_REACTIONS,Intents.FLAGS.GUILD_BANS, Intents.FLAGS.GUILD_EMOJIS_AND_STICKERS, Intents.FLAGS.GUILD_WEBHOOKS, Intents.FLAGS.GUILD_INVITES, Intents.FLAGS.GUILD_MEMBERS, Intents.FLAGS.GUILD_VOICE_STATES, Intents.FLAGS.GUILD_PRESENCES, Intents.FLAGS.GUILD_MESSAGES],
shardCount: Cluster.data.TOTAL_SHARDS
})
}
else
new OneForAll({partials: ['MESSAGE', 'CHANNEL', 'REACTION'], restTimeOffset: 0, intents: [Intents.FLAGS.GUILDS,Intents.FLAGS.GUILD_MESSAGE_REACTIONS, Intents.FLAGS.GUILD_PRESENCES, Intents.FLAGS.DIRECT_MESSAGE_REACTIONS, Intents.FLAGS.GUILD_BANS, Intents.FLAGS.GUILD_EMOJIS_AND_STICKERS, Intents.FLAGS.GUILD_WEBHOOKS, Intents.FLAGS.GUILD_INVITES, Intents.FLAGS.GUILD_MEMBERS, Intents.FLAGS.GUILD_VOICE_STATES, Intents.FLAGS.GUILD_MESSAGES]})
require('events').EventEmitter.defaultMaxListeners = 0;
moment.locale('fr')