Code Monkey home page Code Monkey logo

discord-rolereact's Introduction

Discord-RoleReact

A bot that automatically assigns roles based on message reactions.

Demo of Bot

Features

  • Customizable messages, reactions, commands, and roles

  • Auto-removes role when user removes a reaction

Installation

Clone this repository to your local machine.

Open roleReact.js, you will need to change most of the settings at the top of the file. The relevant lines look like this:

//Settings!
const yourID = ""; //Instructions on how to get this: https://redd.it/40zgse
const setupCMD = "!createroleressage"
let initialMessage = `**React to the messages below to receive the associated role. If you would like to remove the role, simply remove your reaction!**`;
const roles = ["Hacker", "Artist", "Public Relations", "Intern"];
const reactions = ["๐Ÿ’ป", "๐Ÿ–Œ", "๐Ÿ˜ƒ", "๐Ÿ†•"];
const botToken = ""; /*You'll have to set this yourself; read more
                     here https://github.com/reactiflux/discord-irc/wiki/Creating-a-discord-bot-&-getting-a-token*/

For the bot to work properly, you must:

  • Fill in the yourID variable; you can get it in any discord channel by typing "@YOUR_NAME". For me, it would be @Night.

  • Adjust the setup command, if you do not like the default one

  • Adjust the initial message, if you do not like the default one

  • Adjust the roles to ones that are actually in your server; make sure the bot's role is high enough on the list in your server's settings that it can assign the them properly.

  • Replace the reactions with the ones of your choosing. Note: to get the value for the reaction, do NOT simply type :my_reaction: and copy the result. You must type \:my_reaction with the backslash and copy that result after pressening enter. If done correctly, the reaction should appear smaller than usual.

  • Set up the bot and get the token. This [Github Wiki Page](here https://github.com/reactiflux/discord-irc/wiki/Creating-a-discord-bot-&-getting-a-token) does a better job of expaining it than I ever could. An image of the permissions the bot needs can be found here.

Conclusion

I hope you find this bot useful. If you need any help, or find any bugs, use the appropriate forums in this repository to contact me.

discord-rolereact's People

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.