Fix Restart #6
All checks were successful
Subsonics - Pipeline/pipeline/head This commit looks good
All checks were successful
Subsonics - Pipeline/pipeline/head This commit looks good
This commit is contained in:
parent
7fbba2fdb9
commit
67af38c9f4
@ -32,37 +32,8 @@ module.exports = {
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
const nodes = [
|
await client.manager.destroyNode()
|
||||||
{
|
await client.manager.createNode()
|
||||||
host: "lavalink.devamop.in",
|
|
||||||
password: "DevamOP",
|
|
||||||
port: 443,
|
|
||||||
secure: true
|
|
||||||
}
|
|
||||||
];
|
|
||||||
|
|
||||||
client.manager = new Manager({
|
|
||||||
// The nodes to connect to, optional if using default lavalink options
|
|
||||||
nodes,
|
|
||||||
// Method to send voice data to Discord
|
|
||||||
send: (id, payload) => {
|
|
||||||
const guild = client.guilds.cache.get(id);
|
|
||||||
// NOTE: FOR ERIS YOU NEED JSON.stringify() THE PAYLOAD
|
|
||||||
if (guild) guild.shard.send(payload);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
// Emitted whenever a node connects
|
|
||||||
client.manager.on("nodeConnect", node => {
|
|
||||||
console.log(`Node "${node.options.identifier}" connected.`)
|
|
||||||
})
|
|
||||||
|
|
||||||
// Emitted whenever a node encountered an error
|
|
||||||
client.manager.on("nodeError", (node, error) => {
|
|
||||||
console.log(`Node "${node.options.identifier}" encountered an error: ${error.message}.`)
|
|
||||||
})
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user