commit
e91ed77cc6
@ -108,7 +108,7 @@ namespace NadekoBot.Modules {
|
|||||||
.Parameter("r", ParameterType.Optional)
|
.Parameter("r", ParameterType.Optional)
|
||||||
.Parameter("g", ParameterType.Optional)
|
.Parameter("g", ParameterType.Optional)
|
||||||
.Parameter("b", ParameterType.Optional)
|
.Parameter("b", ParameterType.Optional)
|
||||||
.Description("Set a role's color to the hex or 0-255 color value provided.\n**Usage**: .color Admin 255 200 100 or .color Admin ffba55")
|
.Description("Set a role's color to the hex or 0-255 rgb color value provided.\n**Usage**: .color Admin 255 200 100 or .color Admin ffba55")
|
||||||
.Do(async e => {
|
.Do(async e => {
|
||||||
if (!e.User.ServerPermissions.ManageRoles) {
|
if (!e.User.ServerPermissions.ManageRoles) {
|
||||||
await e.Channel.SendMessage("You don't have permission to use this!");
|
await e.Channel.SendMessage("You don't have permission to use this!");
|
||||||
@ -160,7 +160,7 @@ namespace NadekoBot.Modules {
|
|||||||
});
|
});
|
||||||
|
|
||||||
cgb.CreateCommand(".modules")
|
cgb.CreateCommand(".modules")
|
||||||
.Description("List all bot modules")
|
.Description("List all bot modules.")
|
||||||
.Do(async e => {
|
.Do(async e => {
|
||||||
await e.Channel.SendMessage("`List of modules:` \n• " + string.Join("\n• ", NadekoBot.client.GetService<ModuleService>().Modules.Select(m => m.Name)));
|
await e.Channel.SendMessage("`List of modules:` \n• " + string.Join("\n• ", NadekoBot.client.GetService<ModuleService>().Modules.Select(m => m.Name)));
|
||||||
});
|
});
|
||||||
@ -180,7 +180,7 @@ namespace NadekoBot.Modules {
|
|||||||
|
|
||||||
cgb.CreateCommand(".b").Alias(".ban")
|
cgb.CreateCommand(".b").Alias(".ban")
|
||||||
.Parameter("everything", ParameterType.Unparsed)
|
.Parameter("everything", ParameterType.Unparsed)
|
||||||
.Description("Bans a mentioned user")
|
.Description("Bans a mentioned user.")
|
||||||
.Do(async e => {
|
.Do(async e => {
|
||||||
try {
|
try {
|
||||||
if (e.User.ServerPermissions.BanMembers && e.Message.MentionedUsers.Any()) {
|
if (e.User.ServerPermissions.BanMembers && e.Message.MentionedUsers.Any()) {
|
||||||
@ -193,7 +193,7 @@ namespace NadekoBot.Modules {
|
|||||||
|
|
||||||
cgb.CreateCommand(".ub").Alias(".unban")
|
cgb.CreateCommand(".ub").Alias(".unban")
|
||||||
.Parameter("everything", ParameterType.Unparsed)
|
.Parameter("everything", ParameterType.Unparsed)
|
||||||
.Description("Unbans a mentioned user")
|
.Description("Unbans a mentioned user.")
|
||||||
.Do(async e => {
|
.Do(async e => {
|
||||||
try {
|
try {
|
||||||
if (e.User.ServerPermissions.BanMembers && e.Message.MentionedUsers.Any()) {
|
if (e.User.ServerPermissions.BanMembers && e.Message.MentionedUsers.Any()) {
|
||||||
@ -219,7 +219,7 @@ namespace NadekoBot.Modules {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
cgb.CreateCommand(".mute")
|
cgb.CreateCommand(".mute")
|
||||||
.Description("Mutes mentioned user or users")
|
.Description("Mutes mentioned user or users.")
|
||||||
.Parameter("throwaway", ParameterType.Unparsed)
|
.Parameter("throwaway", ParameterType.Unparsed)
|
||||||
.Do(async e => {
|
.Do(async e => {
|
||||||
if (!e.User.ServerPermissions.MuteMembers) {
|
if (!e.User.ServerPermissions.MuteMembers) {
|
||||||
@ -239,7 +239,7 @@ namespace NadekoBot.Modules {
|
|||||||
});
|
});
|
||||||
|
|
||||||
cgb.CreateCommand(".unmute")
|
cgb.CreateCommand(".unmute")
|
||||||
.Description("Unmutes mentioned user or users")
|
.Description("Unmutes mentioned user or users.")
|
||||||
.Parameter("throwaway", ParameterType.Unparsed)
|
.Parameter("throwaway", ParameterType.Unparsed)
|
||||||
.Do(async e => {
|
.Do(async e => {
|
||||||
if (!e.User.ServerPermissions.MuteMembers) {
|
if (!e.User.ServerPermissions.MuteMembers) {
|
||||||
@ -310,7 +310,7 @@ namespace NadekoBot.Modules {
|
|||||||
await e.Channel.SendMessage($"Removed channel **{e.GetArg("channel_name")}**.");
|
await e.Channel.SendMessage($"Removed channel **{e.GetArg("channel_name")}**.");
|
||||||
}
|
}
|
||||||
} catch {
|
} catch {
|
||||||
await e.Channel.SendMessage("No sufficient permissions.");
|
await e.Channel.SendMessage("Insufficient permissions.");
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
@ -324,7 +324,7 @@ namespace NadekoBot.Modules {
|
|||||||
await e.Channel.SendMessage($"Created voice channel **{e.GetArg("channel_name")}**.");
|
await e.Channel.SendMessage($"Created voice channel **{e.GetArg("channel_name")}**.");
|
||||||
}
|
}
|
||||||
} catch {
|
} catch {
|
||||||
await e.Channel.SendMessage("No sufficient permissions.");
|
await e.Channel.SendMessage("Insufficient permissions.");
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
@ -338,7 +338,7 @@ namespace NadekoBot.Modules {
|
|||||||
await e.Channel.SendMessage($"Removed text channel **{e.GetArg("channel_name")}**.");
|
await e.Channel.SendMessage($"Removed text channel **{e.GetArg("channel_name")}**.");
|
||||||
}
|
}
|
||||||
} catch {
|
} catch {
|
||||||
await e.Channel.SendMessage("No sufficient permissions.");
|
await e.Channel.SendMessage("Insufficient permissions.");
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
@ -352,7 +352,7 @@ namespace NadekoBot.Modules {
|
|||||||
await e.Channel.SendMessage($"Added text channel **{e.GetArg("channel_name")}**.");
|
await e.Channel.SendMessage($"Added text channel **{e.GetArg("channel_name")}**.");
|
||||||
}
|
}
|
||||||
} catch {
|
} catch {
|
||||||
await e.Channel.SendMessage("No sufficient permissions.");
|
await e.Channel.SendMessage("Insufficient permissions.");
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
@ -367,7 +367,7 @@ namespace NadekoBot.Modules {
|
|||||||
});
|
});
|
||||||
|
|
||||||
cgb.CreateCommand(".uid").Alias(".userid")
|
cgb.CreateCommand(".uid").Alias(".userid")
|
||||||
.Description("Shows user id")
|
.Description("Shows user ID.")
|
||||||
.Parameter("user", ParameterType.Optional)
|
.Parameter("user", ParameterType.Optional)
|
||||||
.Do(async e => {
|
.Do(async e => {
|
||||||
var usr = e.User;
|
var usr = e.User;
|
||||||
@ -376,15 +376,15 @@ namespace NadekoBot.Modules {
|
|||||||
});
|
});
|
||||||
|
|
||||||
cgb.CreateCommand(".cid").Alias(".channelid")
|
cgb.CreateCommand(".cid").Alias(".channelid")
|
||||||
.Description("Shows current channel id")
|
.Description("Shows current channel ID.")
|
||||||
.Do(async e => await e.Channel.SendMessage("This channel's id is " + e.Channel.Id));
|
.Do(async e => await e.Channel.SendMessage("This channel's ID is " + e.Channel.Id));
|
||||||
|
|
||||||
cgb.CreateCommand(".sid").Alias(".serverid")
|
cgb.CreateCommand(".sid").Alias(".serverid")
|
||||||
.Description("Shows current server id")
|
.Description("Shows current server ID.")
|
||||||
.Do(async e => await e.Channel.SendMessage("This server's id is " + e.Server.Id));
|
.Do(async e => await e.Channel.SendMessage("This server's ID is " + e.Server.Id));
|
||||||
|
|
||||||
cgb.CreateCommand(".stats")
|
cgb.CreateCommand(".stats")
|
||||||
.Description("Shows some basic stats for nadeko")
|
.Description("Shows some basic stats for Nadeko.")
|
||||||
.Do(async e => {
|
.Do(async e => {
|
||||||
var t = Task.Run(() => {
|
var t = Task.Run(() => {
|
||||||
return NadekoStats.Instance.GetStats() + "`" + Music.GetMusicStats() + "`";
|
return NadekoStats.Instance.GetStats() + "`" + Music.GetMusicStats() + "`";
|
||||||
@ -431,7 +431,7 @@ namespace NadekoBot.Modules {
|
|||||||
|
|
||||||
ConcurrentDictionary<Server, bool> clearDictionary = new ConcurrentDictionary<Server, bool>();
|
ConcurrentDictionary<Server, bool> clearDictionary = new ConcurrentDictionary<Server, bool>();
|
||||||
cgb.CreateCommand(".clr")
|
cgb.CreateCommand(".clr")
|
||||||
.Description("Clears some of nadeko's (or some other user's if supplied) messages from the current channel.\n**Usage**: .clr @X")
|
.Description("Clears some of Nadeko's (or some other user's if supplied) messages from the current channel.\n**Usage**: .clr @X")
|
||||||
.Parameter("user",ParameterType.Unparsed)
|
.Parameter("user",ParameterType.Unparsed)
|
||||||
.Do(async e => {
|
.Do(async e => {
|
||||||
var usrId = NadekoBot.client.CurrentUser.Id;
|
var usrId = NadekoBot.client.CurrentUser.Id;
|
||||||
@ -645,7 +645,7 @@ namespace NadekoBot.Modules {
|
|||||||
});
|
});
|
||||||
|
|
||||||
cgb.CreateCommand(".videocall")
|
cgb.CreateCommand(".videocall")
|
||||||
.Description("Creates a private appear.in video call link for you and other mentioned people and sends it in private messages")
|
.Description("Creates a private appear.in video call link for you and other mentioned people. The link is sent to mentioned people via a private message.")
|
||||||
.Parameter("arg", ParameterType.Unparsed)
|
.Parameter("arg", ParameterType.Unparsed)
|
||||||
.Do(async e => {
|
.Do(async e => {
|
||||||
try {
|
try {
|
||||||
|
@ -78,7 +78,7 @@ namespace NadekoBot.Modules
|
|||||||
|
|
||||||
cgb.CreateCommand("poketype")
|
cgb.CreateCommand("poketype")
|
||||||
.Parameter("target", Discord.Commands.ParameterType.Required)
|
.Parameter("target", Discord.Commands.ParameterType.Required)
|
||||||
.Description("Gets the users element type. Use this to do more damage with strike")
|
.Description("Gets the users element type. Use this to do more damage with strike!")
|
||||||
.Do(async e =>
|
.Do(async e =>
|
||||||
{
|
{
|
||||||
var usr = e.Server.FindUsers(e.GetArg("target")).FirstOrDefault();
|
var usr = e.Server.FindUsers(e.GetArg("target")).FirstOrDefault();
|
||||||
|
@ -46,7 +46,7 @@ namespace NadekoBot.Modules {
|
|||||||
|
|
||||||
cgb.CreateCommand("s")
|
cgb.CreateCommand("s")
|
||||||
.Alias("stop")
|
.Alias("stop")
|
||||||
.Description("Completely stops the music and unbinds the bot from the channel and cleanes up files.")
|
.Description("Completely stops the music, unbinds the bot from the channel, and cleans up files.")
|
||||||
.Do(e => {
|
.Do(e => {
|
||||||
if (musicPlayers.ContainsKey(e.Server) == false) return;
|
if (musicPlayers.ContainsKey(e.Server) == false) return;
|
||||||
musicPlayers[e.Server].Stop();
|
musicPlayers[e.Server].Stop();
|
||||||
@ -54,7 +54,7 @@ namespace NadekoBot.Modules {
|
|||||||
|
|
||||||
cgb.CreateCommand("p")
|
cgb.CreateCommand("p")
|
||||||
.Alias("pause")
|
.Alias("pause")
|
||||||
.Description("Pauses or Unpauses the song")
|
.Description("Pauses or Unpauses the song.")
|
||||||
.Do(async e => {
|
.Do(async e => {
|
||||||
if (musicPlayers.ContainsKey(e.Server) == false) return;
|
if (musicPlayers.ContainsKey(e.Server) == false) return;
|
||||||
if (musicPlayers[e.Server].TogglePause())
|
if (musicPlayers[e.Server].TogglePause())
|
||||||
@ -65,7 +65,7 @@ namespace NadekoBot.Modules {
|
|||||||
|
|
||||||
cgb.CreateCommand("q")
|
cgb.CreateCommand("q")
|
||||||
.Alias("yq")
|
.Alias("yq")
|
||||||
.Description("Queue a song using keywords or link. Bot will join your voice channel. **You must be in a voice channel**.\n**Usage**: `!m q Dream Of Venice`")
|
.Description("Queue a song using keywords or a link. Bot will join your voice channel. **You must be in a voice channel**.\n**Usage**: `!m q Dream Of Venice`")
|
||||||
.Parameter("query", ParameterType.Unparsed)
|
.Parameter("query", ParameterType.Unparsed)
|
||||||
.Do(async e => await QueueSong(e,e.GetArg("query")));
|
.Do(async e => await QueueSong(e,e.GetArg("query")));
|
||||||
|
|
||||||
@ -190,7 +190,7 @@ namespace NadekoBot.Modules {
|
|||||||
.Parameter("playlist", ParameterType.Unparsed)
|
.Parameter("playlist", ParameterType.Unparsed)
|
||||||
.Do(async e => {
|
.Do(async e => {
|
||||||
if (e.User.VoiceChannel?.Server != e.Server) {
|
if (e.User.VoiceChannel?.Server != e.Server) {
|
||||||
await e.Channel.SendMessage("💢 You need to be in the voice channel on this server.\n If you already are in a voice channel, try rejoining it.");
|
await e.Channel.SendMessage("💢 You need to be in a voice channel on this server.\n If you are already in a voice channel, try rejoining it.");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
var ids = await SearchHelper.GetVideoIDs(await SearchHelper.GetPlaylistIdByKeyword(e.GetArg("playlist")));
|
var ids = await SearchHelper.GetVideoIDs(await SearchHelper.GetPlaylistIdByKeyword(e.GetArg("playlist")));
|
||||||
@ -208,7 +208,7 @@ namespace NadekoBot.Modules {
|
|||||||
.Parameter("radio_link", ParameterType.Required)
|
.Parameter("radio_link", ParameterType.Required)
|
||||||
.Do(async e => {
|
.Do(async e => {
|
||||||
if (e.User.VoiceChannel?.Server != e.Server) {
|
if (e.User.VoiceChannel?.Server != e.Server) {
|
||||||
await e.Channel.SendMessage("💢 You need to be in the voice channel on this server.\n If you already are in a voice channel, try rejoining it.");
|
await e.Channel.SendMessage("💢 You need to be in a voice channel on this server.\n If you are already in a voice channel, try rejoining it.");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
await QueueSong(e, e.GetArg("radio_link"), radio: true);
|
await QueueSong(e, e.GetArg("radio_link"), radio: true);
|
||||||
@ -225,7 +225,7 @@ namespace NadekoBot.Modules {
|
|||||||
});
|
});
|
||||||
|
|
||||||
cgb.CreateCommand("rm")
|
cgb.CreateCommand("rm")
|
||||||
.Description("Removes a song by a # from the queue or 'all' to remove whole queue.")
|
.Description("Remove a song by its # in the queue, or 'all' to remove whole queue.")
|
||||||
.Parameter("num",ParameterType.Required)
|
.Parameter("num",ParameterType.Required)
|
||||||
.Do(async e => {
|
.Do(async e => {
|
||||||
var arg = e.GetArg("num");
|
var arg = e.GetArg("num");
|
||||||
@ -263,7 +263,7 @@ namespace NadekoBot.Modules {
|
|||||||
|
|
||||||
private async Task QueueSong(CommandEventArgs e, string query, bool silent = false, bool radio = false) {
|
private async Task QueueSong(CommandEventArgs e, string query, bool silent = false, bool radio = false) {
|
||||||
if (e.User.VoiceChannel?.Server != e.Server) {
|
if (e.User.VoiceChannel?.Server != e.Server) {
|
||||||
await e.Channel.SendMessage("💢 You need to be in the voice channel on this server.\n If you are already in a voice channel, try rejoining.");
|
await e.Channel.SendMessage("💢 You need to be in a voice channel on this server.\n If you are already in a voice channel, try rejoining.");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -20,7 +20,7 @@ namespace NadekoBot.Modules {
|
|||||||
cgb.AddCheck(Classes.Permissions.PermissionChecker.Instance);
|
cgb.AddCheck(Classes.Permissions.PermissionChecker.Instance);
|
||||||
|
|
||||||
cgb.CreateCommand("~hentai")
|
cgb.CreateCommand("~hentai")
|
||||||
.Description("Shows a random NSFW hentai image from gelbooru and danbooru with a given tag. Tag is optional but preffered. (multiple tags are appended with +)\n**Usage**: ~hentai yuri")
|
.Description("Shows a random NSFW hentai image from gelbooru and danbooru with a given tag. Tag is optional but preffered. (multiple tags are appended with +)\n**Usage**: ~hentai yuri+kissing")
|
||||||
.Parameter("tag", ParameterType.Unparsed)
|
.Parameter("tag", ParameterType.Unparsed)
|
||||||
.Do(async e => {
|
.Do(async e => {
|
||||||
string tag = e.GetArg("tag");
|
string tag = e.GetArg("tag");
|
||||||
@ -48,8 +48,8 @@ namespace NadekoBot.Modules {
|
|||||||
await e.Channel.SendMessage(await SearchHelper.GetGelbooruImageLink(tag));
|
await e.Channel.SendMessage(await SearchHelper.GetGelbooruImageLink(tag));
|
||||||
});
|
});
|
||||||
cgb.CreateCommand("~e621")
|
cgb.CreateCommand("~e621")
|
||||||
.Description("Shows a random hentai image from e621.net with a given tag. Tag is optional but preffered. Use spaces for multiple tags.\n**Usage**: ~e621 yuri kissing")
|
.Description("Shows a random hentai image from e621.net with a given tag. Tag is optional but preffered. Use spaces for multiple tags.\n**Usage**: ~e621 yuri+kissing")
|
||||||
.Parameter("tag", ParameterType.Unparsed)
|
.Parameter("tag", ParameterType.Unparsed
|
||||||
.Do(async e => {
|
.Do(async e => {
|
||||||
string tag = e.GetArg("tag");
|
string tag = e.GetArg("tag");
|
||||||
if (tag == null)
|
if (tag == null)
|
||||||
|
@ -85,7 +85,7 @@ namespace NadekoBot.Modules {
|
|||||||
});
|
});
|
||||||
|
|
||||||
cgb.CreateCommand("~i")
|
cgb.CreateCommand("~i")
|
||||||
.Description("Pulls a first image using a search parameter. Use ~ir for different results.\n**Usage**: ~i cute kitten")
|
.Description("Pulls the first image found using a search parameter. Use ~ir for different results.\n**Usage**: ~i cute kitten")
|
||||||
.Parameter("query", ParameterType.Unparsed)
|
.Parameter("query", ParameterType.Unparsed)
|
||||||
.Do(async e => {
|
.Do(async e => {
|
||||||
if (string.IsNullOrWhiteSpace(e.GetArg("query")))
|
if (string.IsNullOrWhiteSpace(e.GetArg("query")))
|
||||||
@ -165,7 +165,7 @@ namespace NadekoBot.Modules {
|
|||||||
});
|
});
|
||||||
|
|
||||||
cgb.CreateCommand("~osu")
|
cgb.CreateCommand("~osu")
|
||||||
.Description("Shows osu stats for a player\n**Usage**:~osu Name")
|
.Description("Shows osu stats for a player.\n**Usage**:~osu Name")
|
||||||
.Parameter("usr", ParameterType.Unparsed)
|
.Parameter("usr", ParameterType.Unparsed)
|
||||||
.Do(async e => {
|
.Do(async e => {
|
||||||
if (string.IsNullOrWhiteSpace(e.GetArg("usr")))
|
if (string.IsNullOrWhiteSpace(e.GetArg("usr")))
|
||||||
@ -191,7 +191,7 @@ namespace NadekoBot.Modules {
|
|||||||
});
|
});
|
||||||
|
|
||||||
cgb.CreateCommand("~ud")
|
cgb.CreateCommand("~ud")
|
||||||
.Description("Searches Urban Dictionary for a word\n**Usage**:~ud Pineapple")
|
.Description("Searches Urban Dictionary for a word.\n**Usage**:~ud Pineapple")
|
||||||
.Parameter("query", ParameterType.Unparsed)
|
.Parameter("query", ParameterType.Unparsed)
|
||||||
.Do(async e => {
|
.Do(async e => {
|
||||||
var arg = e.GetArg("query");
|
var arg = e.GetArg("query");
|
||||||
@ -217,7 +217,7 @@ namespace NadekoBot.Modules {
|
|||||||
});
|
});
|
||||||
// thanks to Blaubeerwald
|
// thanks to Blaubeerwald
|
||||||
cgb.CreateCommand("~#")
|
cgb.CreateCommand("~#")
|
||||||
.Description("Searches Tagdef.com for a hashtag\n**Usage**:~# ff")
|
.Description("Searches Tagdef.com for a hashtag.\n**Usage**:~# ff")
|
||||||
.Parameter("query", ParameterType.Unparsed)
|
.Parameter("query", ParameterType.Unparsed)
|
||||||
.Do(async e => {
|
.Do(async e => {
|
||||||
var arg = e.GetArg("query");
|
var arg = e.GetArg("query");
|
||||||
@ -238,7 +238,7 @@ namespace NadekoBot.Modules {
|
|||||||
await e.Channel.SendMessage(sb.ToString());
|
await e.Channel.SendMessage(sb.ToString());
|
||||||
}
|
}
|
||||||
catch {
|
catch {
|
||||||
await e.Channel.SendMessage("💢 Failed finidng a definition for that tag");
|
await e.Channel.SendMessage("💢 Failed finidng a definition for that tag.");
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
//todo when moved from parse
|
//todo when moved from parse
|
||||||
|
@ -74,7 +74,7 @@ namespace NadekoBot.Modules {
|
|||||||
});
|
});
|
||||||
|
|
||||||
cgb.CreateCommand("bind")
|
cgb.CreateCommand("bind")
|
||||||
.Description("Bind a trello bot to a single channel. You will receive notifications from your board when somethign is added or edited.")
|
.Description("Bind a trello bot to a single channel. You will receive notifications from your board when something is added or edited.")
|
||||||
.Parameter("board_id", Discord.Commands.ParameterType.Required)
|
.Parameter("board_id", Discord.Commands.ParameterType.Required)
|
||||||
.Do(async e => {
|
.Do(async e => {
|
||||||
if (e.User.Id != NadekoBot.OwnerID) return;
|
if (e.User.Id != NadekoBot.OwnerID) return;
|
||||||
|
Loading…
Reference in New Issue
Block a user