Refactor command definitions across various cogs to replace hybrid commands with regular commands for improved consistency and clarity. Update command structures in moderation, music, and other cogs to enhance user experience and streamline command handling.
Some checks failed
CI / Bot (Python) (push) Successful in 12s
CI / Dashboard (Next.js) (push) Failing after 9s

This commit is contained in:
TheOnlyMace
2026-07-21 22:59:25 +02:00
parent a52d84467d
commit d24b810164
25 changed files with 436 additions and 90 deletions

View File

@@ -30,10 +30,25 @@ class Games(Cog):
def __init__(self, client: Axiom):
self.client = client
@commands.hybrid_group(
name="game",
description="Play mini-games with friends or the bot.",
fallback="help",
invoke_without_command=True,
)
@blacklist_check()
@ignore_check()
@commands.cooldown(1, 3, commands.BucketType.user)
@commands.guild_only()
async def game(self, ctx: Context):
"""Games root — use `/game <subcommand>` or `>game <subcommand>`."""
if ctx.subcommand_passed is None:
await ctx.send_help(ctx.command)
ctx.command.reset_cooldown(ctx)
@commands.hybrid_command(name="chess",
@game.command(name="chess",
help="Play Chess with a user.",
usage="Chess <user>")
usage="game chess <user>")
@blacklist_check()
@ignore_check()
@commands.cooldown(1, 3, commands.BucketType.user)
@@ -49,10 +64,10 @@ class Games(Cog):
await game.start(ctx)
@commands.hybrid_command(name="rps",
@game.command(name="rps",
help="Play Rock Paper Scissor with bot/user.",
aliases=["rockpaperscissors"],
usage="Rockpaperscissors")
usage="game rps [user]")
@blacklist_check()
@ignore_check()
@commands.cooldown(1, 3, commands.BucketType.user)
@@ -62,10 +77,10 @@ class Games(Cog):
game = btn.BetaRockPaperScissors(player)
await game.start(ctx, timeout=120)
@commands.hybrid_command(name="tic-tac-toe",
@game.command(name="tictactoe",
help="play tic-tac-toe game with a user.",
aliases=["ttt", "tictactoe"],
usage="Ticktactoe <member>")
aliases=["ttt", "tic-tac-toe"],
usage="game tictactoe <member>")
@blacklist_check()
@ignore_check()
@commands.cooldown(1, 3, commands.BucketType.user)
@@ -80,9 +95,9 @@ class Games(Cog):
game = btn.BetaTictactoe(cross=ctx.author, circle=player)
await game.start(ctx, timeout=30)
@commands.hybrid_command(name="wordle",
@game.command(name="wordle",
help="Wordle Game | Play with bot.",
usage="Wordle")
usage="game wordle")
@blacklist_check()
@ignore_check()
@commands.cooldown(1, 3, commands.BucketType.user)
@@ -92,10 +107,10 @@ class Games(Cog):
game = games.Wordle()
await game.start(ctx, timeout=120)
@commands.hybrid_command(name="2048",
@game.command(name="2048",
help="Play 2048 game with bot.",
aliases=["twenty48"],
usage="2048")
usage="game 2048")
@blacklist_check()
@ignore_check()
@commands.cooldown(1, 3, commands.BucketType.user)
@@ -105,10 +120,10 @@ class Games(Cog):
game = btn.BetaTwenty48()
await game.start(ctx, win_at=2048)
@commands.hybrid_command(name="memory-game",
@game.command(name="memory",
help="How strong is your memory?",
aliases=["memory"],
usage="memory-game")
aliases=["memory-game"],
usage="game memory")
@blacklist_check()
@ignore_check()
@commands.cooldown(1, 3, commands.BucketType.user)
@@ -118,10 +133,10 @@ class Games(Cog):
game = btn.MemoryGame()
await game.start(ctx)
@commands.hybrid_command(name="number-slider",
@game.command(name="slider",
help="slide numbers with bot",
aliases=["slider"],
usage="slider")
aliases=["number-slider"],
usage="game slider")
@blacklist_check()
@ignore_check()
@commands.cooldown(1, 3, commands.BucketType.user)
@@ -131,10 +146,10 @@ class Games(Cog):
game = btn.NumberSlider()
await game.start(ctx)
@commands.hybrid_command(name="battleship",
@game.command(name="battleship",
help="Play battleship game with your friend.",
aliases=["battle-ship"],
usage="battleship <user>")
usage="game battleship <user>")
@blacklist_check()
@ignore_check()
@commands.cooldown(1, 3, commands.BucketType.user)
@@ -164,10 +179,10 @@ class Games(Cog):
async def _end_country_guesser(self, ctx: Context):
await self.country_guesser_game.end_game_manually(ctx)"""
@commands.hybrid_command(name="connectfour",
@game.command(name="connectfour",
help="Play Connect Four game with user.",
aliases=["c4", "connect-four", "connect4"],
usage="connectfour <user>")
usage="game connectfour <user>")
@blacklist_check()
@ignore_check()
@commands.cooldown(1, 3, commands.BucketType.user)
@@ -184,10 +199,10 @@ class Games(Cog):
@commands.hybrid_command(name="lights-out",
@game.command(name="lightsout",
help="Play Lights Show game with bot.",
aliases=["lightsout"],
usage="Lights-out")
aliases=["lights-out"],
usage="game lightsout")
@blacklist_check()
@ignore_check()
@commands.cooldown(1, 3, commands.BucketType.user)