Advertisement
Guest User

Untitled

a guest
Mar 18th, 2017
330
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.24 KB | None | 0 0
  1. import discord
  2. import asyncio
  3.  
  4. USERNAME = ''
  5. PASSWORD = ''
  6. TOKEN = ''
  7.  
  8.  
  9. class Bot(discord.Client):
  10. def __init__(self, **kwargs):
  11. super().__init__(**kwargs)
  12. self.loop.create_task(self.discrim_changer())
  13.  
  14. async def discrim_changer(self):
  15. await asyncio.sleep(10)
  16. print('Started!')
  17. while True:
  18. try:
  19. print('Attempting to change discriminator...')
  20. users = list({x.name for x in self.get_all_members() if x.discriminator == self.user.discriminator})
  21. users.remove(self.user.name)
  22. if len(users) == 0:
  23. print('Unable to find suitable discriminator.')
  24. await self.logout()
  25. return
  26. await self.edit_profile(username=users[0], password=PASSWORD)
  27. await self.edit_profile(username=USERNAME, password=PASSWORD)
  28. await asyncio.sleep(10)
  29. print('Changed to {}!'.format(self.user.discriminator))
  30. if int(self.user.discriminator) < 100:
  31. await self.logout()
  32. return
  33. except:
  34. print('Failed :(')
  35. await asyncio.sleep(3650)
  36.  
  37.  
  38. bot = Bot()
  39. bot.run(TOKEN, bot=False)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement