Implement queue flush
This commit is contained in:
@@ -20,4 +20,9 @@ module.exports = class AudioQueue {
|
||||
this.queue.push(element);
|
||||
if (this.queue.length == 1) this.playNext();
|
||||
}
|
||||
flush() {
|
||||
this.current.setVolume(0);
|
||||
this.queue=[];
|
||||
this.playNext();
|
||||
}
|
||||
}
|
@@ -17,4 +17,5 @@ module.exports = function (bot, api) {
|
||||
api.respond(message, args[1] + " is not a valid engine name");
|
||||
}
|
||||
});
|
||||
api.registerCommand('flush',()=>api.queue.flush());
|
||||
}
|
BIN
tts/.DS_Store
vendored
BIN
tts/.DS_Store
vendored
Binary file not shown.
Reference in New Issue
Block a user