I didn't know exactly what interactive mode meant, but this sample code in README at discord.py might be helpful.If the message sent is ping, this is a sample that returns pong.
import discord
class MyClient(discord.Client):
async def on_ready(self):
print('Logged on as',self.user')
async default_message(self, message):
# don't respond to our selves
if message.author==self.user:
return
if message.content=='ping':
wait message.channel.send('pong')
client=MyClient()
client.run('token')
574 Who developed the "avformat-59.dll" that comes with FFmpeg?
617 Uncaught (inpromise) Error on Electron: An object could not be cloned
578 Understanding How to Configure Google API Key
610 GDB gets version error when attempting to debug with the Presense SDK (IDE)
572 rails db:create error: Could not find mysql2-0.5.4 in any of the sources
© 2024 OneMinuteCode. All rights reserved.