From 5a64ce49832f27e3974261cde3b1fcf7c2a5405a Mon Sep 17 00:00:00 2001 From: blha303 Date: Thu, 4 Apr 2013 22:35:34 +0800 Subject: [PATCH] Updating .mcstatus to show correct colors. --- plugins/mctools.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/plugins/mctools.py b/plugins/mctools.py index bfcd811..4d10039 100755 --- a/plugins/mctools.py +++ b/plugins/mctools.py @@ -73,12 +73,13 @@ def mcstatus(inp, say=None): data = json.loads(request.replace("}", "").replace("{", "").replace("]", "}").replace("[", "{")) out = [] + out.append("\x039") # use a loop so we don't have to update it if they add more servers for server, status in data.items(): if status == "green": - out.append("{} is \x033\x02online\x02\x03".format(server)) + out.append("{} is \x033\x02online\x02\x039".format(server)) else: - out.append("{} is \x034\x02offline\x02\x03".format(server)) + out.append("{} is \x034\x02offline\x02\x039".format(server)) return ", ".join(out) + "."