From d38b1a80653c4f9f3ebb045d12f418555e557e2b Mon Sep 17 00:00:00 2001 From: Ave Ozkal Date: Tue, 25 Dec 2018 14:43:23 +0300 Subject: [PATCH] speak: add --- cogs/admin.py | 7 ------- cogs/mod.py | 14 ++++++++++++++ 2 files changed, 14 insertions(+), 7 deletions(-) diff --git a/cogs/admin.py b/cogs/admin.py index 777a806..199b960 100644 --- a/cogs/admin.py +++ b/cogs/admin.py @@ -18,13 +18,6 @@ class AdminCog: def check_if_bot_manager(ctx): return any(r.id == config.bot_manager_role_id for r in ctx.author.roles) - @commands.guild_only() - @commands.check(check_if_staff) - @commands.command(aliases=['echo'], hidden=True) - async def say(self, ctx, *, the_text: str): - """Repeats a given text, staff only.""" - await ctx.send(the_text) - @commands.guild_only() @commands.check(check_if_bot_manager) @commands.command(name='exit', hidden=True) diff --git a/cogs/mod.py b/cogs/mod.py index dad5b52..f29122e 100644 --- a/cogs/mod.py +++ b/cogs/mod.py @@ -221,6 +221,20 @@ class ModCog: await log_channel.send(chan_message) await ctx.send(f"{safe_name} is now b&. 👍") + @commands.guild_only() + @commands.check(check_if_staff) + @commands.command(aliases=['echo']) + async def say(self, ctx, *, the_text: str): + """Repeats a given text, staff only.""" + await ctx.send(the_text) + + @commands.guild_only() + @commands.check(check_if_staff) + @commands.command() + async def speak(self, ctx, channel: discord.TextChannel, *, the_text: str): + """Repeats a given text in a given channel, staff only.""" + await channel.send(the_text) + @commands.guild_only() @commands.bot_has_permissions(ban_members=True) @commands.check(check_if_staff)