'Why is the discord bot not talking?
The discord bot is not answering back when I said !hello. It does not respond. What is the issue?
import discord
import os
client = discord.Client()
@client.event
async def on_ready():
print('We have loggin in as {0.user}'.format(client))
@client.event
async def on_message(message):
if message.author == client.user:
return
if message.conetnt.startswith('!hello'):
await message.channel.send('Hello!')
client.run(os.getenv('TOKEN'))
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
