mirror of
https://gitlab.com/MisterBiggs/multi-bot-tutorial.git
synced 2025-06-16 07:06:51 +00:00
22 lines
362 B
Python
22 lines
362 B
Python
import discord
|
|
|
|
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("$hello"):
|
|
await message.channel.send("Hello!")
|
|
|
|
|
|
client.run("your token here")
|
|
|