import disnake
from disnake import File
from disnake.ext import commands
from easy_pil import Editor, load_image_async, Font
class Testing(commands.Cog):
def __init__(self, bot):
self.bot = bot
@commands.slash_command(description="Test")
async def testing(self, inter, member: disnake.Member = None):
background = Editor("wlcbg.jpg")
profile_image = await load_image_async(str(member.display_avatar.url))
profile = Editor(profile_image).resize( (150, 150)).circle_image()
poppins = Font.poppins(size=50, variant="bold")
poppins_small = Font.poppins(size=20, variant="light")
background.paste(profile, (325, 90))
background.ellipse((325, 90), 150, 150, outline="gold", stroke_width=4)
background.text((400, 260), f"WELCOME TO {member.guild.name}", color="white", font=poppins, align="center")
background.text((400, 325), f"{member.name}#{member.discriminator}", color="white", font=poppins_small, align="center")
file = File(fp=background.image_bytes, filename="wlcbg.jpg")
profile.show()
await inter.send(file=file)
def setup(bot):
bot.add_cog(Testing(bot))
ошибки нет не в консоли не в чате при написании команды