aboutsummaryrefslogtreecommitdiffstats
path: root/bot/seasons/evergreen/8bitify.py
diff options
context:
space:
mode:
authorGravatar RohanJnr <[email protected]>2019-10-02 09:39:10 +0530
committerGravatar RohanJnr <[email protected]>2019-10-02 09:39:10 +0530
commitcd5842811f92bd5c82a164d33ad71a9c7c172e57 (patch)
tree4a15827a3d94cbc78fa8a9a5b47cdd57283f304e /bot/seasons/evergreen/8bitify.py
parentWorked on the requested changes and also made a few other changes: (diff)
parentMerge branch 'master' into trivia_quiz (diff)
Merge branch 'trivia_quiz' of https://github.com/RohanJnr/seasonalbot into trivia_quiz
Diffstat (limited to 'bot/seasons/evergreen/8bitify.py')
-rw-r--r--bot/seasons/evergreen/8bitify.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/bot/seasons/evergreen/8bitify.py b/bot/seasons/evergreen/8bitify.py
index 54db71db..60062fc1 100644
--- a/bot/seasons/evergreen/8bitify.py
+++ b/bot/seasons/evergreen/8bitify.py
@@ -13,17 +13,17 @@ class EightBitify(commands.Cog):
@staticmethod
def pixelate(image: Image) -> Image:
- """Takes an image and pixelates it"""
+ """Takes an image and pixelates it."""
return image.resize((32, 32)).resize((1024, 1024))
@staticmethod
def quantize(image: Image) -> Image:
- """Reduces colour palette to 256 colours"""
+ """Reduces colour palette to 256 colours."""
return image.quantize(colors=32)
@commands.command(name="8bitify")
async def eightbit_command(self, ctx: commands.Context) -> None:
- """Pixelates your avatar and changes the palette to an 8bit one"""
+ """Pixelates your avatar and changes the palette to an 8bit one."""
async with ctx.typing():
image_bytes = await ctx.author.avatar_url.read()
avatar = Image.open(BytesIO(image_bytes))