summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefan Beller <stefanbeller@googlemail.com>2011-08-24 19:33:31 +0200
committerStefan Beller <stefanbeller@googlemail.com>2011-08-24 19:33:31 +0200
commitcbd465195dd81fa36a1c7f86ca56b4a4e705351f (patch)
tree03d8f0c2b1e6460947e063e780dc199b46cd3c03
parentce51681100e5ea18da7e2171f523296c28f0cda1 (diff)
downloadmanamarket-cbd465195dd81fa36a1c7f86ca56b4a4e705351f.tar.gz
manamarket-cbd465195dd81fa36a1c7f86ca56b4a4e705351f.tar.bz2
manamarket-cbd465195dd81fa36a1c7f86ca56b4a4e705351f.tar.xz
manamarket-cbd465195dd81fa36a1c7f86ca56b4a4e705351f.zip
Adding !list for blocked users; introduce config.admin
-rw-r--r--config.py.template1
-rwxr-xr-xmain.py6
2 files changed, 4 insertions, 3 deletions
diff --git a/config.py.template b/config.py.template
index df11a32..2d3155e 100644
--- a/config.py.template
+++ b/config.py.template
@@ -5,3 +5,4 @@ account = ""
password = ""
relist_time = 604800 # Time in seconds before an item needs to be relisted.
character = 0 #slot character is in, 0 for first, 1 for second, 2 for third
+admin = "Admin <admin@email.com>"
diff --git a/main.py b/main.py
index 0adf113..a14dbb2 100755
--- a/main.py
+++ b/main.py
@@ -45,11 +45,11 @@ def process_whisper(nick, msg, mapserv):
if user != -10:
if int(user.get("accesslevel")) == -1: # A user who has been blocked for abuse.
if int(user.get("used_slots")) == 0 and int(user.get("money")) == 0:
- mapserv.sendall(whisper(nick, "You can no longer use the bot. If you feel this is in error, please contact <administrator>."))
+ mapserv.sendall(whisper(nick, "You can no longer use the bot. If you feel this is in error, please contact" + config.admin))
return
- allowed_commands = ['!money', '!help', '!getback' ]
+ allowed_commands = ['!money', '!help', '!getback', '!info' ]
if not broken_string[0] in allowed_commands:
- mapserv.sendall(whisper(nick, "Your access level has been set to blocked! If you feel this is in error, please contact <administrator>."))
+ mapserv.sendall(whisper(nick, "Your access level has been set to blocked! If you feel this is in error, please contact" + config.admin))
mapserv.sendall(whisper(nick, "Though, you still can do the following: "+str(allowed_commands))
return