From: Christian Heller <c.heller@plomlompom.de>
Date: Tue, 23 Feb 2016 21:12:35 +0000 (+0100)
Subject: Plugin: Don't use global on variables changed by plugin itself.
X-Git-Tag: tce~175
X-Git-Url: https://plomlompom.com/repos/%7B%7B%20web_path%20%7D%7D/decks/booking/%7B%7Bdb.prefix%7D%7D/%7B%7Btodo.comment%7D%7D?a=commitdiff_plain;h=dc6fe5e5b871e529cc0079458c80b58b2883d053;p=plomrogue

Plugin: Don't use global on variables changed by plugin itself.
---

diff --git a/plugins/server/PleaseTheIslandGod.py b/plugins/server/PleaseTheIslandGod.py
index 2aceb19..3b571c7 100644
--- a/plugins/server/PleaseTheIslandGod.py
+++ b/plugins/server/PleaseTheIslandGod.py
@@ -79,7 +79,8 @@ def make_world(seed):
     strong_write(io_db["file_out"], "NEW_WORLD\n")
 
 def thingproliferation(t, prol_map):
-    global directions_db, new_Thing, mv_yx_in_dir_legal
+    from server.new_thing import new_Thing
+    global directions_db, mv_yx_in_dir_legal
     prolscore = world_db["ThingTypes"][t["T_TYPE"]]["TT_PROLIFERATE"]
     if prolscore and \
       (world_db["ThingTypes"][t["T_TYPE"]]["TT_LIFEPOINTS"] == 0 or
@@ -261,7 +262,7 @@ def actor_drop(t):
 
 
 def actor_move(t):
-    global symbols_passable
+    from server.config.world_data import symbols_passable
     from server.build_fov_map import build_fov_map
     def decrement_lifepoints(t):
         t["T_LIFEPOINTS"] -= 1