-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathmain.py
57 lines (26 loc) · 1.07 KB
/
main.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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
import nextcord
import json
import os
from cogs.verification import VerifyButton
from nextcord.ext import commands , tasks
import requests
os.chdir("./")
class Bot(commands.Bot):
def __init__(self, *args, **kwargs):
super().__init__(*args, **kwargs)
self.persistent_views_added = False
self = self
async def on_ready(self):
if not self.persistent_views_added:
self.add_view(VerifyButton(client))
self.persistent_views_added = True
print(f"Logged in as {client.user}!")
await client.change_presence(status = nextcord.Status.online, activity=nextcord.Activity(type=nextcord.ActivityType.watching, name="People Verify"))
intents = nextcord.Intents.default()
intents.members = True
client = Bot(command_prefix = "nom!", intents = intents)
for filename in os.listdir('./cogs'):
if filename.endswith('.py'):
client.load_extension(f'cogs.{filename[:-3]}')
print(f"Loaded {filename} cog")
client.run("ODcxMzgwNzI0NzYxMTI0OTE0.GrrFch.XwoIEbolc2cqJh4IfqER4xlDOGoExX2wFIZANY")