mirror of
https://github.com/BluemediaDev/muse.git
synced 2025-05-05 01:51:35 +02:00
Configurable voice channel leave behavior (#514)
Co-authored-by: Max Isom <hi@maxisom.me>
This commit is contained in:
parent
8e5b3cfa43
commit
4dbb55a721
8 changed files with 123 additions and 11 deletions
|
@ -4,7 +4,7 @@ import {Except} from 'type-fest';
|
|||
import shuffle from 'array-shuffle';
|
||||
import {TYPES} from '../types.js';
|
||||
import GetSongs from '../services/get-songs.js';
|
||||
import {QueuedSong} from './player.js';
|
||||
import {QueuedSong, STATUS} from './player.js';
|
||||
import PlayerManager from '../managers/player.js';
|
||||
import {prisma} from '../utils/db.js';
|
||||
import {buildPlayingMessageEmbed} from '../utils/build-embed.js';
|
||||
|
@ -131,6 +131,9 @@ export default class AddQueryToQueue {
|
|||
await interaction.editReply({
|
||||
embeds: [buildPlayingMessageEmbed(player)],
|
||||
});
|
||||
} else if (player.status === STATUS.IDLE) {
|
||||
// Player is idle, start playback instead
|
||||
await player.play();
|
||||
}
|
||||
|
||||
// Build response message
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue