Skip to content
This repository has been archived by the owner on Apr 28, 2021. It is now read-only.

Library to easily create message collector, reactions collector and reactions role on discord.js v12, with customization ways.

License

Notifications You must be signed in to change notification settings

IDjinn/Discord.js-Collector

Repository files navigation

downloads-npm-total downloads-npm-week dependencies-deprecated-status npm-version

Discord.js-collector

Library to easily create message collector, reactions collector and reactions role on discord.js v12, with customization ways.

Author Note: This library has no longer support, i will not maintenance this anymore, sorry for who use and like this project. I recommend each you re-do with your own code or migrate to another library who will keep supporting discord.js updates

Thank you for using discord.js-collector! ❤


Sumary

◘ Reactions Collectors:
| Reaction Role
| Menu
| Question
| Yes/No Question
| Embeds Paginator
◘ Messages Collectors:
| Question
| Async Question
◘ Examples
| Reaction Role Manager
| Reaction Menu
◘ Others
| Changelog
| Breaking Changes

Discord Server

Sorry, but support server was closed for no longer support of this lib

Documentation

See all documentation of last version here


Reaction role

You can create reactions roles, with amazing functions:
| • If you bot turns off, when it turns on all users reacted in messages will win the role.
| • If you bot turns off, if any user remove reaction, when the bot turns on will remove the role from him.
| • You can store the roles in a JSON file and migrate the reaction role data.
| • You can limit max roles given by bot, like 10 roles.
| • Toggled roles: Limit one of these roles to use (Util for colors reaction roles, only get one of roles)
| • Requirements: Limit roles to only boosters or discord developers win roles!
| • Just Win: you can configure a role to just give to member if him react on it!
| • Just Lose: you can configure a role to just take from member if him react on it!
| • Reversed: When react on it, member will lose the role. When take off reaction of it, member will win the role.

Reaction Role Gif

You can find this code example here


Reaction menu

To create a reaction menu with multiple pages.

Menu Gif

You can find this code example here

Simple reaction collector

To use in multiple actions, react and then trigger one function to do things.

Question Gif

Simple boolean reaction collector

To use in if statements, the asynchronous reaction collector returning Promise is more practical

Question Gif

Embeds pagination

Example here

Easier paginator embeds, with back/skip reaction to change current page.

Question Gif

You can find this code example here

Simple messages collector

Await for messages from user, and when it's send will fire a trigger to do things. See exemple [here]

You can find this code example here

Question Gif

Async message collector

Await for message from user, and when user send, will return user message as Promise.

Question Gif

const { MessageCollector } = require("discord.js-collector");

const botMessage = await message.channel.send("Awaiting a message");
const userMessage = await MessageCollector.asyncQuestion({
  botMessage,
  user: message.author.id,
});
if (userMessage.content === "ping") {
  await message.channel.send("pong!");
}

About

Library to easily create message collector, reactions collector and reactions role on discord.js v12, with customization ways.

Topics

Resources

License

Stars

Watchers

Forks

Contributors 4

  •  
  •  
  •  
  •