Sign In

shardReconnecting

This event is fired when a shard starts reconnecting

v1.0.1+

Register the event

Enable shardReconnecting in events in your ForgeClient options in index.js:

const { ForgeClient } = require("@tryforge/forgescript")

const client = new ForgeClient({
  events: [
    "shardReconnecting"
  ],
  intents: [
    "Guilds"
  ]
})

Handle the event

Listen and react when shardReconnecting is triggered using an inline command or an external handler file:

client.commands.add({
  type: "shardReconnecting",
  code: `$log[shardReconnecting event was triggered!]`
})

Was this page helpful?