Prepare hooks to be used for other things than Message

This commit is contained in:
nemunaire 2014-09-11 21:20:56 +02:00
commit 8c52f75b6a
16 changed files with 171 additions and 136 deletions

View file

@ -34,7 +34,7 @@ def help_full():
return "!conjugaison <tens> <verb>: give the conjugaison for <verb> in <tens>."
@hook("cmd_hook", "conjugaison", help="!conjugaison <tens> <verb>: give the conjugaison for <verb> in <tens>.")
@hook("cmd_hook", "conjugaison")
def cmd_conjug(msg):
if len(msg.cmds) < 3:
raise IRCException("donne moi un temps et un verbe, et je te donnerai sa conjugaison!")