NadekoBot/README.md

196 lines
13 KiB
Markdown
Raw Normal View History

2015-12-05 10:13:23 +00:00
# NadekoBot
2016-01-29 14:55:53 +00:00
**Scroll down for a list of commands**
2016-01-22 08:16:10 +00:00
Nadeko Discord chatbot written in C# using Discord.net library.
2016-01-22 08:15:52 +00:00
You might want to join my discord server where i can provide help etc. https://discord.gg/0ehQwTK2RBhxEi0X
2015-12-05 11:02:45 +00:00
2016-01-08 08:36:02 +00:00
##This section will guide you through how to setup NadekoBot from the source code
#### If you want to semi-easily setup the bot, go to [releases](https://github.com/Kwoth/NadekoBot/releases)
2015-12-05 11:02:45 +00:00
In your bin/debug folder (or next to your exe), you must have a file called 'credentials.json' in which you will store all the necessary data to make the bot know who the owner is, where to store data, etc.
**This is how the credentials.json should look like:**
```json
{
"Username":"bot_email",
"BotMention":"<@bot_id>",
"Password":"bot_password",
"GoogleAPIKey":"google_api_key",
"OwnerID":123123123123,
"ParseID":"parse_app_id",
"ParseKey":"parse_api_key",
"TrelloAppKey": "your_trello_app_key (optional)",
"ForwardMessages": true,
"OsuApiKey": "your_osu_key (optional)",
"SoundCloudClientID": "your_soundcloud_key (optional)",
"MashapeKey": "your_mashape_key (optional)",
2015-12-05 11:02:45 +00:00
}
```
##### You can omit:
- googleAPIKey if you don't want music
- TrelloAppKey if you don't need trello notifications
2016-01-22 08:22:02 +00:00
- ForwardMessages if you don't want bot PM messages to be redirected to you
2016-01-11 19:10:47 +00:00
```json
{
"Username":"bot_email",
"BotMention":"<@bot_id>",
"Password":"bot_password",
"OwnerID":123123123123,
2016-01-25 14:16:31 +00:00
"ParseID":"parse_app_id",
"ParseKey":"parse_api_key",
2016-01-11 19:10:47 +00:00
}
```
2016-01-11 18:39:55 +00:00
- BotMention(bot\_id) and OwnerID are **NOT** names of the owner and the bot. If you do not know the id of your bot, put 2 random numbers in those fields, run the bot and do `.uid @MyBotName` - that will give you your bot\_id, do the same for yourself `.uid @MyName` and copy the numbers in their respective fields.
2016-01-24 08:21:19 +00:00
- For google api key, you need to enable URL shortner and Youtube video search in the [dev console](https://console.developers.google.com/).
- For **ParseID** and **ParseKey**, you need to register on http://www.parse.com, get those values and create a **DATA** app with these 3 classes: `'CommandsRan', 'Requests' and 'Stats'` in order to make the logging work http://i.imgur.com/bXsL19z.png.
2016-02-05 22:20:19 +00:00
- For Osu Api key you need an Osu account. Login then go to this link https://osu.ppy.sh/p/api, create a new app and give it any name you like. App url is not important. After creating your app, you will get your Api Key which you need to paste into your credentials.json.
- For the Soundcloud Api key you need a Soundcloud account. You need to create a new app on http://soundcloud.com/you/apps/new and after that go here http://soundcloud.com/you/apps click on the name of your created your app and copy the Client ID. Paste it into credentials.json.
- For Mashape Api Key you need to create an account on their api marketplace here https://market.mashape.com/. After that you need to go to market.mashape.com/YOURNAMEHERE/applications/default-application and press GET THE KEYS in the right top corner copy paste it into your credentials.json and you are ready to race!
2016-01-12 16:28:51 +00:00
- If you want to have music, you need to download FFMPEG from this link http://ffmpeg.zeranoe.com/builds/ (static build version) and add ffmpeg/bin folder to your PATH environment variable. You do that by opening explorer -> right click 'This PC' -> properties -> advanced system settings -> In the top part, there is a PATH field, add `;` to the end and then your ffmpeg install location /bin (for example ;C:\ffmpeg-5.6.7\bin) and save. Open command prompt and type ffmpeg to see if you added it correctly. If it says "command not found" then you made a mistake somewhere. There are a lot of guides on the internet on how to add stuff to your PATH, check them out if you are stuck.
2015-12-05 11:02:45 +00:00
2016-01-28 09:21:44 +00:00
You should **remove** Discord.Net projects from your solution, and use add reference to the Discord.NET DLLs in your bin/debug.
2015-12-05 11:02:45 +00:00
**You are all set.**
Fire up visual studio, wait for it to resolve dependencies and start NadekoBot.
Enjoy
2015-12-05 11:25:40 +00:00
2016-01-29 14:55:53 +00:00
##List of commands
2016-02-05 13:40:01 +00:00
(may be incomplete) last updated: 5.2.2016
2016-01-05 10:02:20 +00:00
Official repo: **github.com/Kwoth/NadekoBot/**
### Administration
2016-01-20 18:00:43 +00:00
Command and aliases | Description | Usage
2016-01-05 10:02:20 +00:00
----------------|--------------|-------
2016-02-05 13:40:01 +00:00
`-h`, `-help`, `@BotName help`, `@BotName h`, `~h` | Help command
2016-01-05 10:02:20 +00:00
`-hgit` | Help command stylized for github readme
2016-02-05 13:40:01 +00:00
`.greet` | Enables or Disables anouncements on the current channel when someone joins the server.
`.greetmsg` | Sets a new announce message. Type %user% if you want to mention the new member. | .greetmsg Welcome to the server, %user%.
`.bye` | Enables or Disables anouncements on the current channel when someone leaves the server.
`.byemsg` | Sets a new announce leave message. Type %user% if you want to mention the new member. | .byemsg %user% has left the server.
2016-01-20 18:00:43 +00:00
`.sr`, `.setrole` | Sets a role for a given user. | .sr @User Guest
`.rr`, `.removerole` | Removes a role from a given user. | .rr @User Admin
`.r`, `.role`, `.cr` | Creates a role with a given name, and color. | .r AwesomeRole Orange
2016-02-05 13:41:46 +00:00
`.rolecolor`, `.rc` | Set a role's color to the hex or 0-255 color value provided. | **Usage*: .color Admin 255 200 100 or .color Admin ffba55
2016-02-05 13:40:01 +00:00
`.roles` | List all roles on this server
2016-01-20 18:00:43 +00:00
`.b`, `.ban` | Bans a mentioned user
`.ub`, `.unban` | Unbans a mentioned user
`.k`, `.kick` | Kicks a mentioned user.
2016-02-05 13:40:01 +00:00
`.mute` | Mutes mentioned user or users
`.unmute` | Unmutes mentioned user or users
`.deafen`, `.deaf` | Deafens mentioned user or users
`.undeafen`, `.undeaf` | Undeafens mentioned user or users
2016-01-05 10:02:20 +00:00
`.rvch` | Removes a voice channel with a given name.
2016-01-20 18:00:43 +00:00
`.vch`, `.cvch` | Creates a new voice channel with a given name.
`.rch`, `.rtch` | Removes a text channel with a given name.
`.ch`, `.tch` | Creates a new text channel with a given name.
`.st`, `.settopic` | Sets a topic on the current channel.
`.uid`, `.userid` | Shows user id
`.cid`, `.channelid` | Shows current channel id
`.sid`, `.serverid` | Shows current server id
2016-01-05 10:02:20 +00:00
`.stats` | Shows some basic stats for nadeko
2016-01-20 17:53:18 +00:00
`.leaveall` | Nadeko leaves all servers
2016-01-11 18:57:05 +00:00
`.prune` | Prunes a number of messages from the current channel. | .prune 50
2016-02-05 13:40:01 +00:00
`.die`, `.graceful` | Works only for the owner. Shuts the bot down and notifies users about the restart.
2016-01-11 18:57:05 +00:00
`.clr` | Clears some of nadeko's messages from the current channel.
`.newname` | Give the bot a new name.
2016-02-05 13:40:01 +00:00
`.setgame` | Sets the bots game.
2016-01-22 08:15:52 +00:00
`.checkmyperms` | Checks your userspecific permissions on this channel.
2016-02-05 13:40:01 +00:00
`.commsuser` | Sets a user for through-bot communication. Only works if server is set. Resets commschannel.**Owner only**.
2016-01-22 08:15:52 +00:00
`.commsserver` | Sets a server for through-bot communication.**Owner only**.
2016-02-05 13:40:01 +00:00
`.commschannel` | Sets a channel for through-bot communication. Only works if server is set. Resets commsuser.**Owner only**.
2016-01-22 08:15:52 +00:00
`.send` | Send a message to someone on a different server through the bot.**Owner only.**
2016-02-05 13:41:46 +00:00
`.menrole`, `.mentionrole` | Mentions every person from the provided role or roles (separated by a comma) on this server. Requires you to have mention @everyone permission.
2016-01-05 10:02:20 +00:00
### Conversations
2016-01-20 18:00:43 +00:00
Command and aliases | Description | Usage
2016-01-05 10:02:20 +00:00
----------------|--------------|-------
`\o\` | Nadeko replies with /o/
`/o/` | Nadeko replies with \o\
2016-01-20 18:00:43 +00:00
`@BotName copyme`, `@BotName cm` | Nadeko starts copying everything you say. Disable with cs
`@BotName cs`, `@BotName copystop` | Nadeko stops copying you
2016-02-05 13:40:01 +00:00
`@BotName req`, `@BotName request` | Requests a feature for nadeko. | @NadekoBot req new_feature
`@BotName lr` | PMs the user all current nadeko requests.
`@BotName dr` | Deletes a request. Only owner is able to do this.
`@BotName rr` | Resolves a request. Only owner is able to do this.
2016-01-11 18:57:05 +00:00
`@BotName uptime` | Shows how long is Nadeko running for.
2016-01-05 10:02:20 +00:00
`@BotName die` | Works only for the owner. Shuts the bot down.
2016-01-11 18:57:05 +00:00
`@BotName randserver` | Generates an invite to a random server and prints some stats.
`@BotName do you love me` | Replies with positive answer only to the bot owner.
2016-01-05 10:02:20 +00:00
`@BotName how are you` | Replies positive only if bot owner is online.
`@BotName insult` | Only works for owner. Insults @X person. | @NadekoBot insult @X.
`@BotName praise` | Only works for owner. Praises @X person. | @NadekoBot praise @X.
2016-02-05 13:40:01 +00:00
`@BotName pat` | Pat someone ^_^
`@BotName cry` | Tell Nadeko to cry. You are a heartless monster if you use this command.
2016-01-05 10:02:20 +00:00
`@BotName are you real` | Useless.
2016-01-20 18:00:43 +00:00
`@BotName are you there`, `@BotName !`, `@BotName ?` | Checks if nadeko is operational.
2016-01-05 10:02:20 +00:00
`@BotName draw` | Nadeko instructs you to type $draw. Gambling functions start with $
`@BotName fire` | Shows a unicode fire message. Optional parameter [x] tells her how many times to repeat the fire. | @NadekoBot fire [x]
2016-02-05 13:40:01 +00:00
`@BotName rip` | Shows a grave image of someone with a start year | @NadekoBot rip @Someone 2000
2016-01-11 18:57:05 +00:00
`@BotName j` | Joins a server using a code.
2016-01-05 10:02:20 +00:00
`@BotName slm` | Shows the message where you were last mentioned in this channel (checks last 10k messages)
`@BotName bb` | Says bye to someone. | @NadekoBot bb @X
`@BotName call` | Useless. Writes calling @X to chat. | @NadekoBot call @X
`@BotName hide` | Hides nadeko in plain sight!11!!
`@BotName unhide` | Unhides nadeko in plain sight!1!!1
2016-02-05 13:40:01 +00:00
`@BotName dump` | Dumps all of the invites it can to dump.txt.** Owner Only.**
`@BotName ab` | Try to get 'abalabahaha'
2016-01-20 18:00:43 +00:00
`@BotName av`, `@BotName avatar` | Shows a mentioned person's avatar. | ~av @X
2016-01-05 10:02:20 +00:00
### Gambling
2016-01-20 18:00:43 +00:00
Command and aliases | Description | Usage
2016-01-05 10:02:20 +00:00
----------------|--------------|-------
`$draw` | Draws a card from the deck.If you supply number [x], she draws up to 5 cards from the deck. | $draw [x]
2016-02-05 13:40:01 +00:00
`$shuffle`, `$reshuffle` | Reshuffles all cards back into the deck.
`$flip` | Flips coin(s) - heads or tails, and shows an image. | `$flip` or `$flip 3`
2016-01-05 10:02:20 +00:00
`$roll` | Rolls 2 dice from 0-10. If you supply a number [x] it rolls up to 30 normal dice. | $roll [x]
2016-02-05 13:40:01 +00:00
`$nroll` | Rolls in a given range. | `$nroll 5` (rolls 0-5) or `$nroll 5-15`
`$raffle` | Prints a name and ID of a random user from the online list from the (optional) role.
2016-01-05 10:02:20 +00:00
### Games
2016-01-20 18:00:43 +00:00
Command and aliases | Description | Usage
2016-01-05 10:02:20 +00:00
----------------|--------------|-------
2016-01-20 18:00:43 +00:00
`t`, `-t` | Starts a game of trivia.
`tl`, `-tl`, `tlb`, `-tlb` | Shows a current trivia leaderboard.
`tq`, `-tq` | Quits current trivia after current question.
2016-02-05 13:40:01 +00:00
`typestart` | Starts a typing contest.
`typestop` | Stops a typing contest on the current channel.
`typeadd` | Adds a new article to the typing contest. Owner only.
2016-01-05 10:02:20 +00:00
`>` | Attack a person. Supported attacks: 'splash', 'strike', 'burn', 'surge'. | > strike @User
`poketype` | Gets the users element type. Use this to do more damage with strike
### Music
2016-01-20 18:00:43 +00:00
Command and aliases | Description | Usage
2016-01-05 10:02:20 +00:00
----------------|--------------|-------
2016-01-20 18:00:43 +00:00
`!m n`, `!m next` | Goes to the next song in the queue.
`!m s`, `!m stop` | Completely stops the music and unbinds the bot from the channel and cleanes up files.
`!m p`, `!m pause` | Pauses the song
2016-02-05 13:40:01 +00:00
`!m q`, `!m yq` | Queue a song using keywords or link. Bot will join your voice channel. **You must be in a voice channel**. | `!m q Dream Of Venice`
2016-01-20 18:00:43 +00:00
`!m lq`, `!m ls`, `!m lp` | Lists up to 10 currently queued songs.
2016-02-05 13:40:01 +00:00
`!m np`, `!m playing` | Shows the song currently playing.
`!m vol` | Sets the music volume 0-150%
`!m min`, `!m mute` | Sets the music volume to 0%
`!m max` | Sets the music volume to 100% (real max is actually 150%).
`!m half` | Sets the music volume to 50%.
2016-01-05 10:02:20 +00:00
`!m sh` | Shuffles the current playlist.
2016-02-05 13:40:01 +00:00
`!m setgame` | Sets the game of the bot to the number of songs playing.**Owner only**
`!m pl` | Queues up to 25 songs from a youtube playlist specified by a link, or keywords.
`!m debug` | Writes some music data to console. **BOT OWNER ONLY**
2016-01-05 10:02:20 +00:00
### Searches
2016-01-20 18:00:43 +00:00
Command and aliases | Description | Usage
2016-01-05 10:02:20 +00:00
----------------|--------------|-------
2016-02-05 13:40:01 +00:00
`~yt` | Searches youtubes and shows the first result
2016-01-20 18:00:43 +00:00
`~ani`, `~anime`, `~aq` | Queries anilist for an anime and shows the first result.
`~mang`, `~manga`, `~mq` | Queries anilist for a manga and shows the first result.
2016-01-11 18:57:05 +00:00
`~randomcat` | Shows a random cat image.
2016-02-05 13:40:01 +00:00
`~i`, `img` | Pulls a first image using a search parameter. | @NadekoBot img Multiword_search_parameter
`~ir`, `imgrandom` | Pulls a random image using a search parameter. | @NadekoBot img Multiword_search_parameter
`~hentai` | Shows a random NSFW hentai image from gelbooru and danbooru with a given tag. Tag is optional but preffered. | ~hentai yuri
`~danbooru` | Shows a random hentai image from danbooru with a given tag. Tag is optional but preffered. | ~hentai yuri
`~gelbooru` | Shows a random hentai image from gelbooru with a given tag. Tag is optional but preffered. | ~hentai yuri
`~cp` | We all know where this will lead you to.
2016-01-22 08:15:52 +00:00
`lmgtfy` | Google something for an idiot.
2016-02-05 13:40:01 +00:00
`~hs` | Searches for a Hearthstone card and shows its image.