make the bot ignore messages it sent

dev
pocketjawa 2017-03-20 18:36:36 -04:00
parent c753214317
commit 189a091d67
1 changed files with 4 additions and 0 deletions

View File

@ -46,6 +46,10 @@ def on_ready():
@asyncio.coroutine @asyncio.coroutine
def on_message(message): def on_message(message):
#Ignore messages from self
if message.author == client.user:
return
#Maki Monday praise command #Maki Monday praise command
if (message.content.lower().startswith('!maki')) or (message.content.lower().startswith('!monday')): if (message.content.lower().startswith('!maki')) or (message.content.lower().startswith('!monday')):
yield from client.send_message(message.channel, 'http://maki.pocketjawa.com/monday.png') yield from client.send_message(message.channel, 'http://maki.pocketjawa.com/monday.png')