Skip to content
This repository has been archived by the owner on Sep 17, 2024. It is now read-only.

Commit

Permalink
Make games case insensitive
Browse files Browse the repository at this point in the history
  • Loading branch information
ASmallSquishySquid committed Apr 24, 2024
1 parent 981dd5a commit 459f5a0
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions cogs/events.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,12 +49,12 @@ async def on_presence_update(self, before: discord.Member, after: discord.Member
channel = await self.bot.fetch_channel(channel_id)

old_playing = [game.name for game in before.activities if str(game.type) == "ActivityType.playing"]
new_playing = [game.name for game in after.activities if str(game.type) == "ActivityType.playing" and game.name not in old_playing]
new_playing = [game.name.lower() for game in after.activities if str(game.type) == "ActivityType.playing" and game.name not in old_playing]

if "Overwatch 2" in new_playing:
if "overwatch 2" in new_playing:
await channel.send(f"<@{os.getenv('BLIST_ID')}> want to do some watching over?")

if "Valorant" in new_playing:
if "valorant" in new_playing:
await channel.send(f"<@{os.getenv('BLIST_ID')}> Val?")

async def setup(bot: commands.Bot):
Expand Down

0 comments on commit 459f5a0

Please sign in to comment.