Skip to content

Commit

Permalink
ClashKing v4
Browse files Browse the repository at this point in the history
  • Loading branch information
MagicTheDev committed Jan 29, 2024
1 parent 43b342d commit 9bb88a4
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions commands/legends/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,7 @@ async def fetch(url, session):
await session.close()
badge = Image.open(responses[0])
size = 275, 275
badge.thumbnail(size, Image.ANTIALIAS)
badge.thumbnail(size, Image.LANCZOS)
A = badge.getchannel('A')
newA = A.point(lambda i: 128 if i > 0 else 0)
badge.putalpha(newA)
Expand Down Expand Up @@ -255,7 +255,7 @@ async def fetch(url, session):
except Exception:
globe = Image.open("assets/country_flags/globe.png")
size = 75, 75
globe.thumbnail(size, Image.ANTIALIAS)
globe.thumbnail(size, Image.LANCZOS)
globe.save("assets/country_flags/globe2.png", "PNG")
globe = Image.open("assets/country_flags/globe2.png")
poster.paste(globe, (90, 340), globe.convert("RGBA"))
Expand All @@ -267,7 +267,7 @@ async def fetch(url, session):
except Exception:
globe = Image.open(f"assets/country_flags/{player.ranking.country_code.lower()}.png")
size = 80, 80
globe.thumbnail(size, Image.ANTIALIAS)
globe.thumbnail(size, Image.LANCZOS)
globe.save(f"assets/country_flags/{player.ranking.country_code.lower()}2.png", "PNG")
globe = Image.open(f"assets/country_flags/{player.ranking.country_code.lower()}2.png")

Expand Down

0 comments on commit 9bb88a4

Please sign in to comment.