Stopped using dispatcher

This commit is contained in:
Christer Warén 2021-06-23 01:25:45 +03:00
parent 284f0e9f0c
commit 10c6a8c589
4 changed files with 4 additions and 4 deletions

View File

@ -27,7 +27,7 @@ module.exports = {
if(currentRadio){
client.funcs.statisticsUpdate(client, currentRadio.currentGuild.guild, currentRadio);
currentRadio.connection.dispatcher?.destroy();
currentRadio.connection.destroy();
currentRadio.voiceChannel.leave();
const cembed = new Discord.MessageEmbed()
.setTitle(client.messages.maintenanceTitle)

View File

@ -76,7 +76,7 @@ module.exports = {
if (radio) {
client.funcs.statisticsUpdate(client, msg.guild, radio);
radio.connection.dispatcher.destroy();
radio.connection.destroy();
radio.station = station;
radio.textChannel = msg.channel;
play(msg.guild, client, url);

View File

@ -9,7 +9,7 @@ module.exports = {
const radio = client.radio.get(msg.guild.id);
if (client.funcs.check(client, msg, command)) {
client.funcs.statisticsUpdate(client, msg.guild, radio);
radio.connection.dispatcher.destroy();
radio.connection.destroy();
radio.voiceChannel.leave();
client.radio.delete(msg.guild.id);
msg.channel.send(client.messageEmojis["stop"] + client.messages.stop);

View File

@ -19,7 +19,7 @@ module.exports = {
if (volume > 100) return msg.channel.send(client.messages.maxVolume);
if (volume < 0) return msg.channel.send(client.messages.negativeVolume);
radio.volume = volume;
radio.connection.dispatcher.setVolume(volume / 5);
/*radio.connection.dispatcher.setVolume(volume / 5);*/
message.newVolume = client.messages.newVolume.replace("%volume%", volume);
return msg.channel.send(message.newVolume);
}