Advertisement
Guest User

Untitled

a guest
Sep 18th, 2018
104
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.67 KB | None | 0 0
  1. // ==UserScript==
  2. // @name SmartBots.ga
  3. // @namespace Free in Discord
  4. // @version 5.0
  5. // @description Free Bots Inviting Friend in Discord
  6. // @author Esael YT
  7. // @match http://agar.bio/*
  8. // @match http://galx.io/*
  9. // @match http://cellcraft.io/*
  10. // @match http://play.agario0.com/*
  11. // @require https://cdnjs.cloudflare.com/ajax/libs/socket.io/1.7.3/socket.io.min.js
  12. // @grant none
  13. // ==/UserScript==
  14.  
  15. (function() {
  16. 'use strict';
  17. window.trap = {
  18. x: 0,
  19. y: 0,
  20. ip: null,
  21. byteLength : 0
  22. };
  23. WebSocket.prototype.Asend = WebSocket.prototype.send;
  24. WebSocket.prototype.send = function(a) {
  25. this.Asend(a);
  26. var msg = new DataView(a);
  27. if (msg.byteLength === 21) {
  28. if (msg.getInt8(0, true) === 16) {
  29. trap.x = msg.getFloat64(1, true);
  30. trap.y = msg.getFloat64(9, true);
  31. trap.byteLength = msg.byteLength;
  32. }
  33. }
  34. if (msg.byteLength === 13) {
  35. if (msg.getUint8(0, true) === 16) {
  36. trap.x = msg.getInt32(1, true);
  37. trap.y = msg.getInt32(5, true);
  38. trap.byteLength = msg.byteLength;
  39. }
  40. }
  41. if (msg.byteLength === 5 || msg.byteLength < 4) {
  42. if (msg.getUint8(0, true) === 16) {
  43. trap.x = msg.getInt16(1, true);
  44. trap.y = msg.getInt16(3, true);
  45. trap.byteLength = msg.byteLength;
  46. }
  47. }
  48. if(this.url !== null) {
  49. trap.ip = this.url;
  50. console.log(trap.ip);
  51. }
  52. };
  53. var socket = io.connect('ws://SmartBots-esaelbots305116.codeanyapp.com:8081');
  54.  
  55. document.addEventListener('keydown', function(e) {
  56. var key = e.keyCode || e.which;
  57. switch (key) {
  58. case 69:
  59. socket.emit('split');
  60. break;
  61. case 82:
  62. socket.emit('eject');
  63. break;
  64. case 67:
  65. socket.emit('spam');
  66. break;
  67. }
  68. });
  69. setInterval(function() {
  70. socket.emit('movement', {
  71. x: trap.x,
  72. y: trap.y,
  73. byteLength: trap.byteLength
  74. });
  75. },100);
  76. window.start = function() {
  77. socket.emit('start', {
  78. ip : trap.ip !== null ? trap.ip : 0,
  79. origin : location.origin
  80. });
  81. };
  82. setTimeout(function() {
  83. $("#canvas").after("<div style='box-shadow: 0px 0px 20px black;z-index:9999999; background-color: #0036FF; -moz-opacity: 0.4; -khtml-opacity: 0.4; opacity: 0.7; zoom: 1; width: 350px; top: 10px; left: 10px; display: block; position: absolute; text-align: center; font-size: 15px; color: #ffffff; font-family: castellar;border: 2px solid #0c31d4;'> <div style='color:#ffffff; display: inline; -moz-opacity:1; -khtml-opacity: 1; opacity:1;font-size: 22px; filter:alpha(opacity=100); padding: 10px;'><a>SmartBots.ga</a></div> <div style=' color:#ffffff; display: inline; -moz-opacity:1; -khtml-opacity: 1; opacity:1; filter:alpha(opacity=100); padding: 10px;'><br>Bots Online: <a id='minionCount'>None</a> </div><button id='start-bots' style='display: block;border-radius: 5px;border: 2px solid #6495ED;background-color: #FF3600;height: 50px;width: 120px;margin: auto;text-align: center;'>Start Now!</button><marquee>Get in: SmartBots.ga</marquee> </div>");
  84. document.getElementById('start-bots').onclick = function() {
  85. start();
  86. };
  87. },2000);
  88. socket.on('botCount', function(count) {
  89. $('#minionCount').html(count);
  90. });
  91. })();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement