From 8818500a48d21f73f5e3598bfea59374c404b7a5 Mon Sep 17 00:00:00 2001 From: Loris TICHADOU <loris.tichadou@ensiie.fr> Date: Fri, 25 Jun 2021 09:49:16 +0000 Subject: [PATCH] Update nardco.py --- nardco.py | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/nardco.py b/nardco.py index 4fafd50..e3cb263 100755 --- a/nardco.py +++ b/nardco.py @@ -70,6 +70,9 @@ scores = {} tour = 0 total = 0 +# Pacho +pachoTime = time.time() + def isCommande(string): return string[0] == config.cmdCarac @@ -133,6 +136,7 @@ class Boooob(ircbot.SingleServerIRCBot): global tour global scores global total + global pachoTime canal = ev.target() @@ -271,7 +275,7 @@ class Boooob(ircbot.SingleServerIRCBot): cmds = [ 'help', 'bdsm', 'haddock', 'useless', 'quizz', 'ecole', 'ffs', 'thanos', 'chuck', 'roll', 'rateau', 'viieux', 'kohlanta', 'new', 'del', 'get', 'debat', 'pipo', 'np', 'commit', 'zertyu', 'getsub', 'sub', 'delsub', - 'addsub', 'reddit', "gratuit" + 'addsub', 'reddit', "gratuit", "pacho" ] most_likely = (cmd, 0) @@ -291,9 +295,6 @@ class Boooob(ircbot.SingleServerIRCBot): result = "{0}, {1}".format(result, user) serv.privmsg(canal, result) - if 'spoil' in args or 'spoil' in cmd: - serv.privmsg(canal, "Le risque de spoil est present. je fais pas ça.") - elif cmd == "help": if len(message.split(" ")) > 1: if "reddit" in message.split(" ")[1]: @@ -309,6 +310,11 @@ class Boooob(ircbot.SingleServerIRCBot): else: serv.privmsg(canal, ("Commandes disponibles :{0}").format(', '.join(cmds))) + elif cmd == "pacho" : + difference = time.time() - pachoTime + pachoTime = time.time() + serv.privmsg(canal, "Et dire que ca faisait seulement" + difference + " secondes que Pacho n'avait pas fait d'allusions") + elif cmd == "haddock": serv.privmsg(canal, haddock()) -- GitLab