From 5fbdd201079cf66a06205877de26ff727a042cf2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20=C3=81lvarez?= Date: Wed, 19 Jul 2017 16:24:14 +0200 Subject: [PATCH] rate limit for guild spam, and m+ format --- guild.py | 2 ++ mythics.py | 3 ++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/guild.py b/guild.py index dcdee85..0e48430 100755 --- a/guild.py +++ b/guild.py @@ -62,3 +62,5 @@ for news in g["news"]: continue wh.send(push) + + time.sleep(2) # prevent rate limit, for example with boss FK diff --git a/mythics.py b/mythics.py index d696732..393a042 100755 --- a/mythics.py +++ b/mythics.py @@ -84,9 +84,10 @@ for zone, instance in conf.zones.items(): #tip = "(piedra +{0} por {1})".format(chests, delta) tip = "(piedra +{0})".format(chests, delta) - msg = "{6} **[{0}](<{7}>) +{1}** hecha en **{2}** {3} por {4} / **rank {5}** de Dun Modr".format(instance, lvl, record, tip, " ".join(party), pos, affix, warcraft_api.format(zone)) + msg = ":mega: **[{0}](<{5}>) +{1}** hecha en **{2}** {3}, **rank {4}** de Dun Modr".format(instance, lvl, record, tip, pos, warcraft_api.format(zone)) #r.rpush("bot:rss:new", msg) #print(msg) + wh.add_embed(webhook.embed(title=" ".join(party))) wh.send(msg) except: