diff --git a/nardco.py b/nardco.py index 94d72e28afc9b07329e019861e4f6d7e22000e69..0b750956a1311ff355cdf81a7bfee9e639000430 100755 --- a/nardco.py +++ b/nardco.py @@ -201,7 +201,7 @@ class Boooob(ircbot.SingleServerIRCBot): if "Titch" in personne and "leave" in message and "nardco" in message: serv.part(canal) - if reponse is not None and reponse in message : + if reponse is not None and fuzz.ratio(message, reponse) > 60 : serv.privmsg(canal, personne + " a trouvé la reponse ! Bien joué !") reponse = None @@ -256,7 +256,8 @@ class Boooob(ircbot.SingleServerIRCBot): reponse = datas['reponse'].lower() choix = datas['choix'] question= datas['question'] - serv.privmsg(canal, "Question : {0}, Choix : {1}".format(question.format('utf8'), ', '.join(choix).format('utf8'))) + serv.privmsg(canal, "Question : {0}".format(question.format('utf8')) + serv.privmsg(canal, "Choix: {0}".format(', '.join(choix).format('utf8'))) elif cmd == "ecole" : try :