From 65fad272530fcf8cf1114e3e74115f85774f9099 Mon Sep 17 00:00:00 2001 From: leo60228 Date: Sun, 3 Mar 2019 12:23:11 -0500 Subject: [PATCH] Add .communitycount --- cogs/basic.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/cogs/basic.py b/cogs/basic.py index 364030e..c579743 100644 --- a/cogs/basic.py +++ b/cogs/basic.py @@ -13,6 +13,14 @@ class Basic(Cog): """Says hello. Duh.""" await ctx.send(f"Hello {ctx.author.mention}!") + @commands.guild_only() + @commands.command() + async def communitycount(self, ctx): + """Prints the community member count of the server.""" + community = ctx.guild.get_role(config.named_roles["community"]) + await ctx.send(f"{ctx.guild.name} has " + f"{len(community.members)} community members!") + @commands.guild_only() @commands.command() async def membercount(self, ctx):