Fixed some plural currency forms, added .scr, .lcr now shows only triggers
This commit is contained in:
		@@ -124,10 +124,32 @@ namespace NadekoBot.Modules.CustomReactions
 | 
			
		||||
            if (customReactions == null || !customReactions.Any())
 | 
			
		||||
                await imsg.Channel.SendMessageAsync("`No custom reactions found`").ConfigureAwait(false);
 | 
			
		||||
            else
 | 
			
		||||
                await imsg.Channel.SendMessageAsync(string.Join("\n", customReactions.OrderBy(cr => cr.Trigger).Skip((page - 1) * 10).Take(10)))
 | 
			
		||||
                await imsg.Channel.SendMessageAsync($"`Page {page} of custom reactions:`\n" + string.Join("\n", customReactions.OrderBy(cr => cr.Trigger).Skip((page - 1) * 15).Take(15).Select(cr => $"`#{cr.Id}`  `Trigger:` {cr.Trigger}")))
 | 
			
		||||
                             .ConfigureAwait(false);
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        [NadekoCommand, Usage, Description, Aliases]
 | 
			
		||||
        public async Task ShowCustReact(IUserMessage imsg, int id)
 | 
			
		||||
        {
 | 
			
		||||
            var channel = imsg.Channel as ITextChannel;
 | 
			
		||||
 | 
			
		||||
            ConcurrentHashSet<CustomReaction> customReactions;
 | 
			
		||||
            if (channel == null)
 | 
			
		||||
                customReactions = GlobalReactions;
 | 
			
		||||
            else
 | 
			
		||||
                customReactions = GuildReactions.GetOrAdd(channel.Guild.Id, new ConcurrentHashSet<CustomReaction>());
 | 
			
		||||
 | 
			
		||||
            var found = customReactions.FirstOrDefault(cr => cr.Id == id);
 | 
			
		||||
 | 
			
		||||
            if (found == null)
 | 
			
		||||
                await imsg.Channel.SendMessageAsync("`No custom reaction found with that id.`").ConfigureAwait(false);
 | 
			
		||||
            else
 | 
			
		||||
            {
 | 
			
		||||
                await imsg.Channel.SendMessageAsync($"`Custom reaction #{id}`\n`Trigger:` {found.Trigger}\n`Response:` {found.Response}")
 | 
			
		||||
                             .ConfigureAwait(false);
 | 
			
		||||
            }
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        [NadekoCommand, Usage, Description, Aliases]
 | 
			
		||||
        public async Task DelCustReact(IUserMessage imsg, int id)
 | 
			
		||||
        {
 | 
			
		||||
 
 | 
			
		||||
@@ -96,7 +96,7 @@ namespace NadekoBot.Modules.Gambling
 | 
			
		||||
                return;
 | 
			
		||||
            }
 | 
			
		||||
            await CurrencyHandler.AddCurrencyAsync(receiver, $"Gift from {umsg.Author.Username} ({umsg.Author.Id}).", amount, true).ConfigureAwait(false);
 | 
			
		||||
            await channel.SendMessageAsync($"{umsg.Author.Mention} successfully sent {amount} {Gambling.CurrencyPluralName}s to {receiver.Mention}!").ConfigureAwait(false);
 | 
			
		||||
            await channel.SendMessageAsync($"{umsg.Author.Mention} successfully sent {amount} {(amount == 1 ? Gambling.CurrencyName : Gambling.CurrencyPluralName)} to {receiver.Mention}!").ConfigureAwait(false);
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        [NadekoCommand, Usage, Description, Aliases]
 | 
			
		||||
@@ -117,7 +117,7 @@ namespace NadekoBot.Modules.Gambling
 | 
			
		||||
 | 
			
		||||
            await CurrencyHandler.AddCurrencyAsync(usrId, $"Awarded by bot owner. ({umsg.Author.Username}/{umsg.Author.Id})", (int)amount).ConfigureAwait(false);
 | 
			
		||||
 | 
			
		||||
            await channel.SendMessageAsync($"{umsg.Author.Mention} successfully awarded {amount} {Gambling.CurrencyName}s to <@{usrId}>!").ConfigureAwait(false);
 | 
			
		||||
            await channel.SendMessageAsync($"{umsg.Author.Mention} successfully awarded {amount} {(amount == 1 ? Gambling.CurrencyName : Gambling.CurrencyPluralName)} to <@{usrId}>!").ConfigureAwait(false);
 | 
			
		||||
        }
 | 
			
		||||
        
 | 
			
		||||
        [NadekoCommand, Usage, Description, Aliases]
 | 
			
		||||
@@ -130,9 +130,9 @@ namespace NadekoBot.Modules.Gambling
 | 
			
		||||
                return;
 | 
			
		||||
 | 
			
		||||
            if(await CurrencyHandler.RemoveCurrencyAsync(user, $"Taken by bot owner.({umsg.Author.Username}/{umsg.Author.Id})", amount, true).ConfigureAwait(false))
 | 
			
		||||
                await channel.SendMessageAsync($"{umsg.Author.Mention} successfully took {amount} {Gambling.CurrencyPluralName} from {user}!").ConfigureAwait(false);
 | 
			
		||||
                await channel.SendMessageAsync($"{umsg.Author.Mention} successfully took {amount} {(amount == 1? Gambling.CurrencyName : Gambling.CurrencyPluralName)} from {user}!").ConfigureAwait(false);
 | 
			
		||||
            else
 | 
			
		||||
                await channel.SendMessageAsync($"{umsg.Author.Mention} was unable to take {amount} {Gambling.CurrencyPluralName} from {user} because the user doesn't have that much {Gambling.CurrencyPluralName}!").ConfigureAwait(false);
 | 
			
		||||
                await channel.SendMessageAsync($"{umsg.Author.Mention} was unable to take {amount} {(amount == 1 ? Gambling.CurrencyName : Gambling.CurrencyPluralName)} from {user} because the user doesn't have that much {Gambling.CurrencyPluralName}!").ConfigureAwait(false);
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
@@ -146,9 +146,9 @@ namespace NadekoBot.Modules.Gambling
 | 
			
		||||
                return;
 | 
			
		||||
 | 
			
		||||
            if(await CurrencyHandler.RemoveCurrencyAsync(usrId, $"Taken by bot owner.({umsg.Author.Username}/{umsg.Author.Id})", amount).ConfigureAwait(false))
 | 
			
		||||
                await channel.SendMessageAsync($"{umsg.Author.Mention} successfully took {amount} {Gambling.CurrencyName}s from <@{usrId}>!").ConfigureAwait(false);
 | 
			
		||||
                await channel.SendMessageAsync($"{umsg.Author.Mention} successfully took {amount} {(amount == 1 ? Gambling.CurrencyName : Gambling.CurrencyPluralName)} from <@{usrId}>!").ConfigureAwait(false);
 | 
			
		||||
            else
 | 
			
		||||
                await channel.SendMessageAsync($"{umsg.Author.Mention} was unable to take {amount} {Gambling.CurrencyPluralName} from `{usrId}` because the user doesn't have that much {Gambling.CurrencyPluralName}!").ConfigureAwait(false);
 | 
			
		||||
                await channel.SendMessageAsync($"{umsg.Author.Mention} was unable to take {amount} {(amount == 1 ? Gambling.CurrencyName : Gambling.CurrencyPluralName)} from `{usrId}` because the user doesn't have that much {Gambling.CurrencyPluralName}!").ConfigureAwait(false);
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        [NadekoCommand, Usage, Description, Aliases]
 | 
			
		||||
 
 | 
			
		||||
@@ -6171,7 +6171,7 @@ namespace NadekoBot.Resources {
 | 
			
		||||
        }
 | 
			
		||||
        
 | 
			
		||||
        /// <summary>
 | 
			
		||||
        ///    Looks up a localized string similar to Shows all possible responses from a single custom reaction..
 | 
			
		||||
        ///    Looks up a localized string similar to Shows a custom reaction's response on a given ID..
 | 
			
		||||
        /// </summary>
 | 
			
		||||
        public static string showcustreact_desc {
 | 
			
		||||
            get {
 | 
			
		||||
@@ -6180,7 +6180,7 @@ namespace NadekoBot.Resources {
 | 
			
		||||
        }
 | 
			
		||||
        
 | 
			
		||||
        /// <summary>
 | 
			
		||||
        ///    Looks up a localized string similar to `.scr %mention% bb`.
 | 
			
		||||
        ///    Looks up a localized string similar to `.scr 1`.
 | 
			
		||||
        /// </summary>
 | 
			
		||||
        public static string showcustreact_usage {
 | 
			
		||||
            get {
 | 
			
		||||
 
 | 
			
		||||
@@ -454,10 +454,10 @@
 | 
			
		||||
    <value>showcustreact scr</value>
 | 
			
		||||
  </data>
 | 
			
		||||
  <data name="showcustreact_desc" xml:space="preserve">
 | 
			
		||||
    <value>Shows all possible responses from a single custom reaction.</value>
 | 
			
		||||
    <value>Shows a custom reaction's response on a given ID.</value>
 | 
			
		||||
  </data>
 | 
			
		||||
  <data name="showcustreact_usage" xml:space="preserve">
 | 
			
		||||
    <value>`.scr %mention% bb`</value>
 | 
			
		||||
    <value>`.scr 1`</value>
 | 
			
		||||
  </data>
 | 
			
		||||
  <data name="editcustreact_cmd" xml:space="preserve">
 | 
			
		||||
    <value>editcustreact ecr</value>
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user