32 lines
842 B
Python
32 lines
842 B
Python
import discord
|
|
import os
|
|
from discord import app_commands
|
|
from discord.ext import commands
|
|
from cogs.deranged_commands import DerangedCommands
|
|
from cogs.support_helper import SupportHelper
|
|
from dotenv import load_dotenv
|
|
import selfcord
|
|
|
|
load_dotenv()
|
|
|
|
client = commands.Bot(intents=discord.Intents.all(), command_prefix=".")
|
|
user = selfcord.Client()
|
|
|
|
|
|
@client.event
|
|
async def on_message(message):
|
|
if message.author.id != 886685857560539176:
|
|
return
|
|
if message.content.startswith('.sync'):
|
|
await client.tree.sync()
|
|
await message.channel.send('Synced commands')
|
|
|
|
|
|
@client.event
|
|
async def on_ready():
|
|
await user.login(os.getenv("USER_TOKEN"))
|
|
await client.add_cog(DerangedCommands(client))
|
|
await client.add_cog(SupportHelper(client))
|
|
print("Loaded all cogs")
|
|
|
|
client.run(os.getenv("TOKEN")) |