summaryrefslogtreecommitdiff
path: root/main.py
diff options
context:
space:
mode:
authorDipesh Amin <yaypunkrock@gmail.com>2011-08-24 15:17:15 +0100
committerDipesh Amin <yaypunkrock@gmail.com>2011-08-24 15:17:15 +0100
commitcb31905b26679c5a0c9a7335943d0d1afe4547bc (patch)
treecc7083bb9fbba4f4a85e91e3d239ba4a5ca51162 /main.py
parent80d3df45dc769fe7e553caaea2ab938e94cbf07b (diff)
downloadmanamarket-cb31905b26679c5a0c9a7335943d0d1afe4547bc.tar.gz
manamarket-cb31905b26679c5a0c9a7335943d0d1afe4547bc.tar.bz2
manamarket-cb31905b26679c5a0c9a7335943d0d1afe4547bc.tar.xz
manamarket-cb31905b26679c5a0c9a7335943d0d1afe4547bc.zip
Let a blocked user retrieve items/money.
Diffstat (limited to 'main.py')
-rwxr-xr-xmain.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/main.py b/main.py
index 89524e6..75afabf 100755
--- a/main.py
+++ b/main.py
@@ -44,8 +44,9 @@ def process_whisper(nick, msg, mapserv):
if user != -10:
if int(user.get("accesslevel")) == -1: # A user who has been blocked for abuse.
- mapserv.sendall(whisper(nick, "You can no longer use the bot. If you feel this is in error, please contact <administrator>."))
- return
+ 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>."))
+ return
if msg == "!list":
# Sends the list of items for sale.
@@ -489,7 +490,7 @@ def process_whisper(nick, msg, mapserv):
mapserv.sendall(whisper(nick, "Syntax incorrect."))
return
- if int(user.get("accesslevel")) < 5:
+ if int(user.get("accesslevel")) < 5 and int(user.get("accesslevel")) > 0:
mapserv.sendall(whisper(nick, "You don't have the correct permissions."))
return