Skip to content

zoewithabang/zerobot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

288 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ZeroBot Build Status CodeFactor

ZeroBot is a Discord bot that supports Markov chain messaging, CyTube integration and other fun commands and features (like cat pictures on demand!).

If you have any questions or issues setting up or operating ZeroBot, please create a new issue on GitHub.

All currently available ZeroBot commands All currently available ZeroBot commands

Commands

Note: To see the syntax required for each command, use the help command once the bot is on your server.

Markov

Once you have written permission from a user, you can use the getposts command to store their posts on your database. Once stored, you can use the markov command to generate a Markov chain message from a given single user, multiple users or from all users on the server. Optionally, a seed can also be provided to force the chain message to begin with one or more given words.

If a user wants their stored posts removed, this automatically occurs when their account is cleared via the user command.

CyTube

Note: These are disabled by default.

If you have a CyTube server hosted on the same machine and have configured the options table in the database appropriately, you can use music and np to link a CyTube room and the currently playing song.

Cat & Dog!

Use the cat and dog commands to get cat and dog pictures!

Command Aliases

In order to not ping people constantly with markov commands, you can use alias to create a shorthand command alias! This works with any other command that ZeroBot recognises as well.

Ranks and Management

Commands can be enabled, disabled and rank restricted using the command command. You can give users different permission ranks with the user command.

Requirements

  • Java 8+
  • Apache Maven
  • MySQL server
  • Linux 64-bit (should work on Windows / other platforms too especially if you don't plan to support CyTube features)

Setup

Database

  • Create a database for ZeroBot on your MySQL server with a dedicated user account like below (please don't use root).
GRANT USAGE ON *.* TO zerobot@localhost IDENTIFIED BY 'secret_zerobot_mysql_password';
GRANT ALL PRIVILEGES ON zerobot.* TO zerobot@localhost;
CREATE DATABASE zerobot;
INSERT INTO options (`key`, `value`) VALUES ('cat_api_key', 'cat api key here');

INSERT INTO options (`key`, `value`) VALUES ('dog_api_key', 'dog api key here');
  • Run zerobot.sql on the new database that has been made, like below.
mysql -u zerobot  -p zerobot < zerobot.sql

Bot Account

Configuration

  • In src/main/resources, copy zerobot.properties.example to zerobot.properties.
  • Edit zerobot.properties to add the bot account's token, the command prefix that you want to use and the MySQL database details.

Running

You should now be able to launch ZeroBot with run.sh in the project root directory.

About

Discord bot using Discord4J that supports Markov chain messaging, CyTube integration and more!

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors