Advertisement
Guest User

Untitled

a guest
Oct 19th, 2019
155
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.99 KB | None | 0 0
  1. // ==UserScript==
  2. // @name Starve - kmccord1 + Chromium Script
  3. // @namespace http://tampermonkey.net/
  4. // @version WhoKnows
  5. // @description starve dieing from the inside :o
  6. // @author kmccord1 + Chromium
  7. // @match https://starve.io/
  8. // @grant none
  9. // ==/UserScript==
  10.  
  11. (function() {
  12. // VARS
  13. var bootloop = setInterval(runbots,17);
  14. var bots = new Array();
  15. var botsconnecting = 0;
  16. // KEYS
  17.  
  18. // FUNCTIONS
  19. function getCookie(name) {
  20. var v = document.cookie.match('(^|;) ?' + name + '=([^;]*)(;|$)');
  21. return v ? v[2] : null;
  22. }
  23. function setCookie(name, value, days) {
  24. var d = new Date;
  25. d.setTime(d.getTime() + 24*60*60*1000*days);
  26. document.cookie = name + "=" + value + ";path=/;expires=" + d.toGMTString();
  27. }
  28. function deleteCookie(name) { setCookie(name, '', -1); }
  29. function botconnect()
  30. {
  31. botsconnecting = 0;
  32. for (var i = 0; i < bots.length; i++)
  33. {
  34. if (bots[i].connected == 0)
  35. {
  36. botsconnecting++;
  37. }
  38. }
  39. if (botsconnecting == 0)
  40. {
  41. bots.push( new WebSocket("wss://" + Xm.ML[11].i + ":" + Xm.ML[11].p) );
  42. bots[bots.length - 1].connected = 0;
  43. bots[bots.length - 1].onopen = function()
  44. {
  45. bots[bots.length - 1].send(JSON.stringify(["Chromium-" + Math.round(Math.random()*1000),2120,1280,46,Math.round(Math.random()*50000000000000000000),getCookie("starve_token_id"),0,0,0,0,0,1,0,0,0,null]))
  46. bots[bots.length - 1].connected = 1;
  47. }
  48. }
  49. }
  50. function filterbots()
  51. {
  52. for (var i = 0; i < bots.length; i++)
  53. {
  54. if (bots[i].connected == 1 && bots[i].readyState != 1)
  55. {
  56. bots.splice(i,1);
  57. }
  58. }
  59. }
  60. function runbots()
  61. {
  62. filterbots();
  63. botconnect();
  64. }
  65. })();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement