loop
This commit is contained in:
parent
65d691040d
commit
0ab77a89f0
1 changed files with 9 additions and 7 deletions
|
@ -23,13 +23,15 @@ class Music(commands.Cog):
|
||||||
|
|
||||||
async def start_nodes(self):
|
async def start_nodes(self):
|
||||||
await self.client.wait_until_ready()
|
await self.client.wait_until_ready()
|
||||||
|
try:
|
||||||
await self.client.wavelink.initiate_node(host = "127.0.0.1",
|
await self.client.wavelink.initiate_node(host = "127.0.0.1",
|
||||||
port = 2333,
|
port = 2333,
|
||||||
rest_uri = "http://127.0.0.1:2333",
|
rest_uri = "http://127.0.0.1:2333",
|
||||||
password = "youshallnotpass",
|
password = "youshallnotpass",
|
||||||
identifier = "PROD",
|
identifier = "PROD",
|
||||||
region = self.keys["REGION_DISCORD"])
|
region = self.keys["REGION_DISCORD"])
|
||||||
|
except:
|
||||||
|
await self.start_nodes()
|
||||||
|
|
||||||
@commands.command(name='connect')
|
@commands.command(name='connect')
|
||||||
async def connect_(self, ctx, *, channel: discord.VoiceChannel = None):
|
async def connect_(self, ctx, *, channel: discord.VoiceChannel = None):
|
||||||
|
|
Reference in a new issue