Starting moments add-on

This commit is contained in:
Dan
2025-01-27 22:26:30 -05:00
parent ac39ff2eb1
commit 03f6337e27
2 changed files with 124 additions and 0 deletions

View File

@ -29,11 +29,15 @@ class EmeraldClient(discord.Client):
def __init__(self):
intents = discord.Intents.default()
intents.message_content = True
intents.messages = True
intents.reactions = True
super().__init__(intents=intents)
self.tree = app_commands.CommandTree(self)
async def setup_hook(self):
"""Sync commands with test guild"""
from commands.moments import setup as moments_setup
await moments_setup(self)
guild = discord.Object(id=config.DISCORD_GUILD)
self.tree.copy_global_to(guild=guild)
await self.tree.sync(guild=guild)