Advertisement
Guest User

ASD

a guest
Jan 12th, 2016
68
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.21 KB | None | 0 0
  1. require_relative 'Mercury/Core'
  2.  
  3. # Make sure there is an accounts.txt & phrases.txt in the same folder as this file
  4.  
  5. # ACCOUNTS.TXT EXAMPLE: http://pastebin.com/raw/u6Zhbw16
  6. # PHRASES.TXT PHRASES: http://pastebin.com/raw/1a7VdZEZ
  7.  
  8. account_file = "#{File.dirname(__FILE__)}/accounts.txt"
  9. phrase_file = "#{File.dirname(__FILE__)}/phrases.txt"
  10.  
  11. penguins = []
  12. if(File.exists?(account_file))
  13. accounts = File.open(account_file,"r").read
  14. else
  15. puts "Please put accounts.txt in the same folder this script is in!"
  16. exit
  17. end
  18. if(File.exists?(phrase_file))
  19. phrases = File.open(phrase_file,"r").read
  20. else
  21. puts "Please put phrases.txt in the same folder this script is in!"
  22. exut
  23. end
  24.  
  25. if(accounts === "")
  26. puts "Accounts file empty, please fill accounts\nwith penguins in this format USERNAME:PASSWORD:SERVER"
  27. exit
  28. else
  29. accounts = accounts.split("\n")
  30. end
  31. phrases = phrases.split("\n")
  32. 2.times do |x|
  33. accounts.count.times do |y|
  34. if(x === 0)
  35. penguins.push(Mercury.new())
  36. else
  37. name = accounts[y].split(":")
  38. penguins[y].login(name[0],name[1],name[2])
  39. end
  40. end
  41. end
  42.  
  43.  
  44. while true
  45. phrases.count.times do |x|
  46. penguins.count.times do |y|
  47. penguins[y].chat(phrases[x])
  48. end
  49. end
  50. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement