diff options
author | Dipesh Amin <yaypunkrock@gmail.com> | 2011-09-01 21:22:00 +0100 |
---|---|---|
committer | Dipesh Amin <yaypunkrock@gmail.com> | 2011-09-01 21:22:35 +0100 |
commit | 1f48228e07461a7df84ef306bbadd8d4befed196 (patch) | |
tree | c44d104a61f8ed2618e3606ba0c7edf5358929f5 | |
parent | b1049b4b6d328740f306a1b67292ab68d5dade73 (diff) | |
download | manamarket-1f48228e07461a7df84ef306bbadd8d4befed196.tar.gz manamarket-1f48228e07461a7df84ef306bbadd8d4befed196.tar.bz2 manamarket-1f48228e07461a7df84ef306bbadd8d4befed196.tar.xz manamarket-1f48228e07461a7df84ef306bbadd8d4befed196.zip |
Fixes
-rwxr-xr-x | main.py | 3 | ||||
-rw-r--r-- | player.py | 5 |
2 files changed, 6 insertions, 2 deletions
@@ -260,7 +260,8 @@ def process_whisper(nick, msg, mapserv): mapserv.sendall(whisper(nick, data[0:len(data)-2]+".")) data = '' - mapserv.sendall(whisper(nick, data[0:len(data)-2]+".")) + if len(data) > 0: + mapserv.sendall(whisper(nick, data[0:len(data)-2]+".")) elif broken_string[0] == '!setslots': # Change the number of slots a user has - !setslots <slots> <name> @@ -6,6 +6,9 @@ This file is part of tradey, a trading bot in the mana world see www.themanaworld.org """ + +import copy + class Item: pass @@ -39,7 +42,7 @@ class Player: def check_inventory(self, user_tree, sale_tree): # Check the inventory state. - test_node = self.inventory.copy() + test_node = copy.deepcopy(self.inventory) for elem in sale_tree.root: item_found = False for item in test_node: |