Advertisement
Guest User

Untitled

a guest
Jun 24th, 2019
78
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.45 KB | None | 0 0
  1. import discord
  2. from discord.ext import commands
  3.  
  4. client = commands.Bot(command_prefix = '!')
  5.  
  6. @client.event
  7. async def on_ready():
  8. print("bot is ready")
  9.  
  10. @client.command()
  11. async def ping(ctx):
  12. await ctx.send(f'!Pong')
  13.  
  14. @client.command(aliases= ['suggest'])
  15. async def purgy(ctx):
  16. mgs = []
  17. async for x in client.logs_from(ctx.message.channel, limit = 2):
  18. mgs.append(x)
  19. await client.delete_messages(mgs)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement