-
Notifications
You must be signed in to change notification settings - Fork 0
/
bot.py
34 lines (27 loc) · 949 Bytes
/
bot.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
import discord
from discord.ext import commands
import asyncio
import config
# Description and Intents
description = 'Circus Casino misc. utility bot'
intents = discord.Intents.default()
intents.members = True # Necessary for member-related information
intents.message_content = True # Necessary for reading message content
bot = commands.Bot(command_prefix=config.COMMAND_PREFIX, description=description, intents=intents)
@bot.event
async def on_ready():
print(f'Logged in as {bot.user} (ID: {bot.user.id})')
print('------')
# Load Cogs/Extensions
async def load_extensions():
cogs = ['commands.leaderboard', 'commands.ledger', 'commands.player']
for cog in cogs:
await bot.load_extension(cog)
# Main Function
async def main():
# Load Cogs
await load_extensions()
# Start the Bot
await bot.start(config.BOT_TOKEN)
if __name__ == "__main__":
asyncio.run(main())