Facebook
From Insensitive Leech, 5 Years ago, written in Python for S60.
Embed
Download Paste or View Raw
Hits: 200
  1. import discord
  2. import asyncio
  3. from discord.ext.commands import bot
  4. from discord.ext import commands
  5. import platform
  6. import time
  7.  
  8. bot =commands.Bot(command_prefix='.')
  9.  
  10. @bot.event
  11. async def on_ready():
  12.         print ('I am online.')
  13.         print('I am running as ' + bot.user.name+',''with the ID:' + bot.user.id+' and I am connected in '+str(len(bot.servers))+' servers.'' I am connected with '+str(len(set(bot.get_all_members())))+' members')
  14.        
  15. @bot.command()
  16. async def ping():
  17.         await bot.say('Pong!')
  18.         await bot.say('Pinged!')
  19.  
  20. @bot.command(pass_context=True)
  21. async def kick (ctx,target:discord.Member):
  22.     await bot.kick(target)
  23.  
  24.     await bot.say('Kicked someone...')
  25.  
  26. @bot.command(pass_context=True)
  27. async def warn(ctx,target:discord.Member):
  28.      await bot.send_message(target,'You got warned.. Plss stop doing what you did..')
  29.      
  30.      await bot.say('You warned someone... Feel better now..')
  31.  
  32. @bot.command(pass_context=True)
  33. async def ban(ctx,target:discord.Member):
  34.      await bot.ban(target)
  35.      
  36.      await bot.say('Succesfully banned')
  37.      
  38. bot.run('NTQ0OTUyMTAwNjMxNjA5MzQ1.D0ll9Q.7tbICYif8GU1IGbQE4NrFyTA058')