discord-player-play-dl/src/utils/Constants.ts

43 lines
1.1 KiB
TypeScript
Raw Normal View History

2021-05-01 12:59:42 +05:00
// @ts-nocheck
import { PlayerOptions as DP_OPTIONS } from '../types/types';
2021-04-06 17:55:29 +05:00
export const PlayerEvents = {
2021-04-06 17:58:46 +05:00
BOT_DISCONNECT: 'botDisconnect',
CHANNEL_EMPTY: 'channelEmpty',
2021-04-06 19:06:18 +05:00
CONNECTION_CREATE: 'connectionCreate',
2021-04-06 17:58:46 +05:00
ERROR: 'error',
2021-04-06 19:06:18 +05:00
MUSIC_STOP: 'musicStop',
2021-04-06 17:58:46 +05:00
NO_RESULTS: 'noResults',
PLAYLIST_ADD: 'playlistAdd',
PLAYLIST_PARSE_END: 'playlistParseEnd',
PLAYLIST_PARSE_START: 'playlistParseStart',
QUEUE_CREATE: 'queueCreate',
QUEUE_END: 'queueEnd',
SEARCH_CANCEL: 'searchCancel',
SEARCH_INVALID_RESPONSE: 'searchInvalidResponse',
SEARCH_RESULTS: 'searchResults',
TRACK_ADD: 'trackAdd',
2021-04-06 19:08:01 +05:00
TRACK_START: 'trackStart'
2021-04-06 19:06:18 +05:00
};
export const PlayerErrorEventCodes = {
2021-04-06 19:08:01 +05:00
LIVE_VIDEO: 'LiveVideo',
NOT_CONNECTED: 'NotConnected',
UNABLE_TO_JOIN: 'UnableToJoin',
NOT_PLAYING: 'NotPlaying',
PARSE_ERROR: 'ParseError',
2021-04-07 19:05:35 +05:00
VIDEO_UNAVAILABLE: 'VideoUnavailable',
MUSIC_STARTING: 'MusicStarting'
2021-04-06 17:58:46 +05:00
};
export const PlayerOptions: DP_OPTIONS = {
leaveOnEnd: true,
leaveOnStop: true,
leaveOnEmpty: true,
leaveOnEmptyCooldown: 0,
autoSelfDeaf: true,
enableLive: false,
ytdlDownloadOptions: {}
};