diff options
author | Livio Recchia <recchialivio@libero.it> | 2020-04-17 22:47:14 +0200 |
---|---|---|
committer | Livio Recchia <recchialivio@libero.it> | 2020-04-17 22:47:14 +0200 |
commit | 8c0c1f98268de8e8c3de183ea85abad67a4e41ed (patch) | |
tree | 0b6cbb0c667b70e17020b433b3a892ee0c802a5b /plugins/shop.py | |
parent | 015cbad937f7be87813c539563771ef5a7b6f064 (diff) | |
download | manachat-8c0c1f98268de8e8c3de183ea85abad67a4e41ed.tar.gz manachat-8c0c1f98268de8e8c3de183ea85abad67a4e41ed.tar.bz2 manachat-8c0c1f98268de8e8c3de183ea85abad67a4e41ed.tar.xz manachat-8c0c1f98268de8e8c3de183ea85abad67a4e41ed.zip |
Used python instead of python2 in auto.sh
Diffstat (limited to 'plugins/shop.py')
-rwxr-xr-x | plugins/shop.py | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/plugins/shop.py b/plugins/shop.py index adeb66f..d45dff2 100755 --- a/plugins/shop.py +++ b/plugins/shop.py @@ -38,8 +38,8 @@ shop_admins = None # FIXME Put on a specified library def preloadArray(nfile): try: - file = open(nfile, "r") array=[] + file = open(nfile, "r") for x in file.readlines(): x = x.replace("\n", "") x = x.replace("\r", "") @@ -54,7 +54,7 @@ sell_greetings = [ ] buy_greetings = [ - "Okay! Let's see what you've got to sell!", + "Okay, {0}! Let's see what you've got to sell!", ] sell_greetings = preloadArray("config/sellGreetings.txt") @@ -547,6 +547,8 @@ def load_shop_list(config): shoplist_txt = config.get('shop', 'shoplist_txt') if not os.path.isfile(shoplist_txt): shoplog.warning('shoplist file not found : %s', shoplist_txt) + print 'Error: shoplist file not found :' + shoplist_txt + os._exit(255) return with open(shoplist_txt, 'r') as f: @@ -574,6 +576,10 @@ def init(config): shop_admins_file = config.get('shop', 'admins_file') if os.path.isfile(shop_admins_file): shop_admins = PlayerList(shop_admins_file) + else: + shoplog.warning('shop admin file not found : %s', shop_admins_file) + print 'Error: shop admin file not found :' + shop_admins_file + badge.is_shop = True |