This commit is contained in:
2025-10-28 17:34:32 +01:00
parent f79a27aaca
commit ed1ea1f7af
4 changed files with 35 additions and 31 deletions

View File

@@ -1,12 +1,23 @@
from interactions import Extension, slash_command, SlashContext
import typing
from interactions import Extension, slash_command, SlashContext, User, Client
from gwendolyn.utils import PARAMS as params
if typing.TYPE_CHECKING:
from gwendolyn_client import Gwendolyn
class GamesExtension(Extension):
"""Contains the game commands."""
def dummy(self):
# For type checking:
self.bot: "Gwendolyn"
@slash_command(**params["games"]["money"]["balance"])
async def balance(self, ctx: SlashContext):
await self.bot.money.sendBalance(ctx)
@slash_command(**params["games"]["money"]["give"])
async def give(self, ctx: SlashContext):
await self.bot.money.giveMoney(ctx)
async def give(self, ctx: SlashContext, user: User, amount: int):
await self.bot.money.giveMoney(ctx, user, amount)