forked from CharmingDays/kurusaki_voice
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbot.py
47 lines (19 loc) · 777 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
35
36
37
38
39
40
41
42
43
44
45
46
47
import discord,asyncio,youtube_dl
from discord.ext import commands
def get_prefix(bot, msg):
"""A callable Prefix for our bot. This could be edited to allow per server prefixes."""
prefixes = ['k.','k!','s.'] #NOTE:Heroku
return commands.when_mentioned_or(*prefixes)(bot, msg)
bot=commands.Bot(command_prefix=get_prefix,description='Multipurpose Discord Bot')
exts=['music']
@bot.event
async def on_ready():
await bot.change_presence(activity=discord.Activity(type=discord.ActivityType.listening,name='TWICE LIKEY'))
print(bot.user.name)
@commands.is_owner()
@bot.command(name='eval',hidden=True)
async def _eval(msg,*,cmd):
await msg.send(eval(cmd))
for i in exts:
bot.load_extension(i)
bot.run(os.environ['TOKEN'])