From 60953207829213908ed020d06458a6683ecd8e64 Mon Sep 17 00:00:00 2001 From: jcao219 Date: Mon, 16 Jul 2012 11:16:26 -0500 Subject: [PATCH] fix bug with debug mode and allowing commands --- botconfig.py.example | 2 +- modules/wolfgame.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/botconfig.py.example b/botconfig.py.example index 6b6b0cd..79c1794 100644 --- a/botconfig.py.example +++ b/botconfig.py.example @@ -14,7 +14,7 @@ IGNORE_HIDDEN_COMMANDS = True # Ignore commands sent to @#channel or +#channel ALLOW_NOTICE_COMMANDS = False # allow /notice #channel !command to be interpreted as a command ALLOW_PRIVATE_NOTICE_COMMANDS = False # allow !command's from /notice (Private) -ALLOWED_NORMAL_MODE_COMMANDS = [] +ALLOWED_NORMAL_MODE_COMMANDS = [] # debug mode commands to be allowed in normal mode OWNERS = ("unaffiliated/wolfbot_admin1",) # the comma is required at the end if there is one owner ADMINS = ("unaffiliated/wolfbot_admin2", "unaffiliated/wolfbot_admin3") # glob syntax supported (wildcards) diff --git a/modules/wolfgame.py b/modules/wolfgame.py index 6bc86b3..922719c 100644 --- a/modules/wolfgame.py +++ b/modules/wolfgame.py @@ -2888,7 +2888,7 @@ if botconfig.DEBUG_MODE or botconfig.ALLOWED_NORMAL_MODE_COMMANDS: if var.PHASE not in ('none','join'): chk_win(cli) -if botconfig.ALLOWED_NORMAL_MODE_COMMANDS: +if botconfig.ALLOWED_NORMAL_MODE_COMMANDS and not botconfig.DEBUG_MODE: for comd in list(COMMANDS.keys()): if (comd not in before_debug_mode_commands and comd not in botconfig.ALLOWED_NORMAL_MODE_COMMANDS):