Shootem.io Bots

Bots for shootem.io that follow everything you do.

  1. // ==UserScript==
  2. // @name Shootem.io Bots
  3. // @namespace https://leaked.wiki/
  4. // @version 0.1
  5. // @description Bots for shootem.io that follow everything you do.
  6. // @author Sango
  7. // @match https://shootem.io/*
  8. // @grant none
  9. // ==/UserScript==
  10.  
  11. (function() {
  12. 'use strict';
  13.  
  14. const NUMBER_OF_BOTS = 19; // Number of mirrored WebSocket connections
  15.  
  16. // Find the WebSocket object
  17. let originalWebSocket = window.WebSocket;
  18. // Override WebSocket constructor
  19. window.WebSocket = function(url, protocols) {
  20. // Create a new WebSocket instance
  21. let ws = new originalWebSocket(url, protocols);
  22.  
  23. // Array to store mirrored WebSocket instances
  24. let mirrorWebSockets = [];
  25.  
  26. // Create mirrored WebSocket instances
  27. for (let i = 0; i < NUMBER_OF_BOTS; i++) {
  28. mirrorWebSockets.push(new originalWebSocket(url));
  29. }
  30.  
  31. // Function to log and mirror messages
  32. function logAndMirrorMessage(type, data) {
  33. mirrorWebSockets.forEach(mirrorWs => {
  34. mirrorWs.send(data);
  35. });
  36.  
  37. // Decode if it's binary data
  38. if (data instanceof ArrayBuffer || ArrayBuffer.isView(data)) {
  39. let decoder = new TextDecoder('utf-8');
  40. //console.log('Decoded:', decoder.decode(data));
  41. }
  42. }
  43.  
  44. // Intercept received messages
  45. ws.addEventListener('message', function(event) {
  46. logAndMirrorMessage('Received', event.data);
  47. // You can do further processing or logging here
  48. });
  49.  
  50. // Intercept sent messages
  51. let originalSend = ws.send;
  52. ws.send = function(data) {
  53. logAndMirrorMessage('Sent', data);
  54. originalSend.apply(ws, arguments);
  55. };
  56.  
  57. // Return the WebSocket instance
  58. return ws;
  59. };
  60. })();