0.5.1 • Published 6 years ago
@tohru/chopin-connector v0.5.1
chopin-connector
Connects chopin with discord.js
chopin-connector is heavily influenced by discord.js-music with slight modifications for my own usage.
I do not support any usage currently.
Usage
Chopin relies on the following packages to be installed: @tohru/chopin
, discord.js
The primary reason for this is because the goal is to make a bridge between discord.js and Chopin for ease of use.
In your entry file:
require('@tohru/chopin-connector');
In a command file:
const playlist = message.guild.playlist;
await msg.guild.playlist.add('some-yt-url', [ytService]);
await playlist.start(msg.member.voiceChannel);
Chopin & chopin-connector emit the following events you can listen to:
- chopinConnectorSongAdd -> returns an array of songs
- chopinConnectorStreamError -> returns the error
- chopinConnectorPlaying -> returns the currently playing song
- chopinConnectorEnd -> returns the end reason or undefined/null
Contributing
- Fork it!
- Create your feature branch:
git checkout -b my-new-feature
- Commit your changes:
git commit -am 'Add some feature'
- Push to the branch:
git push origin my-new-feature
- Submit a pull request :D
Author
chopin-connector © iCrawl. Authored and maintained by iCrawl.
GitHub @iCrawl