Advertisement
Sub-Urban

[Release] 1v1.lol Script

Nov 18th, 2020 (edited)
9,579
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. function initMod({
  2.     toggleKey: e,
  3.     godInBlink: t,
  4.     debugMode: n
  5. }) {
  6.     let o = !1,
  7.         i = {},
  8.         l = 0,
  9.         d = [],
  10.         c = WebSocket.prototype.send;
  11.     WebSocket.prototype.send = function() {
  12.         o ? (n && console.log("Holding Packet"), d.push({
  13.             this: this,
  14.             args: arguments
  15.         })) : c.apply(this, arguments)
  16.     };
  17.     let s = Object.getOwnPropertyDescriptors(WebSocket.prototype).onmessage.set;
  18.     Object.defineProperty(WebSocket.prototype, "onmessage", {
  19.             set: function() {
  20.                 let e = () => {};
  21.                 "function" == typeof arguments[0] && (e = arguments[0], arguments[0] = function() {
  22.                     (function() {
  23.                         if (arguments[0].data instanceof ArrayBuffer) {
  24.                             let e = new Uint8Array(arguments[0].data);
  25.                             return o && t && 243 == e[0] && 4 == e[1] && 200 == e[2] && 2 == e[3] && 245 == e[4] && 21 == e[5] && (48 == e.length || 25 == e.length || 49 == e.length || 50 == e.length) ? (n && console.error(`Bocked Packet ${48==e.length?"Damage?":"Shot? "+e.length}`, e), !1) : (n && console.log("Packet", e), !0)
  26.                         }
  27.                         return !0
  28.                     }).apply(this, arguments) && e.apply(this, arguments)
  29.                 }), s.apply(this, arguments)
  30.             }
  31.         }), document.addEventListener("keydown", t => {
  32.             t.code == e && (o = !o, document.getElementById("blink_at").innerText = `Hax: ${o?"Enabled":"Disabled"}`, o ? (document.getElementById("blink_ct").style.visibility = "", l = 0, i = setInterval(function() {
  33.                 l++, document.getElementById("blink_ct").innerText = `${l/10} s`
  34.             }, 100)) : (document.getElementById("blink_ct").style.visibility = "hidden", clearInterval(i), function() {
  35.                 n && console.warn("Dumping Packets...");
  36.                 for (let e in d) c.apply(d[e].this, d[e].args);
  37.                 d = []
  38.             }()))
  39.         }),
  40.         function() {
  41.             let e = document.createElement("div");
  42.             e.id = "blink", e.style.position = "absolute", e.style.zIndex = 999999, e.style.color = "blue", e.style.fontSize = "small", e.style.fontWeight = "bold";
  43.             let t = document.createElement("p"),
  44.                 n = document.createTextNode("Hax: Disabled");
  45.             t.id = "blink_at", t.style.marginTop = "10px", t.appendChild(n);
  46.             let o = document.createElement("p"),
  47.                 i = document.createTextNode("0 s");
  48.             o.id = "blink_ct", o.style.marginTop = "10px", o.style.visibility = "hidden", o.style.marginTop = "5px", o.appendChild(i), e.appendChild(t), e.appendChild(o), document.body.insertBefore(e, document.body.firstChild)
  49.         }()
  50. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement