Add channelEmpty event in the readme

This commit is contained in:
Androz2091 2020-01-12 18:56:28 +01:00
parent 4c835286bc
commit 4e1d27cbb8

View file

@ -46,7 +46,8 @@ client.login(settings.token);
You can pass a third parameter when instantiating the class Player: the **options** object:
**options.leaveOnEnd**: whether the bot should leave the voice channel when there is no more song in the queue.
**options.leaveOnStop**: whether the bot should leave the voice channel when the `stop()` function is used.
**options.leaveOnStop**: whether the bot should leave the voice channel when the `stop()` function is used.
**options.leaveOnEmpty**: whether the bot should leave the voice channel if there is no more member in it.
### Features Overview
@ -82,6 +83,9 @@ client.player.getQueue(guildID)
})
.on('songChanged', (oldSong, newSong) => {
message.channel.send(`Now playing ${newSong.name}...`);
})
.on('channelEmpty', () => {
message.channel.send('Stop playing, there is no more member in the voice channel...');
});
```