home · contact · privacy
Client: Fix bugs in plugin infrastructure.
authorChristian Heller <c.heller@plomlompom.de>
Sun, 21 Feb 2016 11:24:43 +0000 (12:24 +0100)
committerChristian Heller <c.heller@plomlompom.de>
Sun, 21 Feb 2016 11:24:43 +0000 (12:24 +0100)
client/window_management.py
roguelike-client

index 9a50b296d22c7165ee9d757008801462e9d64090..610764b5402bf69fd83b57c5ad94243acf64b616 100644 (file)
@@ -95,6 +95,8 @@ def set_windows():
     curses.endwin()
     stdscr = curses.initscr()
     screen_size = stdscr.getmaxyx()
+    global windows
+    windows = []
     for config in windows_config:
         size = size_window(config["config"])
         window = Window(config["title"], config["func"], size)
index ed0ab745cea65434efa73c55bfe1269a689abaa3..4514946f7da145f44b4cae9680f289e34e7dc9a2 100755 (executable)
@@ -89,7 +89,7 @@ def read_message_queue():
             redraw_windows = True
         elif message == "WORLD_UPDATED":
             query_mapcell()
-        elif message == "PLUGIN":
+        elif message[:6] == "PLUGIN":
             str_plugin = message[7:]
             if (str_plugin.replace("_", "").isalnum()
                 and os.access("plugins/client/" + str_plugin + ".py",