mirror of
https://github.com/musix-org/musix-oss
synced 2025-07-07 01:20:48 +00:00
additional error logging and debugging.
This commit is contained in:
@ -1,22 +1,24 @@
|
||||
module.exports = async function (client, reason, guild) {
|
||||
const queue = client.queue.get(guild.id);
|
||||
queue.playing = false;
|
||||
if (reason === "seek") {
|
||||
return (queue.playing = true);
|
||||
}
|
||||
|
||||
if (!queue.songLooping) {
|
||||
if (queue.looping) {
|
||||
queue.songs.push(queue.songs[0]);
|
||||
module.exports = {
|
||||
async execute(client, guild) {
|
||||
const queue = client.queue.get(guild.id);
|
||||
queue.playing = false;
|
||||
if (queue.endReason === "seek") {
|
||||
return (queue.playing = true);
|
||||
}
|
||||
|
||||
queue.time = 0;
|
||||
queue.votes = 0;
|
||||
queue.voters = [];
|
||||
if (reason !== "replay") {
|
||||
if (reason === "previous") queue.songs.unshift(queue.prevSongs.pop())
|
||||
if (reason !== "previous") queue.prevSongs.push(queue.songs.shift());
|
||||
if (!queue.songLooping) {
|
||||
if (queue.looping) {
|
||||
queue.songs.push(queue.songs[0]);
|
||||
}
|
||||
|
||||
queue.time = 0;
|
||||
queue.votes = 0;
|
||||
queue.voters = [];
|
||||
if (queue.endReason !== "replay") {
|
||||
if (queue.endReason === "previous") queue.songs.unshift(queue.prevSongs.pop())
|
||||
if (queue.endReason !== "previous") queue.prevSongs.push(queue.songs.shift());
|
||||
}
|
||||
}
|
||||
}
|
||||
client.funcs.play(guild, queue.songs[0], client, 0, true);
|
||||
client.funcs.play(guild, queue.songs[0], client, 0, true);
|
||||
},
|
||||
};
|
Reference in New Issue
Block a user