def __init__(self, alerts): """Generate an embed containing the list of alerts Parameters: ----------- l_alerts: iterable of :class:`warframe.parser.alerts.Alerts` The list of alerts. platform: str [Optional] The platform those alerts are on. Attributes: ----------- _desc_gotl: str The description present if the alert is a gift of the lotus """ self._desc_gotl = "Gift of The Lotus" title = "Alerts" Embed.__init__(self, title=title, type="rich") if alerts is not None: for alert in alerts: self.add_alert(alert) self.colour = Colour.gold()
def __init__(self, synthesis, name): name = name.title() title = f"Synthesis Target - {name}" Embed.__init__(self, title=title, type="rich") if synthesis is not None: for target in synthesis: if target['name'] == name: self.add_target(target) self.colour = Colour.gold()
def __init__(self, cetus, earth, vallis): title = "Timers" Embed.__init__(self, title=title, type="rich") self.colour = Colour.dark_orange() self.addCetusTimer(cetus) self.addEarthTimer(earth) self.addVallisTimer(vallis)
def __init__(self, sortie): boss = sortie['boss'] title = "Sortie: " + boss Embed.__init__(self, title=title, type="rich") if sortie['expired']: self.description = "Expired" else: self.description = "Ends in " + sortie['eta'] self.colour = Colour.dark_orange() for mission in sortie['variants']: self.addFieldMission(mission)
def __init__(self, t, name, url_name): name = name.title() self.id = "" self.assets_url = "https://warframe.market/static/assets/" title = f"warframe.market data - {name}" Embed.__init__(self, title=title, type="rich") self.colour = Colour.gold() self.url_name = url_name self.api_url = f"https://api.warframe.market/v1/items/{url_name}" self.add_desc() if t in ['buy', 'b']: self.add_buy() else: self.add_sell()
def __init__(self, fissures): """Generate an embed containing the list of fissures Parameters: ----------- l_fissures: iterable of :class:`warframe.parser.fissure.Fissure` The list of fissures. platform: str [Optional] The platform those fissures are on. """ title = "Fissures" Embed.__init__(self, title = title, type = "rich") self.url = "http://warframe.wikia.com/wiki/Void_Fissure" for fissure in fissures: self.add_fissure(fissure) self.colour = Colour.teal()
def __init__(self, nw, daily=False): color = int("0x10C4BC", 0) if not daily: mission_str = "Weekly Challenges" else: mission_str = "Daily Challenges" self.daily = daily title = f"Nightwave Season {nw['season']} - {mission_str}" Embed.__init__(self, title=title, type="rich") nightwave_url = "https://warframe.fandom.com/wiki/Nightwave" nightwave_banner = "https://vignette.wikia.nocookie.net/warframe/images/e/e0/NightwaveSyndicate.png" self.set_thumbnail(url=nightwave_banner) self.url = nightwave_url self.colour = color for challenge in nw['activeChallenges']: if not daily and 'isDaily' not in challenge: self.addChallenge(challenge) elif daily and 'isDaily' in challenge: self.addChallenge(challenge)
def __init__(self, baro): node = baro['location'] baro_url = "http://warframe.wikia.com/wiki/Baro_Ki%27Teer" baro_image = "https://vignette.wikia.nocookie.net/warframe/images/1/12/BaroBanner.png" color = int("0x10C4BC", 0) title = f"[PC] Baro Ki'Teer - {node}" Embed.__init__(self, title=title, type="rich") if baro['active']: self.description = f"Leave in {baro['endString']}" else: self.description = f"Arrive in {baro['startString']}" self.url = baro_url self.set_thumbnail(url=baro_image) self.colour = color self._unlocalized_str = "/Lotus/" self._separator = "/" self._placeholder = "[PH] " for item in baro['inventory']: self.addItem(item)