.unmute renamed to .voiceunmute

This commit is contained in:
Kwoth 2016-10-19 08:09:25 +02:00
parent 9c22ee7b96
commit b18b805f4d
3 changed files with 35 additions and 41 deletions

View File

@ -468,18 +468,12 @@ namespace NadekoBot.Modules.Administration
[NadekoCommand, Usage, Description, Aliases]
[RequireContext(ContextType.Guild)]
[RequirePermission(GuildPermission.MuteMembers)]
public async Task Unmute(IUserMessage umsg, params IGuildUser[] users)
public async Task VoiceUnmute(IUserMessage umsg, IGuildUser user)
{
var channel = (ITextChannel)umsg.Channel;
if (!users.Any())
return;
try
{
foreach (var u in users)
{
await u.ModifyAsync(usr => usr.Mute = false).ConfigureAwait(false);
}
await user.ModifyAsync(usr => usr.Mute = false).ConfigureAwait(false);
await channel.SendMessageAsync("Unmute successful").ConfigureAwait(false);
}
catch

View File

@ -7187,33 +7187,6 @@ namespace NadekoBot.Resources {
}
}
/// <summary>
/// Looks up a localized string similar to unmute.
/// </summary>
public static string unmute_cmd {
get {
return ResourceManager.GetString("unmute_cmd", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to Unmutes mentioned user or users. .
/// </summary>
public static string unmute_desc {
get {
return ResourceManager.GetString("unmute_desc", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to `.unmute &quot;@Someguy&quot;` or `.unmute &quot;@Someguy&quot; &quot;@Someguy&quot;`.
/// </summary>
public static string unmute_usage {
get {
return ResourceManager.GetString("unmute_usage", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to unstuck.
/// </summary>
@ -7619,6 +7592,33 @@ namespace NadekoBot.Resources {
}
}
/// <summary>
/// Looks up a localized string similar to voiceunmute.
/// </summary>
public static string voiceunmute_cmd {
get {
return ResourceManager.GetString("voiceunmute_cmd", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to Gives a previously voice-muted user a permission to speak. .
/// </summary>
public static string voiceunmute_desc {
get {
return ResourceManager.GetString("voiceunmute_desc", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to `.unmute @Someguy`.
/// </summary>
public static string voiceunmute_usage {
get {
return ResourceManager.GetString("voiceunmute_usage", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to volume vol.
/// </summary>

View File

@ -621,14 +621,14 @@
<data name="mute_usage" xml:space="preserve">
<value>`.mute @Someone`</value>
</data>
<data name="unmute_cmd" xml:space="preserve">
<value>unmute</value>
<data name="voiceunmute_cmd" xml:space="preserve">
<value>voiceunmute</value>
</data>
<data name="unmute_desc" xml:space="preserve">
<value>Unmutes mentioned user or users. </value>
<data name="voiceunmute_desc" xml:space="preserve">
<value>Gives a previously voice-muted user a permission to speak. </value>
</data>
<data name="unmute_usage" xml:space="preserve">
<value>`.unmute "@Someguy"` or `.unmute "@Someguy" "@Someguy"`</value>
<data name="voiceunmute_usage" xml:space="preserve">
<value>`.unmute @Someguy`</value>
</data>
<data name="deafen_cmd" xml:space="preserve">
<value>deafen deaf</value>