1
This commit is contained in:
17
main.py
17
main.py
@@ -16,13 +16,12 @@ from discord.ext import commands
|
|||||||
# | |
|
# | |
|
||||||
# |_|
|
# |_|
|
||||||
|
|
||||||
client = discord.Client()
|
|
||||||
token = os.getenv("TOKEN")
|
token = os.getenv("TOKEN")
|
||||||
bot = commands.Bot(command_prefix=commands.when_mentioned_or("/"),
|
bot = commands.Bot(command_prefix=commands.when_mentioned_or("/"),
|
||||||
description="SnakieCat bot")
|
description="SnakieCat bot")
|
||||||
@client.event
|
@bot.event
|
||||||
async def on_ready():
|
async def on_ready():
|
||||||
print('Yeah, I am started and my name is {0.user}'.format(client))
|
print('Yeah, I am started and my name is {0.user}'.format(bot))
|
||||||
|
|
||||||
#########################################################################################################################
|
#########################################################################################################################
|
||||||
|
|
||||||
@@ -148,18 +147,15 @@ class Music(commands.Cog):
|
|||||||
# | $$$$$$/
|
# | $$$$$$/
|
||||||
# \______/
|
# \______/
|
||||||
|
|
||||||
@client.event
|
@bot.event
|
||||||
async def on_message(message):
|
async def on_message(message):
|
||||||
if message.author == client.user:
|
if message.author == bot.user:
|
||||||
return
|
return
|
||||||
|
|
||||||
if message.content.startswith('hello'):
|
if message.content.startswith('hello'):
|
||||||
await message.channel.send('Hello!')
|
await message.channel.send('Hello!')
|
||||||
|
|
||||||
if message.content.startswith('aboba'):
|
if message.content.startswith('aboba') or message.content.startswith('ABOBA'):
|
||||||
await message.channel.send(':regional_indicator_a: :regional_indicator_b: :regional_indicator_o: :regional_indicator_b: :regional_indicator_a:')
|
|
||||||
|
|
||||||
if message.content.startswith('ABOBA'):
|
|
||||||
await message.channel.send(':regional_indicator_a: :regional_indicator_b: :regional_indicator_o: :regional_indicator_b: :regional_indicator_a:')
|
await message.channel.send(':regional_indicator_a: :regional_indicator_b: :regional_indicator_o: :regional_indicator_b: :regional_indicator_a:')
|
||||||
|
|
||||||
|
|
||||||
@@ -170,4 +166,5 @@ async def on_message(message):
|
|||||||
# / _, _/ /_/ / /| /
|
# / _, _/ /_/ / /| /
|
||||||
#/_/ |_|\____/_/ |_/
|
#/_/ |_|\____/_/ |_/
|
||||||
|
|
||||||
client.run(token)
|
bot.add_cog(Music(bot))
|
||||||
|
bot.run("ODI5OTk2MzM3NjEyNzE4MTEw.YHAQUw.UoEzhz7fVG3Wqfr2IhrE14oNqEE")
|
||||||
|
|||||||
Reference in New Issue
Block a user