Last active
May 19, 2018 00:08
-
-
Save 4Kaylum/56ca463ff603a0bc8d3d9601e3391309 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import discord | |
| import asyncio | |
| import sys | |
| from discord.ext import commands | |
| bot = commands.Bot(command_prefix=']',self_bot=True) | |
| non_bmp_map = dict.fromkeys(range(0x10000, sys.maxunicode + 1), 0xfffd) | |
| @bot.event | |
| async def on_ready(): | |
| print("----------") | |
| print("Logged in as:") | |
| print(" "+str(bot.user.name)) | |
| print(" "+str(bot.user.id)) | |
| print("----------") | |
| @bot.event | |
| async def on_message(message): | |
| if message.author.id == bot.user.id: | |
| # print('{0.timestamp} :: {0.content}'.format(message).translate(non_bmp_map)) | |
| if message.content.replace(' ','') == '%✈📺📻': | |
| print('{0.timestamp} :: Command has been triggered'.format(message)) | |
| token = "Redacted" | |
| bot.run(token, bot=False) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment