30 lines
616 B
Python
30 lines
616 B
Python
import discord
|
|
from discord.ext import commands
|
|
|
|
import config
|
|
|
|
EXTENSIONS = [
|
|
"cogs.roles",
|
|
"cogs.channels",
|
|
"cogs.countdown",
|
|
]
|
|
|
|
|
|
class Bot(commands.Bot):
|
|
def __init__(self):
|
|
super().__init__(
|
|
command_prefix=commands.when_mentioned,
|
|
intents=discord.Intents.default(),
|
|
)
|
|
|
|
async def setup_hook(self):
|
|
for ext in EXTENSIONS:
|
|
await self.load_extension(ext)
|
|
await self.tree.sync(guild=config.GUILD)
|
|
|
|
async def on_ready(self):
|
|
print(f"Logged in as {self.user} (id {self.user.id})", flush=True)
|
|
|
|
|
|
Bot().run(config.TOKEN)
|