rename collage method

This commit is contained in:
yuki 2025-10-08 23:20:33 -03:00
parent 8b496f7b12
commit 6c919081c7
2 changed files with 12 additions and 4 deletions

8
commands/_top.py Normal file
View file

@ -0,0 +1,8 @@
import nerimity
import bot
def setup(bot: bot.Bot):
@bot.command(name="topartists", aliases=["ta","topartist"])
@bot.slash_command(name="topartists")
def topartists(ctx: nerimity.Context, timeframe)

View file

@ -8,7 +8,7 @@ import utils as u
# from catbox_async_uploader.catbox_async_uploader.enums import LitterboxDuration
# from pyzxz import ZeroXZero
async def create_chart(bot: bot.Bot, ctx: nerimity.Context, entity: str, size: str = "3x3", timeframe: str = "7day", username: str = None):
async def send_collage(bot: bot.Bot, ctx: nerimity.Context, entity: str, size: str = "3x3", timeframe: str = "7day", username: str = None):
temp_msg = None
if 'x' not in size:
@ -96,7 +96,7 @@ def setup(bot: bot.Bot):
@bot.command(name="chart", aliases=["c", "chartalbum", "albumchart", "collage"])
@bot.slash_command(name="chartalbum", description="Generate an album collage.")
async def chartalbum(ctx: nerimity.Context, size: str = "3x3", timeframe: str = "7day", username: str = None):
await create_chart(
await send_collage(
bot = bot,
ctx = ctx,
entity = "album",
@ -108,7 +108,7 @@ def setup(bot: bot.Bot):
@bot.command(name="artistchart", aliases=["ac", "ca", "chartartist", "artistcollage"])
@bot.slash_command(name="chartartist", description="Generate an artist collage.")
async def chartartist(ctx: nerimity.Context, size: str = "3x3", timeframe: str = "7day", username: str = None):
await create_chart(
await send_collage(
bot = bot,
ctx = ctx,
entity = "artist",
@ -120,7 +120,7 @@ def setup(bot: bot.Bot):
@bot.command(name="trackchart", aliases=["tc", "ct", "charttrack", "chartracks", "songchart", "chartsong", "trackcollage", "songcollage"])
@bot.slash_command(name="charttrack", description="Generate a track/song collage.")
async def charttrack(ctx: nerimity.Context, size: str = "3x3", timeframe: str = "7day", username: str = None):
await create_chart(
await send_collage(
bot = bot,
ctx = ctx,
entity = "track",