added enemy level information
This commit is contained in:
parent
d6ddc5e693
commit
4037d41351
|
@ -107,6 +107,8 @@ class WarBot(irc.IRCClient):
|
||||||
info = alert["MissionInfo"]
|
info = alert["MissionInfo"]
|
||||||
node = self.solNodes[info["location"]]
|
node = self.solNodes[info["location"]]
|
||||||
mission_type = self.missionTypes[info["missionType"]]["value"]
|
mission_type = self.missionTypes[info["missionType"]]["value"]
|
||||||
|
minLvl = info["minEnemyLevel"]
|
||||||
|
maxLvl = info["maxEnemyLevel"]
|
||||||
credits = info["missionReward"].get("credits")
|
credits = info["missionReward"].get("credits")
|
||||||
items = info["missionReward"].get("items", [])
|
items = info["missionReward"].get("items", [])
|
||||||
if items:
|
if items:
|
||||||
|
@ -125,11 +127,12 @@ class WarBot(irc.IRCClient):
|
||||||
|
|
||||||
message = "\x0300[\x0305ALERT\x0300] " \
|
message = "\x0300[\x0305ALERT\x0300] " \
|
||||||
+ f"\x0310Location\x03: \x0312{node['value']}\x03 | " \
|
+ f"\x0310Location\x03: \x0312{node['value']}\x03 | " \
|
||||||
+ f"\x0310Mission Type\x03: \x0312{mission_type}\x03 | " \
|
+ f"\x0310Mission Type\x03: \x0312{mission_type}\x03 " \
|
||||||
|
+ f"(\x0307{minLvl}\x03-\x0307{maxLvl}\x03) | " \
|
||||||
+ f"\x0310Expiry\x03: \x0308{expire_diff // 3600}h" \
|
+ f"\x0310Expiry\x03: \x0308{expire_diff // 3600}h" \
|
||||||
+ f"{expire_diff % 3600 // 60}m\x03 " \
|
+ f"{expire_diff % 3600 // 60}m\x03 " \
|
||||||
+ f"(\x0308{time.strftime('%H:%M', expire_t)}\x03)" \
|
+ f"(\x0308{time.strftime('%H:%M', expire_t)}\x03) | " \
|
||||||
+ f" | \x0310Credits\x03: \x0312{credits}\x03"
|
+ f"\x0310Credits\x03: \x0312{credits}\x03"
|
||||||
if items:
|
if items:
|
||||||
message += f" | \x0310Items: \x0312{', '.join(items)}\x03"
|
message += f" | \x0310Items: \x0312{', '.join(items)}\x03"
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user