-
Notifications
You must be signed in to change notification settings - Fork 0
/
tagpuan.py
36 lines (28 loc) · 1.05 KB
/
tagpuan.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
from discord.ext.commands import Bot, when_mentioned_or
from discord import Intents, Activity, ActivityType, Status
from discord.ext.commands.core import command
import config
from pathlib import Path
from keep_alive import keep_alive
keep_alive()
class Tagpuan_PH_2_0(Bot):
def __init__(self):
self.owner_ids = [481374570130046976, 817701164258689054]
super().__init__(command_prefix=when_mentioned_or("/"), intents=Intents.all())
def setup(self):
cogs = [u.stem for u in Path(".").glob("./cogs/*.py")]
for cog in cogs:
self.load_extension(f'cogs.{cog}')
def run(self):
self.setup()
super().run(config.token, reconnect=True)
async def on_ready(self):
await self.change_presence(status=Status.online,
activity=Activity(type=ActivityType.watching,
name="Tagpuan PH"))
print("Bot is ready.")
def main():
bot = Tagpuan_PH_2_0()
bot.run()
if __name__ == '__main__':
main()