diff --git a/README.md b/README.md index 3d28419..a27d811 100755 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# Robocop-ng +# robocop-ng Next-gen rewrite of Kurisu/Robocop bot used on ReSwitched bot with discord.py rewrite, designed to be relatively clean, consistent and un-bloated. diff --git a/Robocop.py b/Robocop.py index 39afd7d..3001e5d 100755 --- a/Robocop.py +++ b/Robocop.py @@ -176,13 +176,25 @@ async def on_command_error(ctx, error): f"{ctx.command.signature}```\nPlease see `{ctx.prefix}help " f"{ctx.command.name}` for more info about this command." ) + + # Keep a list of commands that involve mentioning users + # and can involve users leaving/getting banned + ಠ_ಠ = ["warn", "kick", "ban"] + if isinstance(error, commands.BadArgument): + # and if said commands get used, add a specific notice. + if ctx.command.name in ಠ_ಠ: + help_text = ( + "This probably means that user left (or already got kicked/banned).\n" + + help_text + ) + return await ctx.send( - f"{ctx.author.mention}: You gave incorrect " f"arguments. {help_text}" + f"{ctx.author.mention}: You gave incorrect arguments. {help_text}" ) elif isinstance(error, commands.MissingRequiredArgument): return await ctx.send( - f"{ctx.author.mention}: You gave incomplete " f"arguments. {help_text}" + f"{ctx.author.mention}: You gave incomplete arguments. {help_text}" ) diff --git a/config_template.py b/config_template.py index 18b2eba..dbcb7d5 100644 --- a/config_template.py +++ b/config_template.py @@ -171,7 +171,7 @@ suspect_ignored_words = [ "tcptx", "udptx", "ctx", - "jit's" + "jit's", ] # == For cogs.links ==