forked from slosher888/Mr_Grizz_Bot
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbot.py
More file actions
30 lines (20 loc) · 626 Bytes
/
bot.py
File metadata and controls
30 lines (20 loc) · 626 Bytes
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
#bot.py
import os
import discord
from dotenv import load_dotenv
load_dotenv()
TOKEN = os.getenv('DISCORD_TOKEN')
client = discord.Client()
@client.event
async def on_ready():
print('We have logged in as {0.user}'.format(client))
@client.event
async def on_message(message):
if message.author == client.user:
return
if message.content.startswith('!mr_grizz'):
if message.content[10:].upper() == 'ARE YOU HOT?' or message.content[10:].upper() == 'ARE YOU HOT':
await message.channel.send('I am decidedly not hot.')
else:
await message.channel.send('Mr_Grizz_Bot smiles and nods')
client.run(TOKEN)