Move portraits ot a new method and then use that picture if you select the spawns for a single boss
All checks were successful
Build and push / changes (push) Successful in 4s
Build and push / Lint-Python (push) Successful in 2s
Build and push / Build-and-Push-Docker (push) Successful in 20s
Build and push / post-status-to-discord (push) Successful in 2s
Build and push / sync-argocd-app (push) Successful in 2s
All checks were successful
Build and push / changes (push) Successful in 4s
Build and push / Lint-Python (push) Successful in 2s
Build and push / Build-and-Push-Docker (push) Successful in 20s
Build and push / post-status-to-discord (push) Successful in 2s
Build and push / sync-argocd-app (push) Successful in 2s
This commit is contained in:
parent
9d544e3bf7
commit
8c46a898f9
@ -147,10 +147,15 @@ class Tarkov(commands.Cog):
|
||||
type="rich",
|
||||
)
|
||||
embed.set_author(name="🎲 Boss Spawn chances by map 🎲")
|
||||
embed.set_thumbnail(url="https://i.ytimg.com/vi/Yis5rmgo_bM/maxresdefault.jpg")
|
||||
|
||||
if boss_name:
|
||||
for item in tarkov.get_boss_pictures():
|
||||
if item["name"] == boss_name:
|
||||
embed.set_thumbnail(url=item["imagePortraitLink"])
|
||||
break
|
||||
|
||||
embed.set_author(name=f"🎲 Spawn chance for {boss_name} 🎲")
|
||||
embed.set_thumbnail(url="https://i.ytimg.com/vi/Yis5rmgo_bM/maxresdefault.jpg")
|
||||
|
||||
levels = tarkov.get_tarkov_boss_info()
|
||||
|
||||
@ -217,14 +222,7 @@ class Tarkov(commands.Cog):
|
||||
# )
|
||||
# break
|
||||
|
||||
portraits = tarkov.query_tarkov_api(
|
||||
"""{
|
||||
bosses(lang: en, gameMode:pve) {
|
||||
name
|
||||
imagePortraitLink
|
||||
}
|
||||
}"""
|
||||
)["bosses"]
|
||||
portraits = tarkov.get_boss_pictures()
|
||||
|
||||
for boss in portraits:
|
||||
if boss["name"] == boss_name:
|
||||
|
@ -18,6 +18,17 @@ def query_tarkov_api(query):
|
||||
).json()["data"]
|
||||
|
||||
|
||||
def get_boss_pictures():
|
||||
return query_tarkov_api(
|
||||
"""{
|
||||
bosses(lang: en, gameMode:pve) {
|
||||
name
|
||||
imagePortraitLink
|
||||
}
|
||||
}"""
|
||||
)["bosses"]
|
||||
|
||||
|
||||
def get_tarkov_boss_info():
|
||||
"""
|
||||
Returns a dict of boss spawn chances per map, and their escorts
|
||||
|
Loading…
x
Reference in New Issue
Block a user