discord bot in php
Go to file
Ben Harris 89cb9dd304 final class, tests 2017-04-29 18:32:40 -04:00
fonts final class, tests 2017-04-29 18:32:40 -04:00
img bamboozle 2017-03-14 13:00:59 -04:00
paper fix tictactoe 2017-04-26 00:25:22 -04:00
project_proposal remove ignored files 2017-04-25 19:44:31 -04:00
src final class, tests 2017-04-29 18:32:40 -04:00
test/Commands final class, tests 2017-04-29 18:32:40 -04:00
.env.example update todo 2017-04-19 11:44:50 -04:00
.gitignore dev stuff 2017-04-16 23:18:32 -04:00
LICENSE.md add license, start music and tictactoe 2017-04-16 13:59:33 -04:00
README.md update README again 2017-04-19 12:40:37 -04:00
banner.txt Command classesgit status 2017-04-07 19:09:43 -04:00
benbot.todo tictactoe worksgd 2017-04-24 02:05:43 -04:00
bot add sync to bot 2017-04-27 14:03:00 -04:00
composer.json final class, tests 2017-04-29 18:32:40 -04:00
composer.lock final class, tests 2017-04-29 18:32:40 -04:00
copypasta.txt add attack helicopter copypasta 2017-04-24 14:11:33 -04:00
miscjokes.txt fix jokes file and bot 2017-04-13 02:16:15 -04:00
phpunit.xml final class, tests 2017-04-29 18:32:40 -04:00
run.php tictactoe wip 2017-04-20 02:29:37 -04:00
yomamajokes.txt add jokes from file 2017-03-18 12:32:12 -04:00

README.md

benbot

Add benbot to your server

This is a Discord bot I've been working on. Under heavy development. It's my senior project.

Feel free to clone this project and try your hand at making a bot.

Set up

Requires PHP 7.0 or later (7.1.4 is preferred. it includes an important fix for SSL and sending files larger than 100kb)

  1. git clone https://git.benharris.ch/srproj/benbot && cd benbot
  2. Install DiscordPHP and dependencies: composer install
  3. Get your Discord API Key and save it in .env (copy or rename .env.example and paste your keys in)
  4. --optional save your API keys in .env for openweathermap.org, cleverbot.com, and a phone number for the text command
  5. Run the bot ./bot start

If you want to keep your bot running in the background, run it as ./bot nohup. If bash isn't available, you can run the bot with just php run.php (and nohup php run.php & to run in the background)

Commands

    //////                        //////                //
   //    //    ////    //////    //    //    ////    ////////
  //////    ////////  //    //  //////    //    //    //
 //    //  //        //    //  //    //  //    //    //
//////      //////  //    //  //////      ////        ////
-------------------------------------------------------------
- a bot made by benh. avatar by hirose.

;8ball <your question to ask here> - ask the mighty 8-ball
;ascii [font] <words> - creates ascii word art
;chat <what you want to say> - talk to benbot
;dm [@user] [message] - sends a dm
;fonts - change your message to another font
;get <thing to find> - retrieve a definition
;img <name of image to show|list|save|rm> - save and retrieve images
;joke [chucknorris|yomama|dad] - tells a random joke
;kaomoji [sad|happy|angry|confused|surprised] - shows a cool japanese emoji face thing
;poll <question> - yes/no poll. lasts 30 seconds.
;roll [number of sides] - rolls an n-sided die (defaults to 6-sided)
;server - displays information about the server
;set <this> <that> - sets this to that
;text_benh [message] - sends an SMS to benh
;time [@user] - looks up times in different time zones. you can save a preferred city.
;unset <thing to remove> - remove a definition
;weather [@user|city search] - get current weather

-------------------------------------------------------------
;help [command] - get more information about a specific command
commands are case-insensitive.

[] denotes an optional argument.
<> denotes a required argument.
|  denotes available options.