mirror of https://github.com/thaldrin/thaldrin.git
12 lines
297 B
TypeScript
12 lines
297 B
TypeScript
|
import { ShardingManager } from "discord.js";
|
||
|
import config from "./config";
|
||
|
let Sharder = new ShardingManager('./build/index.js', {
|
||
|
token: config.token,
|
||
|
totalShards: "auto"
|
||
|
})
|
||
|
|
||
|
Sharder.on("shardCreate", async (shard) => {
|
||
|
console.log(`Launched Shard #${shard.id}`)
|
||
|
})
|
||
|
|
||
|
Sharder.spawn()
|