Giter Site home page Giter Site logo

ivanskodje / rpbot Goto Github PK

View Code? Open in Web Editor NEW
3.0 1.0 0.0 17.13 MB

A simple pen & paper roleplaying Discord bot written in Java. The purpose of this bot is to supplement pen & paper roleplayers that use Discord.

License: GNU General Public License v3.0

Java 99.87% Shell 0.13%
discord rp roleplaying bot java discord4j command4j rpg roll dice

rpbot's Introduction

RPBot

A simple pen & paper roleplaying bot written in Java. The purpose of this bot is to supplement pen & paper roleplayers that use Discord.

Contributions are always welcome.

How to setup

Open the project in the IDE of your choice. It is assumed you know how to import new projects, as well as how to import libraries.

Setting up the Bot (Discordapp.com)

  1. Go to Discordapp.com and create a "New App"
  2. Note down the given ID if your App.
  3. Add your own App ID to the oAuth2 URL: https://discordapp.com/api/oauth2/authorize?client_id=&scope=bot&permissions=0
  4. Enter the URL into your browser, and select which channel you want the bot to connect.
  5. Done. The bot should now appear as "Offline" in the selected Discord channel.

Bot Login

  1. Go to Discordapp.com and copy the Token value of your bot
  2. Create a token.txt textfile and add it to the root of your project
  3. Open token.txt and store the token on the first line. NB: Never share your token file. If you do, other people can login as YOUR bot.
  4. Run Main.java and the bot should login. Test it by typing in '!roll 1d6'.

Available Commands

Command Description
help Displays available commands (!help)
roll Generates dices equal to the first number, and rolls values between 1 and the second number. (!roll 1d6)
calc Calculates mathematical expressions. (!calc (1*2)/2)
name Generates a female or male name. (!name female)
table Used to generate or display a row from a text file (!table short example 5)
list Used to create your own lists and items. Can create lists inside lists. Be careful when removing data.

Additional Information (Discord4J and Command4J)

Check out the documentation for Discord4J and the Discord4J Plugin: Command4J.

You can also ask for help on the official Discord4J Discord Server.

License

GPLv3 License

Copyright (C) 2016 Ivan P. Skodje

This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.

GPLv3

rpbot's People

Stargazers

 avatar  avatar  avatar

Watchers

 avatar

rpbot's Issues

Ivan, you don't even know what "Engineer" means.

@ivanskodje Ivan, you're not engineer.

Stop falsely claiming to be an "Engineer". You know nothing about engineering. Engineering has nothing to do with sitting lazily behind a keyboard and writing code. Engineering is a real subject. Engineering means designing and building real mechanical systems, like vehicular engines and turbojets. You software devs are claiming the most ridiculous of false claims these days. Software dev is easy and for kids, and has absolutely nothing to do with a real and serious complex subject like engineering. So stop the lies. You will never be engineers @ivanskodje .

Don't put your token in the repository

Hello Ivanskodje.

I advise you to remive your token from token.txt, and load it instead from environment variables.

Otherwise anyone could use the token to get use the api to act as your bot.

Regards

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.