First pass at boss spawn monitoring
All checks were successful
Build and push / changes (push) Successful in 4s
Build and push / Lint-Python (push) Successful in 6s
Build and push / Build-and-Push-Docker (push) Successful in 1m37s
Build and push / sync-argocd-app (push) Successful in 3s

This commit is contained in:
Luke R 2024-11-06 10:36:57 -08:00
parent 74729a101f
commit 5d8d96213b

View File

@ -27,20 +27,20 @@ class Tarkov(commands.Cog):
# Wait until the bot is ready before we actually start executing code
await self.bot.wait_until_ready()
levels = tarkov.tarkov_boss_info()
most_recent_spawns = tarkov.tarkov_boss_info()
if os.path.exists("/tmp/boss_spawns.txt"):
current_spawns = eval(open("/tmp/boss_spawns.txt", "r").read())
spawn_data = eval(open("/tmp/boss_spawns.txt", "r").read())
if levels != current_spawns:
if most_recent_spawns != spawn_data:
print("Boss spawns have changed")
embed = discord.Embed(
description="-------", color=discord.Color.blue(), type="rich"
)
embed.set_author(name="🎲 Boss Spawns have updated 🎲")
for key, value in current_spawns.items():
for key, value in most_recent_spawns.items():
embed.add_field(
name=key,
value="\n".join(