animal racing fixes, #476 , commandlist updated

This commit is contained in:
Kwoth 2016-07-29 13:06:24 +02:00
parent ef4e146138
commit 994d514353
2 changed files with 136 additions and 131 deletions

View File

@ -1,14 +1,13 @@
using NadekoBot.Classes; using Discord;
using Discord.Commands;
using NadekoBot.Classes;
using NadekoBot.Extensions;
using System; using System;
using System.Collections.Concurrent;
using System.Collections.Generic; using System.Collections.Generic;
using System.Linq; using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Discord.Commands;
using System.Collections.Concurrent;
using Discord;
using NadekoBot.Extensions;
using System.Threading; using System.Threading;
using System.Threading.Tasks;
namespace NadekoBot.Modules.Gambling.Commands namespace NadekoBot.Modules.Gambling.Commands
{ {
@ -24,7 +23,8 @@ namespace NadekoBot.Modules.Gambling.Commands
{ {
cgb.CreateCommand(Prefix + "race") cgb.CreateCommand(Prefix + "race")
.Description($"Starts a new animal race. | `{Prefix}race`") .Description($"Starts a new animal race. | `{Prefix}race`")
.Do(e => { .Do(e =>
{
var ar = new AnimalRace(e.Server.Id, e.Channel); var ar = new AnimalRace(e.Server.Id, e.Channel);
if (ar.Fail) if (ar.Fail)
{ {
@ -37,7 +37,8 @@ namespace NadekoBot.Modules.Gambling.Commands
.Alias(Prefix + "jr") .Alias(Prefix + "jr")
.Description($"Joins a new race. You can specify an amount of flowers for betting (optional). You will get YourBet*(participants-1) back if you win. | `{Prefix}jr` or `{Prefix}jr 5`") .Description($"Joins a new race. You can specify an amount of flowers for betting (optional). You will get YourBet*(participants-1) back if you win. | `{Prefix}jr` or `{Prefix}jr 5`")
.Parameter("amount", ParameterType.Optional) .Parameter("amount", ParameterType.Optional)
.Do(async e => { .Do(async e =>
{
int amount; int amount;
if (!int.TryParse(e.GetArg("amount"), out amount) || amount < 0) if (!int.TryParse(e.GetArg("amount"), out amount) || amount < 0)
@ -55,11 +56,12 @@ namespace NadekoBot.Modules.Gambling.Commands
await FlowersHandler.RemoveFlowers(e.User, "BetRace", (int)amount, true).ConfigureAwait(false); await FlowersHandler.RemoveFlowers(e.User, "BetRace", (int)amount, true).ConfigureAwait(false);
AnimalRace ar; AnimalRace ar;
if (!AnimalRaces.TryGetValue(e.Server.Id, out ar)) { if (!AnimalRaces.TryGetValue(e.Server.Id, out ar))
{
await e.Channel.SendMessage("No race exists on this server"); await e.Channel.SendMessage("No race exists on this server");
} }
await ar.JoinRace(e.User, amount); await ar.JoinRace(e.User, amount);
}); });
} }
@ -93,7 +95,7 @@ namespace NadekoBot.Modules.Gambling.Commands
{ {
try try
{ {
await raceChannel.SendMessage($"🏁`Race is starting in 20 seconds or when the room is full. Type $jr to join the race.`"); await raceChannel.SendMessage($"🏁`Race is starting in 20 seconds or when the room is full. Type {NadekoBot.Config.CommandPrefixes.Gambling}jr to join the race.`");
var t = await Task.WhenAny(Task.Delay(20000, token), fullgame); var t = await Task.WhenAny(Task.Delay(20000, token), fullgame);
Started = true; Started = true;
cancelSource.Cancel(); cancelSource.Cancel();
@ -103,7 +105,7 @@ namespace NadekoBot.Modules.Gambling.Commands
} }
else if (participants.Count > 1) else if (participants.Count > 1)
{ {
await raceChannel.SendMessage("🏁`Game starting with " + participants.Count + " praticipants.`"); await raceChannel.SendMessage("🏁`Game starting with " + participants.Count + " participants.`");
} }
else else
{ {
@ -127,7 +129,8 @@ namespace NadekoBot.Modules.Gambling.Commands
AnimalRaces.TryRemove(serverId, out throwaway); AnimalRaces.TryRemove(serverId, out throwaway);
} }
private async Task StartRace() { private async Task StartRace()
{
var rng = new Random(); var rng = new Random();
Participant winner = null; Participant winner = null;
Message msg = null; Message msg = null;
@ -163,14 +166,14 @@ namespace NadekoBot.Modules.Gambling.Commands
|🏁🏁🏁🏁🏁🏁🏁🏁🏁🏁🏁🏁🏁🏁🏁🔚|"; |🏁🏁🏁🏁🏁🏁🏁🏁🏁🏁🏁🏁🏁🏁🏁🔚|";
if (msg == null || messagesSinceGameStarted >= 10) // also resend the message if channel was spammed if (msg == null || messagesSinceGameStarted >= 10) // also resend the message if channel was spammed
{ {
if(msg != null) if (msg != null)
try { await msg.Delete(); } catch { } try { await msg.Delete(); } catch { }
msg = await raceChannel.SendMessage(text); msg = await raceChannel.SendMessage(text);
messagesSinceGameStarted = 0; messagesSinceGameStarted = 0;
} }
else else
await msg.Edit(text); await msg.Edit(text);
await Task.Delay(2500); await Task.Delay(2500);
} }
} }
@ -199,10 +202,11 @@ namespace NadekoBot.Modules.Gambling.Commands
messagesSinceGameStarted++; messagesSinceGameStarted++;
} }
private async Task CheckForFullGameAsync(CancellationToken cancelToken) { private async Task CheckForFullGameAsync(CancellationToken cancelToken)
{
while (animals.Count > 0) while (animals.Count > 0)
{ {
await Task.Delay(100,cancelToken); await Task.Delay(100, cancelToken);
} }
} }
@ -257,8 +261,8 @@ namespace NadekoBot.Modules.Gambling.Commands
public override bool Equals(object obj) public override bool Equals(object obj)
{ {
var p = obj as Participant; var p = obj as Participant;
return p == null? return p == null ?
false: false :
p.User == User; p.User == User;
} }
@ -279,7 +283,8 @@ namespace NadekoBot.Modules.Gambling.Commands
{ {
return str + "`3rd`"; return str + "`3rd`";
} }
else { else
{
return str + $"`{Place}th`"; return str + $"`{Place}th`";
} }

View File

@ -3,61 +3,61 @@
######or paypal: `nadekodiscordbot@gmail.com` ######or paypal: `nadekodiscordbot@gmail.com`
#NadekoBot List Of Commands #NadekoBot List Of Commands
Version: `NadekoBot v0.9.6053.28429` Version: `NadekoBot v0.9.6054.4837`
### Help ### Help
Command and aliases | Description | Usage Command and aliases | Description | Usage
----------------|--------------|------- ----------------|--------------|-------
`-h`, `-help`, `@BotName help`, `@BotName h`, `~h` | Either shows a help for a single command, or PMs you help link if no arguments are specified. | '-h !m q' or just '-h' `-h`, `-help`, `@BotName help`, `@BotName h`, `~h` | Either shows a help for a single command, or PMs you help link if no arguments are specified. | `-h !m q` or just `-h`
`-hgit` | Generates the commandlist.md file. **Bot Owner Only!** `-hgit` | Generates the commandlist.md file. **Bot Owner Only!** | `-hgit`
`-readme`, `-guide` | Sends a readme and a guide links to the channel. `-readme`, `-guide` | Sends a readme and a guide links to the channel. | `-readme` or `-guide`
`-donate`, `~donate` | Instructions for helping the project! `-donate`, `~donate` | Instructions for helping the project! | `{Prefix}donate` or `~donate`
`-modules`, `.modules` | List all bot modules. `-modules`, `.modules` | List all bot modules. | `{Prefix}modules` or `.modules`
`-commands`, `.commands` | List all of the bot's commands from a certain module. `-commands`, `.commands` | List all of the bot's commands from a certain module. | `{Prefix}commands` or `.commands`
### Administration ### Administration
Command and aliases | Description | Usage Command and aliases | Description | Usage
----------------|--------------|------- ----------------|--------------|-------
`.grdel` | Toggles automatic deletion of greet and bye messages. `.grdel` | Toggles automatic deletion of greet and bye messages. | `.grdel`
`.greet` | Toggles anouncements on the current channel when someone joins the server. `.greet` | Toggles anouncements on the current channel when someone joins the server. | `.greet`
`.greetmsg` | Sets a new join announcement message. Type %user% if you want to mention the new member. Using it with no message will show the current greet message. | .greetmsg Welcome to the server, %user%. `.greetmsg` | Sets a new join announcement message. Type %user% if you want to mention the new member. Using it with no message will show the current greet message. | `.greetmsg Welcome to the server, %user%.`
`.bye` | Toggles anouncements on the current channel when someone leaves the server. `.bye` | Toggles anouncements on the current channel when someone leaves the server. | `.bye`
`.byemsg` | Sets a new leave announcement message. Type %user% if you want to mention the new member. Using it with no message will show the current bye message. | .byemsg %user% has left the server. `.byemsg` | Sets a new leave announcement message. Type %user% if you want to mention the new member. Using it with no message will show the current bye message. | `.byemsg %user% has left the server.`
`.byepm` | Toggles whether the good bye messages will be sent in a PM or in the text channel. `.byepm` | Toggles whether the good bye messages will be sent in a PM or in the text channel. | `.byepm`
`.greetpm` | Toggles whether the greet messages will be sent in a PM or in the text channel. `.greetpm` | Toggles whether the greet messages will be sent in a PM or in the text channel. | `.greetpm`
`.spmom` | Toggles whether mentions of other offline users on your server will send a pm to them. `.spmom` | Toggles whether mentions of other offline users on your server will send a pm to them. | `.spmom`
`.logserver` | Toggles logging in this channel. Logs every message sent/deleted/edited on the server. **Bot Owner Only!** `.logserver` | Toggles logging in this channel. Logs every message sent/deleted/edited on the server. **Bot Owner Only!** | `.logserver`
`.logignore` | Toggles whether the .logserver command ignores this channel. Useful if you have hidden admin channel and public log channel. `.logignore` | Toggles whether the .logserver command ignores this channel. Useful if you have hidden admin channel and public log channel. | `.logignore`
`.userpresence` | Starts logging to this channel when someone from the server goes online/offline/idle. `.userpresence` | Starts logging to this channel when someone from the server goes online/offline/idle. | `.userpresence`
`.voicepresence` | Toggles logging to this channel whenever someone joins or leaves a voice channel you are in right now. `.voicepresence` | Toggles logging to this channel whenever someone joins or leaves a voice channel you are in right now. | `{Prefix}voicerpresence`
`.repeatinvoke`, `.repinv` | Immediately shows the repeat message and restarts the timer. `.repeatinvoke`, `.repinv` | Immediately shows the repeat message and restarts the timer. | `{Prefix}repinv`
`.repeat` | Repeat a message every X minutes. If no parameters are specified, repeat is disabled. Requires manage messages. | `.repeat 5 Hello there` `.repeat` | Repeat a message every X minutes. If no parameters are specified, repeat is disabled. Requires manage messages. | `.repeat 5 Hello there`
`.rotateplaying`, `.ropl` | Toggles rotation of playing status of the dynamic strings you specified earlier. `.rotateplaying`, `.ropl` | Toggles rotation of playing status of the dynamic strings you specified earlier. | `.ropl`
`.addplaying`, `.adpl` | Adds a specified string to the list of playing strings to rotate. Supported placeholders: %servers%, %users%, %playing%, %queued%, %trivia% `.addplaying`, `.adpl` | Adds a specified string to the list of playing strings to rotate. Supported placeholders: %servers%, %users%, %playing%, %queued%, %trivia% | `.adpl`
`.listplaying`, `.lipl` | Lists all playing statuses with their corresponding number. `.listplaying`, `.lipl` | Lists all playing statuses with their corresponding number. | `.lipl`
`.removeplaying`, `.repl`, `.rmpl` | Removes a playing string on a given number. `.removeplaying`, `.repl`, `.rmpl` | Removes a playing string on a given number. | `.rmpl`
`.slowmode` | Toggles slow mode. When ON, users will be able to send only 1 message every 5 seconds. `.slowmode` | Toggles slow mode. When ON, users will be able to send only 1 message every 5 seconds. | `.slowmode`
`.cleanv+t`, `.cv+t` | Deletes all text channels ending in `-voice` for which voicechannels are not found. **Use at your own risk.** `.cleanv+t`, `.cv+t` | Deletes all text channels ending in `-voice` for which voicechannels are not found. **Use at your own risk.** | `.cleanv+t`
`.voice+text`, `.v+t` | Creates a text channel for each voice channel only users in that voice channel can see.If you are server owner, keep in mind you will see them all the time regardless. `.voice+text`, `.v+t` | Creates a text channel for each voice channel only users in that voice channel can see.If you are server owner, keep in mind you will see them all the time regardless. | `.voice+text`
`.scsc` | Starts an instance of cross server channel. You will get a token as a DMthat other people will use to tune in to the same instance `.scsc` | Starts an instance of cross server channel. You will get a token as a DM that other people will use to tune in to the same instance. | `.scsc`
`.jcsc` | Joins current channel to an instance of cross server channel using the token. `.jcsc` | Joins current channel to an instance of cross server channel using the token. | `.jcsc`
`.lcsc` | Leaves Cross server channel instance from this channel `.lcsc` | Leaves Cross server channel instance from this channel. | `.lcsc`
`.asar` | Adds a role, or list of roles separated by whitespace(use quotations for multiword roles) to the list of self-assignable roles. | .asar Gamer `.asar` | Adds a role, or list of roles separated by whitespace(use quotations for multiword roles) to the list of self-assignable roles. | .asar Gamer
`.rsar` | Removes a specified role from the list of self-assignable roles. `.rsar` | Removes a specified role from the list of self-assignable roles. | `.rsar`
`.lsar` | Lists all self-assignable roles. `.lsar` | Lists all self-assignable roles. | `.lsar`
`.togglexclsar`, `.tesar` | toggle whether the self-assigned roles should be exclusive `.togglexclsar`, `.tesar` | toggle whether the self-assigned roles should be exclusive | `.tesar`
`.iam` | Adds a role to you that you choose. Role must be on a list of self-assignable roles. | .iam Gamer `.iam` | Adds a role to you that you choose. Role must be on a list of self-assignable roles. | .iam Gamer
`.iamnot`, `.iamn` | Removes a role to you that you choose. Role must be on a list of self-assignable roles. | .iamn Gamer `.iamnot`, `.iamn` | Removes a role to you that you choose. Role must be on a list of self-assignable roles. | .iamn Gamer
`.addcustreact`, `.acr` | Add a custom reaction. Guide here: <https://github.com/Kwoth/NadekoBot/wiki/Custom-Reactions> **Bot Owner Only!** | .acr "hello" I love saying hello to %user% `.addcustreact`, `.acr` | Add a custom reaction. Guide here: <https://github.com/Kwoth/NadekoBot/wiki/Custom-Reactions> **Bot Owner Only!** | `.acr "hello" I love saying hello to %user%`
`.listcustreact`, `.lcr` | Lists custom reactions (paginated with 30 commands per page). Use 'all' instead of page number to get all custom reactions DM-ed to you. | .lcr 1 `.listcustreact`, `.lcr` | Lists custom reactions (paginated with 30 commands per page). Use 'all' instead of page number to get all custom reactions DM-ed to you. | `.lcr 1`
`.showcustreact`, `.scr` | Shows all possible responses from a single custom reaction. | .scr %mention% bb `.showcustreact`, `.scr` | Shows all possible responses from a single custom reaction. | `.scr %mention% bb`
`.editcustreact`, `.ecr` | Edits a custom reaction, arguments are custom reactions name, index to change, and a (multiword) message **Bot Owner Only** | `.ecr "%mention% disguise" 2 Test 123` `.editcustreact`, `.ecr` | Edits a custom reaction, arguments are custom reactions name, index to change, and a (multiword) message **Bot Owner Only** | `.ecr "%mention% disguise" 2 Test 123`
`.delcustreact`, `.dcr` | Deletes a custom reaction with given name (and index) `.delcustreact`, `.dcr` | Deletes a custom reaction with given name (and index). | `.dcr index`
`.autoassignrole`, `.aar` | Automaticaly assigns a specified role to every user who joins the server. Type `.aar` to disable, `.aar Role Name` to enable `.autoassignrole`, `.aar` | Automaticaly assigns a specified role to every user who joins the server. Type `.aar` to disable, `.aar Role Name` to enable
`.leave` | Makes Nadeko leave the server. Either name or id required. | `.leave 123123123331` `.leave` | Makes Nadeko leave the server. Either name or id required. | `.leave 123123123331`
`.listincidents`, `.lin` | List all UNREAD incidents and flags them as read. `.listincidents`, `.lin` | List all UNREAD incidents and flags them as read. | `.lin`
`.listallincidents`, `.lain` | Sends you a file containing all incidents and flags them as read. `.listallincidents`, `.lain` | Sends you a file containing all incidents and flags them as read. | `.lain`
`.delmsgoncmd` | Toggles the automatic deletion of user's successful command message to prevent chat flood. Server Manager Only. `.delmsgoncmd` | Toggles the automatic deletion of user's successful command message to prevent chat flood. Server Manager Only. | `.delmsgoncmd`
`.restart` | Restarts the bot. Might not work. **Bot Owner Only** `.restart` | Restarts the bot. Might not work. **Bot Owner Only** | `.restart`
`.setrole`, `.sr` | Sets a role for a given user. | `.sr @User Guest` `.setrole`, `.sr` | Sets a role for a given user. | `.sr @User Guest`
`.removerole`, `.rr` | Removes a role from a given user. | `.rr @User Admin` `.removerole`, `.rr` | Removes a role from a given user. | `.rr @User Admin`
`.renamerole`, `.renr` | Renames a role. Role you are renaming must be lower than bot's highest role. | `.renr "First role" SecondRole` `.renamerole`, `.renr` | Renames a role. Role you are renaming must be lower than bot's highest role. | `.renr "First role" SecondRole`
@ -77,15 +77,15 @@ Command and aliases | Description | Usage
`.creatxtchanl`, `.ctch` | Creates a new text channel with a given name. | `.ctch TextChannelName` `.creatxtchanl`, `.ctch` | Creates a new text channel with a given name. | `.ctch TextChannelName`
`.settopic`, `.st` | Sets a topic on the current channel. | `.st My new topic` `.settopic`, `.st` | Sets a topic on the current channel. | `.st My new topic`
`.setchanlname`, `.schn` | Changed the name of the current channel.| `.schn NewName` `.setchanlname`, `.schn` | Changed the name of the current channel.| `.schn NewName`
`.heap` | Shows allocated memory - **Bot Owner Only!** `.heap` | Shows allocated memory - **Bot Owner Only!** | `.heap`
`.prune`, `.clr` | `.prune` removes all nadeko's messages in the last 100 messages.`.prune X` removes last X messages from the channel (up to 100)`.prune @Someone` removes all Someone's messages in the last 100 messages.`.prune @Someone X` removes last X 'Someone's' messages in the channel. | `.prune` or `.prune 5` or `.prune @Someone` or `.prune @Someone X` `.prune`, `.clr` | `.prune` removes all nadeko's messages in the last 100 messages.`.prune X` removes last X messages from the channel (up to 100)`.prune @Someone` removes all Someone's messages in the last 100 messages.`.prune @Someone X` removes last X 'Someone's' messages in the channel. | `.prune` or `.prune 5` or `.prune @Someone` or `.prune @Someone X`
`.die` | Shuts the bot down and notifies users about the restart. **Bot Owner Only!** `.die` | Shuts the bot down and notifies users about the restart. **Bot Owner Only!** | `.die`
`.setname`, `.newnm` | Give the bot a new name. **Bot Owner Only!** | .newnm BotName `.setname`, `.newnm` | Give the bot a new name. **Bot Owner Only!** | .newnm BotName
`.newavatar`, `.setavatar` | Sets a new avatar image for the NadekoBot. Argument is a direct link to an image. **Bot Owner Only!** | `.setavatar https://i.ytimg.com/vi/WDudkR1eTMM/maxresdefault.jpg` `.newavatar`, `.setavatar` | Sets a new avatar image for the NadekoBot. Argument is a direct link to an image. **Bot Owner Only!** | `.setavatar https://i.ytimg.com/vi/WDudkR1eTMM/maxresdefault.jpg`
`.setgame` | Sets the bots game. **Bot Owner Only!** | `.setgame Playing with kwoth` `.setgame` | Sets the bots game. **Bot Owner Only!** | `.setgame Playing with kwoth`
`.send` | Send a message to someone on a different server through the bot. **Bot Owner Only!** | `.send serverid|u:user_id Send this to a user!` or `.send serverid|c:channel_id Send this to a channel!` `.send` | Send a message to someone on a different server through the bot. **Bot Owner Only!** | `.send serverid|u:user_id Send this to a user!` or `.send serverid|c:channel_id Send this to a channel!`
`.mentionrole`, `.menro` | Mentions every person from the provided role or roles (separated by a ',') on this server. Requires you to have mention everyone permission. | `.menro RoleName` `.mentionrole`, `.menro` | Mentions every person from the provided role or roles (separated by a ',') on this server. Requires you to have mention everyone permission. | `.menro RoleName`
`.unstuck` | Clears the message queue. **Bot Owner Only!** `.unstuck` | Clears the message queue. **Bot Owner Only!** | `.unstuck`
`.donators` | List of lovely people who donated to keep this project alive. `.donators` | List of lovely people who donated to keep this project alive.
`.donadd` | Add a donator to the database. | `.donadd Donate Amount` `.donadd` | Add a donator to the database. | `.donadd Donate Amount`
`.announce` | Sends a message to all servers' general channel bot is connected to.**Bot Owner Only!** | `.announce Useless spam` `.announce` | Sends a message to all servers' general channel bot is connected to.**Bot Owner Only!** | `.announce Useless spam`
@ -95,16 +95,16 @@ Command and aliases | Description | Usage
Command and aliases | Description | Usage Command and aliases | Description | Usage
----------------|--------------|------- ----------------|--------------|-------
`.remind` | Sends a message to you or a channel after certain amount of time. First argument is me/here/'channelname'. Second argument is time in a descending order (mo>w>d>h>m) example: 1w5d3h10m. Third argument is a (multiword)message. | `.remind me 1d5h Do something` or `.remind #general Start now!` `.remind` | Sends a message to you or a channel after certain amount of time. First argument is me/here/'channelname'. Second argument is time in a descending order (mo>w>d>h>m) example: 1w5d3h10m. Third argument is a (multiword)message. | `.remind me 1d5h Do something` or `.remind #general Start now!`
`.remindmsg` | Sets message for when the remind is triggered. Available placeholders are %user% - user who ran the command, %message% - Message specified in the remind, %target% - target channel of the remind. **Bot Owner Only!** `.remindmsg` | Sets message for when the remind is triggered. Available placeholders are %user% - user who ran the command, %message% - Message specified in the remind, %target% - target channel of the remind. **Bot Owner Only!** | `.remindmsg do something else`
`.serverinfo`, `.sinfo` | Shows info about the server the bot is on. If no channel is supplied, it defaults to current one. | .sinfo Some Server `.serverinfo`, `.sinfo` | Shows info about the server the bot is on. If no channel is supplied, it defaults to current one. | `.sinfo Some Server`
`.channelinfo`, `.cinfo` | Shows info about the channel. If no channel is supplied, it defaults to current one. | .cinfo #some-channel `.channelinfo`, `.cinfo` | Shows info about the channel. If no channel is supplied, it defaults to current one. | `.cinfo #some-channel`
`.userinfo`, `.uinfo` | Shows info about the user. If no user is supplied, it defaults a user running the command. | .uinfo @SomeUser `.userinfo`, `.uinfo` | Shows info about the user. If no user is supplied, it defaults a user running the command. | `.uinfo @SomeUser`
`.whoplays` | Shows a list of users who are playing the specified game. | `.whoplays Overwatch` `.whoplays` | Shows a list of users who are playing the specified game. | `.whoplays Overwatch`
`.inrole` | Lists every person from the provided role or roles (separated by a ',') on this server. If the list is too long for 1 message, you must have Manage Messages permission. | `.inrole Role` `.inrole` | Lists every person from the provided role or roles (separated by a ',') on this server. If the list is too long for 1 message, you must have Manage Messages permission. | `.inrole Role`
`.checkmyperms` | Checks your userspecific permissions on this channel. `.checkmyperms` | Checks your userspecific permissions on this channel. | `.checkmyperms`
`.stats` | Shows some basic stats for Nadeko. `.stats` | Shows some basic stats for Nadeko. | `.stats`
`.dysyd` | Shows some basic stats for Nadeko. `.dysyd` | Shows some basic stats for Nadeko. | `.dysyd`
`.userid`, `.uid` | Shows user ID. | `.uid` or `.uid "@SomeGuy" `.userid`, `.uid` | Shows user ID. | `.uid` or `.uid "@SomeGuy"`
`.channelid`, `.cid` | Shows current channel ID. | `.cid` `.channelid`, `.cid` | Shows current channel ID. | `.cid`
`.serverid`, `.sid` | Shows current server ID. | `.sid` `.serverid`, `.sid` | Shows current server ID. | `.sid`
`.roles` | List all roles on this server or a single user if specified. `.roles` | List all roles on this server or a single user if specified.
@ -120,12 +120,12 @@ Command and aliases | Description | Usage
`;rmvfilterword`, `;rfw` | Removes the word from the list of filtered words | ;rw poop `;rmvfilterword`, `;rfw` | Removes the word from the list of filtered words | ;rw poop
`;lstfilterwords`, `;lfw` | Shows a list of filtered words | ;lfw `;lstfilterwords`, `;lfw` | Shows a list of filtered words | ;lfw
`;srvrfilterwords`, `;sfw` | Enables or disables automatic deleting of messages containing forbidden words on the server. | ;sfw disable `;srvrfilterwords`, `;sfw` | Enables or disables automatic deleting of messages containing forbidden words on the server. | ;sfw disable
`;permrole`, `;pr` | Sets a role which can change permissions. Or supply no parameters to find out the current one. Default one is 'Nadeko'. `;permrole`, `;pr` | Sets a role which can change permissions. Or supply no parameters to find out the current one. Default one is 'Nadeko'. | `;pr role`
`;rolepermscopy`, `;rpc` | Copies BOT PERMISSIONS (not discord permissions) from one role to another. | `;rpc Some Role ~ Some other role` `;rolepermscopy`, `;rpc` | Copies BOT PERMISSIONS (not discord permissions) from one role to another. | `;rpc Some Role ~ Some other role`
`;chnlpermscopy`, `;cpc` | Copies BOT PERMISSIONS (not discord permissions) from one channel to another. | `;cpc Some Channel ~ Some other channel` `;chnlpermscopy`, `;cpc` | Copies BOT PERMISSIONS (not discord permissions) from one channel to another. | `;cpc Some Channel ~ Some other channel`
`;usrpermscopy`, `;upc` | Copies BOT PERMISSIONS (not discord permissions) from one role to another. | `;upc @SomeUser ~ @SomeOtherUser` `;usrpermscopy`, `;upc` | Copies BOT PERMISSIONS (not discord permissions) from one role to another. | `;upc @SomeUser ~ @SomeOtherUser`
`;verbose`, `;v` | Sets whether to show when a command/module is blocked. | `;verbose true` `;verbose`, `;v` | Sets whether to show when a command/module is blocked. | `;verbose true`
`;srvrperms`, `;sp` | Shows banned permissions for this server. `;srvrperms`, `;sp` | Shows banned permissions for this server. | `;sp`
`;roleperms`, `;rp` | Shows banned permissions for a certain role. No argument means for everyone. | `;rp AwesomeRole` `;roleperms`, `;rp` | Shows banned permissions for a certain role. No argument means for everyone. | `;rp AwesomeRole`
`;chnlperms`, `;cp` | Shows banned permissions for a certain channel. No argument means for this channel. | `;cp #dev` `;chnlperms`, `;cp` | Shows banned permissions for a certain channel. No argument means for this channel. | `;cp #dev`
`;userperms`, `;up` | Shows banned permissions for a certain user. No argument means for yourself. | `;up Kwoth` `;userperms`, `;up` | Shows banned permissions for a certain user. No argument means for yourself. | `;up Kwoth`
@ -158,48 +158,48 @@ Command and aliases | Description | Usage
`...` | Shows a random quote with a specified name. | `... abc` `...` | Shows a random quote with a specified name. | `... abc`
`..qdel`, `..quotedelete` | Deletes all quotes with the specified keyword. You have to either be bot owner or the creator of the quote to delete it. | `..qdel abc` `..qdel`, `..quotedelete` | Deletes all quotes with the specified keyword. You have to either be bot owner or the creator of the quote to delete it. | `..qdel abc`
`@BotName rip` | Shows a grave image of someone with a start year | @NadekoBot rip @Someone 2000 `@BotName rip` | Shows a grave image of someone with a start year | @NadekoBot rip @Someone 2000
`@BotName die` | Works only for the owner. Shuts the bot down. `@BotName die` | Works only for the owner. Shuts the bot down. | `@NadekoBot die`
`@BotName do you love me` | Replies with positive answer only to the bot owner. `@BotName do you love me` | Replies with positive answer only to the bot owner. | `@NadekoBot do you love me`
`@BotName how are you`, `@BotName how are you?` | Replies positive only if bot owner is online. `@BotName how are you`, `@BotName how are you?` | Replies positive only if bot owner is online. | `@NadekoBot how are you`
`@BotName fire` | Shows a unicode fire message. Optional parameter [x] tells her how many times to repeat the fire. | @NadekoBot fire [x] `@BotName fire` | Shows a unicode fire message. Optional parameter [x] tells her how many times to repeat the fire. | `@NadekoBot fire [x]`
`@BotName dump` | Dumps all of the invites it can to dump.txt.** Owner Only.** `@BotName dump` | Dumps all of the invites it can to dump.txt.** Owner Only.** | `@NadekoBot dump`
`@BotName ab` | Try to get 'abalabahaha' `@BotName ab` | Try to get 'abalabahaha'| `@NadekoBot ab`
### Gambling ### Gambling
Command and aliases | Description | Usage Command and aliases | Description | Usage
----------------|--------------|------- ----------------|--------------|-------
`$draw` | Draws a card from the deck.If you supply number [x], she draws up to 5 cards from the deck. | $draw [x] `$draw` | Draws a card from the deck.If you supply number [x], she draws up to 5 cards from the deck. | `$draw [x]`
`$shuffle`, `$sh` | Reshuffles all cards back into the deck. `$shuffle`, `$sh` | Reshuffles all cards back into the deck.|`$shuffle`
`$flip` | Flips coin(s) - heads or tails, and shows an image. | `$flip` or `$flip 3` `$flip` | Flips coin(s) - heads or tails, and shows an image. | `$flip` or `$flip 3`
`$betflip`, `$bf` | Bet to guess will the result be heads or tails. Guessing award you double flowers you've bet. | `$bf 5 heads` or `$bf 3 t` `$betflip`, `$bf` | Bet to guess will the result be heads or tails. Guessing award you double flowers you've bet. | `$bf 5 heads` or `$bf 3 t`
`$roll` | Rolls 0-100. If you supply a number [x] it rolls up to 30 normal dice. If you split 2 numbers with letter d (xdy) it will roll x dice from 1 to y. | $roll or $roll 7 or $roll 3d5 `$roll` | Rolls 0-100. If you supply a number [x] it rolls up to 30 normal dice. If you split 2 numbers with letter d (xdy) it will roll x dice from 1 to y. | `$roll` or `$roll 7` or `$roll 3d5`
`$rolluo` | Rolls 0-100. If you supply a number [x] it rolls up to 30 normal dice (unordered). If you split 2 numbers with letter d (xdy) it will roll x dice from 1 to y. | $roll or $roll 7 or $roll 3d5 `$rolluo` | Rolls 0-100. If you supply a number [x] it rolls up to 30 normal dice (unordered). If you split 2 numbers with letter d (xdy) it will roll x dice from 1 to y. | `$roll` or `$roll` 7 or `$roll 3d5`
`$nroll` | Rolls in a given range. | `$nroll 5` (rolls 0-5) or `$nroll 5-15` `$nroll` | Rolls in a given range. | `$nroll 5` (rolls 0-5) or `$nroll 5-15`
`$race` | Starts a new animal race. `$race` | Starts a new animal race. | `$race`
`$joinrace`, `$jr` | Joins a new race. You can specify an amount of flowers for betting (optional). You will get YourBet*(participants-1) back if you win. | `$jr` or `$jr 5` `$joinrace`, `$jr` | Joins a new race. You can specify an amount of flowers for betting (optional). You will get YourBet*(participants-1) back if you win. | `$jr` or `$jr 5`
`$raffle` | Prints a name and ID of a random user from the online list from the (optional) role. | `$raffle` or `$raffle RoleName `$raffle` | Prints a name and ID of a random user from the online list from the (optional) role. | `$raffle` or `$raffle RoleName`
`$$$` | Check how much NadekoFlowers a person has. (Defaults to yourself) | `$$$` or `$$$ @Someone` `$$$` | Check how much NadekoFlowers a person has. (Defaults to yourself) | `$$$` or `$$$ @Someone`
`$give` | Give someone a certain amount of NadekoFlowers|`$give 1 "@SomeGuy"` `$give` | Give someone a certain amount of NadekoFlowers|`$give 1 "@SomeGuy"`
`$award` | Gives someone a certain amount of flowers. **Bot Owner Only!** | `$award 100 @person` `$award` | Gives someone a certain amount of flowers. **Bot Owner Only!** | `$award 100 @person`
`$take` | Takes a certain amount of flowers from someone. **Bot Owner Only!** | `$take 1 "@someguy"` `$take` | Takes a certain amount of flowers from someone. **Bot Owner Only!** | `$take 1 "@someguy"`
`$betroll`, `$br` | Bets a certain amount of NadekoFlowers and rolls a dice. Rolling over 66 yields x2 flowers, over 90 - x3 and 100 x10. | $br 5 `$betroll`, `$br` | Bets a certain amount of NadekoFlowers and rolls a dice. Rolling over 66 yields x2 flowers, over 90 - x3 and 100 x10. | `$br 5`
`$leaderboard`, `$lb` | `$leaderboard`, `$lb` | Displays bot currency leaderboard | $lb
### Games ### Games
Command and aliases | Description | Usage Command and aliases | Description | Usage
----------------|--------------|------- ----------------|--------------|-------
`>t` | Starts a game of trivia. You can add nohint to prevent hints.First player to get to 10 points wins by default. You can specify a different number. 30 seconds per question. | `>t nohint` or `>t 5 nohint` `>t` | Starts a game of trivia. You can add nohint to prevent hints.First player to get to 10 points wins by default. You can specify a different number. 30 seconds per question. | `>t nohint` or `>t 5 nohint`
`>tl` | Shows a current trivia leaderboard. `>tl` | Shows a current trivia leaderboard. | `>tl`
`>tq` | Quits current trivia after current question. `>tq` | Quits current trivia after current question. | `>tq`
`>typestart` | Starts a typing contest. `>typestart` | Starts a typing contest. | `>typestart`
`>typestop` | Stops a typing contest on the current channel. `>typestop` | Stops a typing contest on the current channel. | `>typestop`
`>typeadd` | Adds a new article to the typing contest. Owner only. `>typeadd` | Adds a new article to the typing contest. Owner only. | `>typeadd wordswords`
`>poll` | Creates a poll, only person who has manage server permission can do it. | >poll Question?;Answer1;Answ 2;A_3 `>poll` | Creates a poll, only person who has manage server permission can do it. | `>poll Question?;Answer1;Answ 2;A_3`
`>pollend` | Stops active poll on this server and prints the results in this channel. `>pollend` | Stops active poll on this server and prints the results in this channel. | `>pollend`
`>pick` | Picks a flower planted in this channel. `>pick` | Picks a flower planted in this channel. | `>pick`
`>plant` | Spend a flower to plant it in this channel. (If bot is restarted or crashes, flower will be lost) `>plant` | Spend a flower to plant it in this channel. (If bot is restarted or crashes, flower will be lost) | `>plant`
`>gencurrency`, `>gc` | Toggles currency generation on this channel. Every posted message will have 2% chance to spawn a NadekoFlower. Optional parameter cooldown time in minutes, 5 minutes by default. Requires Manage Messages permission. | `>gc` or `>gc 60` `>gencurrency`, `>gc` | Toggles currency generation on this channel. Every posted message will have 2% chance to spawn a NadekoFlower. Optional parameter cooldown time in minutes, 5 minutes by default. Requires Manage Messages permission. | `>gc` or `>gc 60`
`>leet` | Converts a text to leetspeak with 6 (1-6) severity levels | >leet 3 Hello `>leet` | Converts a text to leetspeak with 6 (1-6) severity levels | `>leet 3 Hello`
`>choose` | Chooses a thing from a list of things | `>choose Get up;Sleep;Sleep more` `>choose` | Chooses a thing from a list of things | `>choose Get up;Sleep;Sleep more`
`>8ball` | Ask the 8ball a yes/no question. | `>8ball should i do something` `>8ball` | Ask the 8ball a yes/no question. | `>8ball should i do something`
`>rps` | Play a game of rocket paperclip scissors with Nadeko. | `>rps scissors` `>rps` | Play a game of rocket paperclip scissors with Nadeko. | `>rps scissors`
@ -245,30 +245,30 @@ Command and aliases | Description | Usage
### Searches ### Searches
Command and aliases | Description | Usage Command and aliases | Description | Usage
----------------|--------------|------- ----------------|--------------|-------
`~lolchamp` | Shows League Of Legends champion statistics. If there are spaces/apostrophes or in the name - omit them. Optional second parameter is a role. | ~lolchamp Riven or ~lolchamp Annie sup `~lolchamp` | Shows League Of Legends champion statistics. If there are spaces/apostrophes or in the name - omit them. Optional second parameter is a role. | `~lolchamp Riven` or `~lolchamp Annie sup`
`~lolban` | Shows top 6 banned champions ordered by ban rate. Ban these champions and you will be Plat 5 in no time. `~lolban` | Shows top 6 banned champions ordered by ban rate. Ban these champions and you will be Plat 5 in no time. | `~lolban`
`~hitbox`, `~hb` | Notifies this channel when a certain user starts streaming. | ~hitbox SomeStreamer `~hitbox`, `~hb` | Notifies this channel when a certain user starts streaming. | `~hitbox SomeStreamer`
`~twitch`, `~tw` | Notifies this channel when a certain user starts streaming. | ~twitch SomeStreamer `~twitch`, `~tw` | Notifies this channel when a certain user starts streaming. | `~twitch SomeStreamer`
`~beam`, `~bm` | Notifies this channel when a certain user starts streaming. | ~beam SomeStreamer `~beam`, `~bm` | Notifies this channel when a certain user starts streaming. | `~beam SomeStreamer`
`~checkhitbox`, `~chhb` | Checks if a certain user is streaming on the hitbox platform. | ~chhb SomeStreamer `~checkhitbox`, `~chhb` | Checks if a certain user is streaming on the hitbox platform. | `~chhb SomeStreamer`
`~checktwitch`, `~chtw` | Checks if a certain user is streaming on the twitch platform. | ~chtw SomeStreamer `~checktwitch`, `~chtw` | Checks if a certain user is streaming on the twitch platform. | `~chtw SomeStreamer`
`~checkbeam`, `~chbm` | Checks if a certain user is streaming on the beam platform. | ~chbm SomeStreamer `~checkbeam`, `~chbm` | Checks if a certain user is streaming on the beam platform. | `~chbm SomeStreamer`
`~removestream`, `~rms` | Removes notifications of a certain streamer on this channel. | ~rms SomeGuy `~removestream`, `~rms` | Removes notifications of a certain streamer on this channel. | `~rms SomeGuy`
`~liststreams`, `~ls` | Lists all streams you are following on this server. | ~ls `~liststreams`, `~ls` | Lists all streams you are following on this server. | `~ls`
`~convert` | Convert quantities from>to. Like `~convert m>km 1000` `~convert` | Convert quantities from>to. | `~convert m>km 1000`
`~convertlist` | List of the convertable dimensions and currencies. `~convertlist` | List of the convertable dimensions and currencies.
`~wowjoke` | Get one of Kwoth's penultimate WoW jokes. `~wowjoke` | Get one of Kwoth's penultimate WoW jokes. | `~wowjoke`
`~calculate`, `~calc` | Evaluate a mathematical expression. | ~calc 1+1 `~calculate`, `~calc` | Evaluate a mathematical expression. | ~calc 1+1
`~osu` | Shows osu stats for a player. | `~osu Name` or `~osu Name taiko` `~osu` | Shows osu stats for a player. | `~osu Name` or `~osu Name taiko`
`~osu b` | Shows information about an osu beatmap. | ~osu b https://osu.ppy.sh/s/127712 `~osu b` | Shows information about an osu beatmap. | `~osu b` https://osu.ppy.sh/s/127712`
`~osu top5` | Displays a user's top 5 plays. | ~osu top5 Name `~osu top5` | Displays a user's top 5 plays. | ~osu top5 Name
`~pokemon`, `~poke` | Searches for a pokemon. `~pokemon`, `~poke` | Searches for a pokemon. | `~poke Sylveon`
`~pokemonability`, `~pokeab` | Searches for a pokemon ability. `~pokemonability`, `~pokeab` | Searches for a pokemon ability. | `~pokeab "water gun"`
`~memelist` | Pulls a list of memes you can use with `~memegen` from http://memegen.link/templates/ `~memelist` | Pulls a list of memes you can use with `~memegen` from http://memegen.link/templates/ | `~memelist`
`~memegen` | Generates a meme from memelist with top and bottom text. | `~memegen biw "gets iced coffee" "in the winter"` `~memegen` | Generates a meme from memelist with top and bottom text. | `~memegen biw "gets iced coffee" "in the winter"`
`~we` | Shows weather data for a specified city and a country. BOTH ARE REQUIRED. Use country abbrevations. | `~we Moscow RF` `~we` | Shows weather data for a specified city and a country. BOTH ARE REQUIRED. Use country abbrevations. | `~we Moscow RF`
`~yt` | Searches youtubes and shows the first result | `~yt query` `~yt` | Searches youtubes and shows the first result | `~yt query`
`~ani`, `~anime`, `~aq` | Queries anilist for an anime and shows the first result. `~ani`, `~anime`, `~aq` | Queries anilist for an anime and shows the first result. | `~aq aquerion evol`
`~imdb` | Queries imdb for movies or series, show first result. | `~imdb query` `~imdb` | Queries imdb for movies or series, show first result. | `~imdb query`
`~mang`, `~manga`, `~mq` | Queries anilist for a manga and shows the first result. | `~mq query` `~mang`, `~manga`, `~mq` | Queries anilist for a manga and shows the first result. | `~mq query`
`~randomcat`, `~meow` | Shows a random cat image. `~randomcat`, `~meow` | Shows a random cat image.
@ -280,13 +280,13 @@ Command and aliases | Description | Usage
`~hs` | Searches for a Hearthstone card and shows its image. Takes a while to complete. | `~hs Ysera` `~hs` | Searches for a Hearthstone card and shows its image. Takes a while to complete. | `~hs Ysera`
`~ud` | Searches Urban Dictionary for a word. | `~ud Pineapple` `~ud` | Searches Urban Dictionary for a word. | `~ud Pineapple`
`~#` | Searches Tagdef.com for a hashtag. | `~# ff` `~#` | Searches Tagdef.com for a hashtag. | `~# ff`
`~quote` | Shows a random quote. `~quote` | Shows a random quote. | `~quote`
`~catfact` | Shows a random catfact from <http://catfacts-api.appspot.com/api/facts> `~catfact` | Shows a random catfact from <http://catfacts-api.appspot.com/api/facts> | `~catfact`
`~yomama`, `~ym` | Shows a random joke from <http://api.yomomma.info/> `~yomama`, `~ym` | Shows a random joke from <http://api.yomomma.info/> | `~ym`
`~randjoke`, `~rj` | Shows a random joke from <http://tambal.azurewebsites.net/joke/random> `~randjoke`, `~rj` | Shows a random joke from <http://tambal.azurewebsites.net/joke/random> | `~rj`
`~chucknorris`, `~cn` | Shows a random chucknorris joke from <http://tambal.azurewebsites.net/joke/random> `~chucknorris`, `~cn` | Shows a random chucknorris joke from <http://tambal.azurewebsites.net/joke/random> | `~cn`
`~magicitem`, `~mi` | Shows a random magicitem from <https://1d4chan.org/wiki/List_of_/tg/%27s_magic_items> `~magicitem`, `~mi` | Shows a random magicitem from <https://1d4chan.org/wiki/List_of_/tg/%27s_magic_items> | `~mi`
`~revav` | Returns a google reverse image search for someone's avatar. | `~revav "@SomeGuy" `~revav` | Returns a google reverse image search for someone's avatar. | `~revav "@SomeGuy"`
`~revimg` | Returns a google reverse image search for an image from a link. | `~revav Image link` `~revimg` | Returns a google reverse image search for an image from a link. | `~revav Image link`
`~safebooru` | Shows a random image from safebooru with a given tag. Tag is optional but preffered. (multiple tags are appended with +) | `~safebooru yuri+kissing` `~safebooru` | Shows a random image from safebooru with a given tag. Tag is optional but preffered. (multiple tags are appended with +) | `~safebooru yuri+kissing`
`~wiki` | Gives you back a wikipedia link | `~wiki query` `~wiki` | Gives you back a wikipedia link | `~wiki query`
@ -302,9 +302,9 @@ Command and aliases | Description | Usage
`~gelbooru` | Shows a random hentai image from gelbooru with a given tag. Tag is optional but preffered. (multiple tags are appended with +) | `~gelbooru yuri+kissing` `~gelbooru` | Shows a random hentai image from gelbooru with a given tag. Tag is optional but preffered. (multiple tags are appended with +) | `~gelbooru yuri+kissing`
`~rule34` | Shows a random image from rule34.xx with a given tag. Tag is optional but preffered. (multiple tags are appended with +) | `~rule34 yuri+kissing` `~rule34` | Shows a random image from rule34.xx with a given tag. Tag is optional but preffered. (multiple tags are appended with +) | `~rule34 yuri+kissing`
`~e621` | Shows a random hentai image from e621.net with a given tag. Tag is optional but preffered. Use spaces for multiple tags. | `~e621 yuri kissing` `~e621` | Shows a random hentai image from e621.net with a given tag. Tag is optional but preffered. Use spaces for multiple tags. | `~e621 yuri kissing`
`~cp` | We all know where this will lead you to. `~cp` | We all know where this will lead you to. | `~cp`
`~boobs` | Real adult content. `~boobs` | Real adult content. | `~boobs`
`~butts`, `~ass`, `~butt` | Real adult content. `~butts`, `~ass`, `~butt` | Real adult content. | `~butts` or `~ass`
### ClashOfClans ### ClashOfClans
Command and aliases | Description | Usage Command and aliases | Description | Usage
@ -323,16 +323,16 @@ Command and aliases | Description | Usage
Command and aliases | Description | Usage Command and aliases | Description | Usage
----------------|--------------|------- ----------------|--------------|-------
`>attack` | Attacks a target with the given move. Use `>movelist` to see a list of moves your type can use. | `>attack "vine whip" @someguy` `>attack` | Attacks a target with the given move. Use `>movelist` to see a list of moves your type can use. | `>attack "vine whip" @someguy`
`>movelist`, `>ml` | Lists the moves you are able to use `>movelist`, `>ml` | Lists the moves you are able to use | `>ml`
`>heal` | Heals someone. Revives those who fainted. Costs a NadekoFlower | >heal @someone `>heal` | Heals someone. Revives those who fainted. Costs a NadekoFlower | `>heal @someone`
`>type` | Get the poketype of the target. | >type @someone `>type` | Get the poketype of the target. | `>type @someone`
`>settype` | Set your poketype. Costs a NadekoFlower. | >settype fire `>settype` | Set your poketype. Costs a NadekoFlower. | `>settype fire`
### Translator ### Translator
Command and aliases | Description | Usage Command and aliases | Description | Usage
----------------|--------------|------- ----------------|--------------|-------
`~translate`, `~trans` | Translates from>to text. From the given language to the destiation language. | `~trans en>fr Hello` `~translate`, `~trans` | Translates from>to text. From the given language to the destiation language. | `~trans en>fr Hello`
`~translangs` | List the valid languages for translation. `~translangs` | List the valid languages for translation. | `{Prefix}translangs` or `{Prefix}translangs language`
### Customreactions ### Customreactions
Command and aliases | Description | Usage Command and aliases | Description | Usage