From 68093c7abe73cef6ddcf7f87cf8893fc1921183d Mon Sep 17 00:00:00 2001 From: BFlow Date: Sun, 17 Nov 2019 18:47:20 +0100 Subject: [PATCH] test de la fonction slap --- kabot/kabot/kabot.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/kabot/kabot/kabot.py b/kabot/kabot/kabot.py index 01fbf60..d57492d 100644 --- a/kabot/kabot/kabot.py +++ b/kabot/kabot/kabot.py @@ -84,8 +84,13 @@ class Mybot(commands.Cog): await ctx.channel.send("j'ai %s lignes dans mon stock" % nb_lines) @commands.command(help='slap this ass') - async def slap(self, ctx, user): - await ctx.channel.send("j'attrape %s est lui met une tarte!" % user) + async def slap(self, ctx, user=None): + if not user: + members = ctx.guild.members + for member in members: + await ctx.channel.send('%s : %s' % (member.nick,member.Status)) + + #await ctx.channel.send("j'attrape %s est lui met une tarte!" % user) @commands.command(help="optionnal args : [livre] [character]") async def kaamelott(self, ctx, *args):