Revolver mod by EZ HACK

Revolver mod good mod

当前为 2024-05-30 提交的版本,查看 最新版本

  1. // ==UserScript==
  2. // @name Revolver mod by EZ HACK
  3. // @namespace none
  4. // @version v2
  5. // @description Revolver mod good mod
  6. // @author EZ HACK
  7. // @license MIT
  8. // @icon https://cdn.discordapp.com/attachments/942291806740160552/1187992941306855544/Untitled_design_23.png?ex=6598e7a5&is=658672a5&hm=3b02984cc121d8feced3ba084129cbb21f3b3be25bd8d7c9964f4f176eeeecba&
  9. // @match *://moomoo.io/*
  10. // @match *://sandbox.moomoo.io/*
  11. // @match *://dev.moomoo.io/*
  12. // @require https://greasyfork.org/scripts/368273-msgpack/code/msgpack.js?version=598723
  13. // @require http://code.jquery.com/jquery-3.3.1.min.js
  14. // @require https://cdn.jsdelivr.net/npm/msgpack-lite@0.1.26/dist/msgpack.min.js
  15. // @require https://cdn.jsdelivr.net/npm/fontfaceobserver@2.1.0/fontfaceobserver.standalone.min.js
  16. // @grant none
  17. // ==/UserScript==
  18. /* KEYBINDS
  19. n - auto triple mills
  20. v - spikes
  21. f - traps
  22. h - double teleporters/turrets
  23. m - music menu
  24. space - perfect spiketick
  25. rightclick - autobreaker
  26. r - normal insta
  27. t - reverse insta
  28. , - boost tick
  29. y - 1 tick
  30. b - bulltick
  31. */
  32. document.getElementById('enterGame').innerText = "⇏ ‍ ‍ Enter_Game. ‍ ‍ ‍⇍";
  33. document.getElementById("enterGame").addEventListener("mouseenter", function() {
  34. document.getElementById('enterGame').innerText = "⇏ Enter_Game. ‍⇍";
  35. });
  36. document.getElementById("enterGame").addEventListener("mouseleave", function() {
  37. document.getElementById('enterGame').innerText = "⇏ ‍ ‍ Enter_Game. ‍ ‍ ‍⇍";
  38. });
  39. $('#itemInfoHolder').css({
  40. 'text-align': 'center',
  41. 'top': '25px',
  42. 'left': '440px',
  43. 'right': '350px',
  44. 'max-width': '350px'
  45. });
  46. document.getElementById('chatBox').innerHTML = 'Hi-____-';
  47. document.getElementById('gameName').innerHTML = '';
  48. setTimeout(() => {
  49. document.getElementById('gameName').innerHTML = 'Loading_Game';
  50. setTimeout(() => {
  51. document.getElementById('gameName').innerHTML = 'R';
  52. setTimeout(() => {
  53. document.getElementById('gameName').innerHTML = 'Re';
  54. setTimeout(() => {
  55. document.getElementById('gameName').innerHTML = 'Rev';
  56. setTimeout(() => {
  57. document.getElementById('gameName').innerHTML = 'Revo';
  58. setTimeout(() => {
  59. document.getElementById('gameName').innerHTML = 'Revol';
  60. setTimeout(() => {
  61. document.getElementById('gameName').innerHTML = 'Revolv';
  62. setTimeout(() => {
  63. document.getElementById('gameName').innerHTML = 'Revolve';
  64. setTimeout(() => {
  65. document.getElementById('gameName').innerHTML = 'Revolver';
  66. setTimeout(() => {
  67. document.getElementById('gameName').innerHTML = 'Revolver modv2';
  68. }, 120);
  69. }, 120);
  70. }, 120);
  71. }, 120);
  72. }, 120);
  73. }, 120);
  74. }, 120);
  75. }, 120);
  76. }, 120);
  77. }, 120);
  78. document.getElementById('loadingText').innerHTML = 'Loading...';
  79. setTimeout(() => {
  80. document.getElementById('loadingText').innerHTML = 'lOADING GAME';
  81. }, 710);
  82. (function () {
  83. 'use strict';
  84. });
  85. setInterval(() => window.follmoo && follmoo(), 10);
  86.  
  87. if(location.hostname == "sandbox.moomoo.io") {
  88. document.getElementById("foodDisplay").style.display = "none";
  89. document.getElementById("woodDisplay").style.display = "none";
  90. document.getElementById("stoneDisplay").style.display = "none";
  91. }
  92.  
  93. document.getElementById("enterGame").addEventListener("click", autohide);
  94. function autohide() {
  95. $("#ot-sdk-btn-floating").hide();
  96. }
  97. document.getElementById("linksContainer2").innerHTML = " ";
  98. let changes = `<div id="subConfirmationElement"><a href="https://discord.gg/BVx8EWfBny">Join Discord!</a></div>`;
  99. $('#linksContainer2').prepend(changes);
  100. $('#subConfirmationElement').click( () => {
  101. try { window.follmoo(); } catch(e){};
  102. localStorage["moofoll"] = "1"; localStorage["moofol"] = "1";
  103. });
  104. document.querySelector("#joinPartyButton").remove();
  105. document.querySelector("#pre-content-container").remove(); //ANTI AD
  106. document.getElementById("gameName").innerHTML = "Revolver mod";
  107. let changes2 = `<div id="customMenuName"><h3 style="font-size: 50px;" class = "indent">By EZ HACK</a></div>`;
  108. $('#gameName').prepend(changes2);
  109. $("#gameName").css({
  110. color: "#FFFFFF",
  111. "text-shadow": "0 1px 0 #181818, 0 2px 0 #181818, 0 3px 0 #181818, 0 4px 0 #181818, 0 5px 0 #181818, 0 6px 0 #181818, 0 7px 0 #181818, 0 8px 0 #181818, 0 9px 0 #181818, rgba(0, 0, 0, 0.4) 1px 1px 40px",
  112. "text-align": "center",
  113. "font-size": "156px",
  114. "margin-bottom": "-30px",
  115. });
  116. document.getElementById("loadingText").innerHTML = `<div id="MRLAGPRO" class="loader">`
  117. //document.getElementById("loadingText").innerHTML = "Chimken Loading";
  118. document.getElementById("diedText").innerHTML = "Revolver Died -_-";
  119. document.getElementById("diedText").style.color = "#FFFFFF";
  120. document.title = " Revolver modv1";
  121. document.getElementById("leaderboard").append("Revolver modv2");
  122. $("#mapDisplay").css("background", "url('https://wormax.org/chrome3kafa/moomooio-background.png')");
  123. document.getElementById("storeHolder").style = "height: 1150px; width: 400px;";
  124. document.getElementById('promoImgHolder').innerHTML =
  125. `
  126. <style>
  127. p { font-size: 20px;}#noticationDisplay {
  128. vertical-align: top;
  129. position: absolute;
  130. right: 85%;
  131. top: 10%;
  132. text-align: right;
  133. } .menuButton { transition: 0.5s; border-radius: 0px;
  134. } .menuButton:hover { transform: scale(1.11); box-shadow: 0 0 20px #db6c1d;
  135. } #linksContainer2 { background: #ccc; border-top: 5px solid; border-image: linear-gradient(to right,#db6c1d,##db6c1d) 1 1 0 0; height: 18px; top: 0%; color: #db6c1d; transition: 0.3s;
  136. } #linksContainer2:hover { background: #ccc; box-shadow: 0 0 20px #db6c1d;
  137. } #top-wrap-right { color: #db6c1d;
  138. } .check-box {transform: scale(1.1);
  139. } .inParty {display: none;
  140. } input[type="checkbox"] { position: relative; appearance: none; width: 33px; height: 15.5px; border-radius: 50px; box-shadow: inset 0 0 5px rgba(41, 41, 41, 0.2); cursor: pointer; top: 7.5px; transition: 0.4s;
  141. } input:checked[type="checkbox"] { background: #db6c1d;
  142. } input[type="checkbox"]::after { position: absolute; content: ""; width: 15.5px; height: 15.5px; top: 0; left: 0; background: #fff; border-radius: 50%; box-shadow: 0 0 5px rgba(0, 0, 0, 0.2); transform: scale(1.1); transition: 0.4s;
  143. } input:checked[type="checkbox"]::after { left: 50%;
  144. } .menuCard { background-color: #181818; border-top: 5px solid; border-image: linear-gradient(to right,#db6c1d,#303030) 1 0 0 0; color: #db6c1d margin-top:0px; border-radius: 0px; border-bottom: 0px solid red; transition: all 1s; transform: scale(1); box-shadow: 0px 0px #db6c1d; transform: translateX(0px);
  145. } .menuCard:hover { transform: scale(1.05); box-shadow: 0 0 20px #db6c1d;
  146. } .menuCard.active { transform: translateX(0px);
  147. } #adCard { display: none;
  148. } #promoImgHolder { overflow-y: scroll; -ms-overflow-style: none; scrollbar-width: none; height: 90px; max-height: 90px; }
  149. </style>
  150. </head>
  151. <div>
  152. <i class="fa-solid fa-rectangle-list"style="font-size: 25px";></i><p>Update V2</p> <div style="font-size: 15px">
  153. - added boost tick<br>
  154. - added normal insta<br>
  155. - added sync detect test<br>
  156. - added sync heal q hold-beta)<br>
  157. - added a lot of visuals<br>
  158. - major bug fixes<br>
  159. - optimised heal<br>
  160. - removed autobreaker secondary<br>
  161. - added biome hat<br>
  162. - fixed heal bugs <br>
  163. - made logo <br>
  164. - changed autobreaker to tankclick<br>
  165. - added menu! <br>
  166. - added stack insta<br>
  167. - added autoaim<br>
  168. - optimised heals<br>
  169. - added bullspam detect<br>
  170. - added accesories <br>
  171. <i class="fa-solid fa-rectangle-list"style="font-size: 25px";></i><p>Update V1</p> <div style="font-size: 15px">
  172. - Created Chimken mod, devlopment beings<br>
  173. - Added basic macros & auto triple mills<br>
  174. - Fixed buggy placement function<br>
  175. - Added mousebutton hats<br>
  176. - Added perfect spiketick<br>
  177. - Added bullspammer<br>
  178. - added autobreaker<br>
  179. - added heal based hitback<br>
  180. - added anti instas<br>
  181. - added reverse insta<br>
  182. - removed bullspammer<br>
  183. - added music menu<br>
  184.  
  185.  
  186. </div><div style="font-size: 15px">
  187. </div><br>
  188. `
  189. $("#itemInfoHolder").css({ top: "0px", left: "15px" });
  190. $("#youtuberOf").remove();
  191. $("#adCard").remove();
  192. $("#mobileInstructions").remove();
  193. $("#downloadButtonContainer").remove();
  194. $("#mobileDownloadButtonContainer").remove();
  195. $(".downloadBadge").remove();
  196.  
  197. const shadowStyle = "box-shadow: 0 0 10px 10px rgba(0, 0, 0, 0.4)";
  198.  
  199. const setupCardDiv = document.getElementById("setupCard");
  200. if (setupCardDiv) {
  201. setupCardDiv.style.cssText += shadowStyle;
  202. }
  203.  
  204. const serverBrowserSelect = document.getElementById("serverBrowser");
  205. if (serverBrowserSelect) {
  206. serverBrowserSelect.style.color = "#FFFFFF";
  207. serverBrowserSelect.style.backgroundColor = "#e5e3e4";
  208. }
  209.  
  210. const enterGameButton = document.getElementById("enterGame");
  211. if (enterGameButton) {
  212. enterGameButton.style.backgroundColor = "#272a2e";
  213. }
  214.  
  215. const style = document.createElement("style");
  216. style.innerHTML = `
  217. .menuLink {
  218. font-size: 20px;
  219. color: #db6c1d;
  220. }
  221. a {
  222. color: #db6c1d;
  223. text-decoration: none;
  224. }
  225. `;
  226. document.head.appendChild(style);
  227.  
  228. const nameInputElement = document.getElementById("nameInput");
  229. if (nameInputElement) {
  230. nameInputElement.style.color = "#FFFFFF";
  231. }
  232.  
  233. const guideCardDiv = document.getElementById("guideCard");
  234. if (guideCardDiv) {
  235. guideCardDiv.style.cssText += shadowStyle;
  236. setupCardDiv.style.backgroundColor = "#181818";
  237. guideCardDiv.style.backgroundColor = "#181818";
  238. }
  239.  
  240. (function () {
  241. if (document.querySelector("#customAudioPlayer")) return;
  242. var audioFiles = [
  243. {
  244. url: "https://cdn.discordapp.com/attachments/1062441866416619653/1069324203297362040/Barren_Gates_-_Obey_NCS_Release.mp3",
  245. title: "Obey NCS",
  246. },
  247. {
  248. url: "https://cdn.discordapp.com/attachments/1062441866416619653/1069323837608570941/Clarx_-_Zig_Zag_NCS_Release.mp3",
  249. title: "Zig Zag NCS",
  250. },
  251. {
  252. url: "https://cdn.discordapp.com/attachments/1062441866416619653/1069300879708135524/Anixto_-_Ride_Or_Die_NCS_Release.mp3",
  253. title: "Ride Or Die NCS",
  254. },
  255. {
  256. url: "https://cdn.discordapp.com/attachments/1062441866416619653/1069324799903531128/MP3DL.CC_Rival_-_Throne_-_ft._Neoni_NCS_Release-256k.mp3",
  257. title: "Throne NCS",
  258. },
  259. {
  260. url: "https://cdn.discordapp.com/attachments/905994516719345664/918544988965568562/Dirty_Palm_-_Ropes_feat._Chandler_Jewels_NCS10_Release.mp3",
  261. title: "Ropes NCS",
  262. },
  263. {
  264. url: "https://cdn.discordapp.com/attachments/905994516719345664/918546211584213023/Jonth_Tom_Wilson_Facading_MAGNUS_Jagsy_Vosai_RudeLies__Domastic_-_Heartless_NCS10_Release.mp3",
  265. title: "Heartless NCS",
  266. },
  267. {
  268. url: "https://cdn.discordapp.com/attachments/905873563490328626/920005714481672212/Anikdote_-_Turn_It_Up_NCS_Release.mp3",
  269. title: "Turn It Up NCS",
  270. },
  271. {
  272. url: "https://cdn.discordapp.com/attachments/905873563490328626/920006439999778856/Unknown_Brain_-_MATAFAKA_feat._Marvin_Divine_NCS_Release.mp3",
  273. title: "MATAFKA NCS",
  274. },
  275. {
  276. url: "https://cdn.discordapp.com/attachments/905994516719345664/918910823290769458/koven_never_have_i_felt_this_ncs_release_gqEQ_nIByoK-gucZcxBO.mp3",
  277. title: "Never Have I Felt This NCS",
  278. },
  279. {
  280. url: "https://cdn.discordapp.com/attachments/905994516719345664/925144953611505714/Rebel_Scum__Dani_King__Centrix_-_Calm_Before_The_Storm_NCS_Release.mp3",
  281. title: "Calm Before The Storm NCS",
  282. },
  283. ];
  284. var currentIndex = 0;
  285. var audio = new Audio(audioFiles[currentIndex].url);
  286. audio.preload = "auto";
  287. audio.volume = 0.1;
  288. var repeat = false;
  289. var shuffled = false;
  290. function playNext() {
  291. if (shuffled) {
  292. currentIndex = Math.floor(Math.random() * audioFiles.length);
  293. } else if (!repeat) {
  294. currentIndex = (currentIndex + 1) % audioFiles.length;
  295. }
  296. audio.src = audioFiles[currentIndex].url;
  297. audio.play();
  298. label.textContent = audioFiles[currentIndex].title;
  299. playButton.textContent = "Pause";
  300. playButton.style.background = "red";
  301. var trackButtons = document.querySelectorAll(".track-button");
  302. trackButtons.forEach(function (trackButton, index) {
  303. if (index === currentIndex) {
  304. trackButton.classList.add("active");
  305. } else {
  306. trackButton.classList.remove("active");
  307. }
  308. });
  309. }
  310. function formatDuration(duration) {
  311. var minutes = Math.floor(duration / 60);
  312. var seconds = Math.floor(duration % 60);
  313. return minutes + ":" + (seconds < 10 ? "0" : "") + seconds;
  314. }
  315. audio.addEventListener("ended", playNext);
  316. audio.addEventListener("timeupdate", function () {
  317. durationDisplay.textContent =
  318. formatDuration(audio.currentTime) + "/" + formatDuration(audio.duration);
  319. });
  320. var player = document.createElement("div");
  321. player.id = "customAudioPlayer";
  322. player.style =
  323. "position:fixed;top:10px;left:10px;z-index:10001;background:#282828;border:1px solid black;padding:20px;border-radius:10px;width:300px;color:#fff;box-shadow:0px 0px 20px 5px rgba(0,0,0,0.75);display:none;flex-direction:column;align-items:center;";
  324. var profilePicture = document.createElement("img");
  325. profilePicture.src =
  326. "https://yt3.ggpht.com/jI1t37BCsCD_jMVBEqQPUghbRmz3KMny540V-r5iYAHaJeGolUYdUE8o1QCok7HMxEzZHZGS9Q=s600-c-k-c0x00ffffff-no-rj-rp-mo";
  327. profilePicture.style =
  328. "width:60px;height:60px;border-radius:50%;cursor:pointer;";
  329. profilePicture.onclick = function () {
  330. window.location.href =
  331. "https://www.youtube.com/channel/UCub84Dy0SSA0NgCqeUdjpsA";
  332. };
  333. player.appendChild(profilePicture);
  334. var label = document.createElement("div");
  335. label.textContent = audioFiles[currentIndex].title;
  336. label.style = "margin-top:10px;text-align:center;";
  337. player.appendChild(label);
  338. var playButton = document.createElement("button");
  339. playButton.textContent = "Play";
  340. playButton.style =
  341. "margin-top:10px;width:100%;padding:10px;border:none;border-radius:5px;background-color:green;color:white;cursor:pointer;";
  342. playButton.onclick = function () {
  343. if (audio.paused) {
  344. audio.play();
  345. this.textContent = "Pause";
  346. this.style.background = "red";
  347. } else {
  348. audio.pause();
  349. this.textContent = "Play";
  350. this.style.background = "green";
  351. }
  352. };
  353. player.appendChild(playButton);
  354. var nextButton = document.createElement("button");
  355. nextButton.textContent = "Next";
  356. nextButton.style =
  357. "margin-top:10px;width:100%;padding:10px;border:none;border-radius:5px;background-color:white;color:black;cursor:pointer;";
  358. nextButton.onclick = playNext;
  359. player.appendChild(nextButton);
  360. var shuffleRepeatContainer = document.createElement("div");
  361. shuffleRepeatContainer.style =
  362. "display:flex;justify-content:space-between;width:100%;margin-top:10px;";
  363. player.appendChild(shuffleRepeatContainer);
  364. var shuffleButton = document.createElement("button");
  365. shuffleButton.textContent = "Shuffle: Off";
  366. shuffleButton.style =
  367. "padding:10px;border:none;border-radius:5px;background-color:black;color:white;cursor:pointer;width:48%;";
  368. shuffleButton.onclick = function () {
  369. shuffled = !shuffled;
  370. this.textContent = shuffled ? "Shuffle: On" : "Shuffle: Off";
  371. };
  372. shuffleRepeatContainer.appendChild(shuffleButton);
  373. var repeatButton = document.createElement("button");
  374. repeatButton.textContent = "Repeat: Off";
  375. repeatButton.style =
  376. "padding:10px;border:none;border-radius:5px;background-color:black;color:white;cursor:pointer;width:48%;";
  377. repeatButton.onclick = function () {
  378. repeat = !repeat;
  379. this.textContent = repeat ? "Repeat: On" : "Repeat: Off";
  380. };
  381. shuffleRepeatContainer.appendChild(repeatButton);
  382. var durationDisplay = document.createElement("div");
  383. durationDisplay.style = "margin-top:10px;text-align:center;";
  384. player.appendChild(durationDisplay);
  385. var trackList = document.createElement("div");
  386. trackList.style =
  387. "overflow:auto;max-height:150px;margin-top:20px;border:1px solid #fff;border-radius:10px;padding:5px;";
  388. audioFiles.forEach(function (track, index) {
  389. var trackButton = document.createElement("button");
  390. trackButton.textContent = track.title;
  391. trackButton.classList.add("track-button");
  392. trackButton.style =
  393. "padding:5px;border:none;border-radius:5px;background-color:black;color:white;cursor:pointer;width:100%;text-align:left;margin-top:5px;";
  394. trackButton.onclick = function () {
  395. currentIndex = index;
  396. audio.src = track.url;
  397. audio.play();
  398. label.textContent = track.title;
  399. playButton.textContent = "Pause";
  400. playButton.style.background = "red";
  401. trackButtons.forEach(function (trackButton, i) {
  402. if (i === currentIndex) {
  403. trackButton.classList.add("active");
  404. } else {
  405. trackButton.classList.remove("active");
  406. }
  407. });
  408. };
  409. trackList.appendChild(trackButton);
  410. });
  411. player.appendChild(trackList);
  412. var activeButtonStyle = document.createElement("style");
  413. activeButtonStyle.innerHTML = ".track-button.active{background-color:green;}";
  414. document.head.appendChild(activeButtonStyle);
  415. var madeByLabel = document.createElement("div");
  416. madeByLabel.textContent = "Made by Zod324myers";
  417. madeByLabel.style = "margin-top:auto;text-align:center;";
  418. player.appendChild(madeByLabel);
  419. document.body.appendChild(player);
  420. document.addEventListener("keydown", function (e) {
  421. if (e.key === "m" && document.activeElement.id.toLowerCase() !== "chatbox") {
  422. player.style.display = player.style.display === "none" ? "flex" : "none";
  423. }
  424. });
  425. })();
  426.  
  427. let lastPing = -1;
  428. let cvs = document.getElementById("gameCanvas"),
  429. ctx = cvs.getContext("2d");
  430. let Ie = document.getElementById("pingDisplay");
  431. Ie.replaceWith(document.createElement("div"));
  432. Ie.style.fontSize = "20px";
  433. Ie.style.fontFamily = "Calibri";
  434. Ie.style.display = "block";
  435. Ie.style.zIndex = "1";
  436. document.body.appendChild(Ie);
  437. setInterval(() => {
  438. Ie.style.display = "block";
  439. Ie.innerText = `${window.pingTime} ping | ${fps} fps`;
  440. }, 0);
  441. const times = [];
  442. let fps;
  443.  
  444. function refreshLoop() {
  445. window.requestAnimationFrame(() => {
  446. const now = performance.now();
  447. while (times.length > 0 && times[0] <= now - 1000) {
  448. times.shift();
  449. }
  450. times.push(now);
  451. fps = times.length;
  452. refreshLoop();
  453. });
  454. }
  455.  
  456. refreshLoop();
  457. Ie.style.fontSize = "20px";
  458. Ie.style.display = "block";
  459. Ie.style.color = "#fff";
  460. Ie.style.textShadow = "3px 3px 3px black";
  461. Ie.style.zIndex = "1";
  462. let anti = true;
  463. let hitBack = false;
  464. let stackInsta = false;
  465. let lastDamageTick = 0;
  466. let HP = 100;
  467. let gameTick = 0;
  468. var shame = 0;
  469. let shameTime,
  470. damageTimes = 0;
  471. let mouseX;
  472. let mouseY;
  473.  
  474. let width;
  475. let height;
  476. //autoaim1
  477. setInterval(() => {
  478. if (autoaim == true) {
  479. doNewSend(["D", [nearestEnemyAngle]]);
  480. }
  481. }, 10);
  482.  
  483. setInterval(() => {
  484. if (hatToggle == 1) {
  485. if (oldHat != normalHat) {
  486. hat(normalHat);
  487. console.log("Tried. - Hat")
  488. }
  489. if (oldAcc != normalAcc) {
  490. acc(normalAcc);
  491. console.log("Tried. - Acc")
  492. }
  493. oldHat = normalHat;
  494. oldAcc = normalAcc
  495. }
  496. }, 25);
  497.  
  498. setInterval(function () {
  499. if (myPlayer.hat == 45) {
  500. doNewSend(["6", ["plis no kil :c"]]);
  501. }
  502. }, 1980);// messages send ever 2000ms but this is incase of packet mashes
  503.  
  504. function normal() {
  505. hat(normalHat);
  506. acc(normalAcc);
  507. }
  508.  
  509. function aim(x, y) {
  510. var cvs = document.getElementById("gameCanvas");
  511. cvs.dispatchEvent(new MouseEvent("mousemove", {
  512. clientX: x,
  513. clientY: y
  514.  
  515. }));
  516. }
  517.  
  518. let coreURL = new URL(window.location.href);
  519. window.sessionStorage.force = coreURL.searchParams.get("fc");
  520.  
  521. var packet
  522. var nearestEnemy;
  523. var nearestEnemyAngle;
  524. var oppositeEnemyAngle;
  525. var enemyRan;
  526. let trap_a = null;
  527. let intrap = false;
  528. let trapid = null;
  529. var antitrap = false;
  530. var isEnemyNear;
  531. var primary;
  532. var secondary;
  533. var foodType;
  534. var wallType;
  535. var spikeType;
  536. var millType;
  537. var mineType;
  538. var boostType;
  539. var turretType;
  540. var spawnpadType;
  541. var autoaim = false;
  542. var autoprimary = false;
  543. var autosecondary = false;
  544. var tick = 1;
  545. var oldHat;
  546. var oldAcc;
  547. var enemiesNear;
  548. var normalHat;
  549. var normalAcc;
  550. var ws;
  551. var msgpack5 = msgpack;
  552. var boostDir;
  553. let myPlayer = {
  554. id: null,
  555. x: null,
  556. y: null,
  557. dir: null,
  558. object: null,
  559. weapon: null,
  560. clan: null,
  561. isLeader: null,
  562. hat: null,
  563. accessory: null,
  564. isSkull: null,
  565. };
  566.  
  567. let healSpeed = 100;
  568. var messageToggle = 0;
  569. var clanToggle = 0;
  570. let healToggle = 1;
  571. let hatToggle = 1;
  572. document.msgpack = msgpack;
  573.  
  574. function n() {
  575. this.buffer = new Uint8Array([0]);
  576. this.buffer.__proto__ = new Uint8Array;
  577. this.type = 0;
  578. }
  579.  
  580. WebSocket.prototype.oldSend = WebSocket.prototype.send;
  581. WebSocket.prototype.send = function(m) {
  582. if (!ws) {
  583. document.ws = this;
  584.  
  585. ws = this;
  586. socketFound(this);
  587. }
  588. this.oldSend(m);
  589. };
  590.  
  591. /*function biomeHat() {
  592. if (myPlayer.y < 2400) {
  593. hat(6);
  594. } else {
  595. if (myPlayer.y > 6850 && myPlayer.y < 7550) {
  596. hat(6);
  597. } else {
  598. hat(6);
  599. }
  600. }
  601. //acc(11);
  602. }*/
  603.  
  604. function socketFound(socket) {
  605. socket.addEventListener('message', function(message) {
  606. handleMessage(message);
  607. });
  608. }
  609.  
  610. function handleMessage(m) {
  611. let temp = msgpack5.decode(new Uint8Array(m.data));
  612. let data;
  613. if (temp.length > 1) {
  614. data = [temp[0], ...temp[1]];
  615. if (data[1] instanceof Array) {
  616. data = data;
  617. }
  618. } else {
  619. data = temp;
  620. }
  621. let item = data[0];
  622. if (!data) {
  623. return
  624. };
  625.  
  626.  
  627. if (item === "io-init") {
  628. let cvs = document.getElementById("gameCanvas");
  629. width = cvs.clientWidth;
  630. height = cvs.clientHeight;
  631. $(window).resize(function() {
  632. width = cvs.clientWidth;
  633. height = cvs.clientHeight;
  634. });
  635. cvs.addEventListener("mousemove", e => {
  636. mouseX = e.clientX;
  637. mouseY = e.clientY;
  638. });
  639. }
  640.  
  641. if (item == "C" && myPlayer.id == null) {
  642. myPlayer.id = data[1];
  643. }
  644.  
  645. if (item == "a") {
  646. enemiesNear = [];
  647. for (let i = 0; i < data[1].length / 13; i++) {
  648. let playerInfo = data[1].slice(13 * i, 13 * i + 13);
  649. if (playerInfo[0] == myPlayer.id) {
  650. myPlayer.x = playerInfo[1];
  651. myPlayer.y = playerInfo[2];
  652. myPlayer.dir = playerInfo[3];
  653. myPlayer.object = playerInfo[4];
  654. myPlayer.weapon = playerInfo[5];
  655. myPlayer.clan = playerInfo[7];
  656. myPlayer.isLeader = playerInfo[8];
  657. myPlayer.hat = playerInfo[9];
  658. myPlayer.accessory = playerInfo[10];
  659. myPlayer.isSkull = playerInfo[11];
  660. } else if (playerInfo[7] != myPlayer.clan || playerInfo[7] === null) {
  661. enemiesNear.push(playerInfo);
  662. }
  663. }
  664. }
  665. update();
  666. if (item == "H") {
  667. for(let i = 0; i < data[1].length / 8; i++) {
  668. let info = data[1].slice(8*i, 8*i+8);
  669. if(info[6] == millType && info[7] == myPlayer.id){
  670. friendlyMillLocs.push(info)
  671. }
  672.  
  673. if(info[7] == myPlayer.id){
  674. onWeapon = true;
  675. }
  676. }
  677.  
  678. }
  679. update();
  680. /*if(item == "P"){
  681. setTimeout(() => {
  682. doNewSend(["M", [{name: "vn-" + "",moofoll: 1,skin: "#cc5151"}]]);
  683. }, 200);
  684. }*/
  685.  
  686. if(item == "Q"){
  687. removeArraysWithValue(friendlyMillLocs, data[1])
  688. }
  689. update();
  690. if(item == "R"){
  691. removeArraysWithValue(friendlyMillLocs, data[1])
  692. }
  693. update();
  694. if(item == "S"){
  695. if(data[1] == 3){
  696. millCount = data[2];
  697. }
  698. }
  699. update();
  700. if(friendlyMillLocs){
  701. nearestFriendlyMill = friendlyMillLocs.sort((a,b) => dist(a, myPlayer) - dist(b, myPlayer))[0];
  702.  
  703. if(nearestFriendlyMill){
  704. nearestFriendlyMillX = nearestFriendlyMill[1]
  705. nearestFriendlyMillY = nearestFriendlyMill[2]
  706. nearestFriendlyMillScale = nearestFriendlyMill[4]
  707. }
  708. }
  709. if(Math.sqrt(Math.pow((myPlayer.y-nearestFriendlyMillY), 2) + Math.pow((myPlayer.x-nearestFriendlyMillX), 2)) < nearestFriendlyMillScale + 100) {
  710. console.log(true)
  711. isNextToFriendlyMill = true;
  712. } else {
  713. isNextToFriendlyMill = false;
  714. }
  715. WebSocket.prototype.send = function(m){
  716. let xcc = new Uint8Array(m);
  717. this.oldSend(m);
  718. let realData = {};
  719. let realInfo = msgpack5.decode(xcc);
  720. if (realInfo[1] instanceof Array){
  721. realData.data = [realInfo[0], ...realInfo[1]]
  722. }
  723. let rd0 = realData.data[0];
  724. let rd1 = realData.data[1];
  725. let rd2 = realData.data[2]
  726.  
  727. if(rd0 == 'a'){
  728. movementDirection = rd1
  729. }
  730. };
  731. isEnemyNear = false;
  732. if (enemiesNear) {
  733. nearestEnemy = enemiesNear.sort((a, b) => dist(a, myPlayer) - dist(b, myPlayer))[0];
  734. }
  735.  
  736. if (nearestEnemy) {
  737. nearestEnemyAngle = Math.atan2(nearestEnemy[2] - myPlayer.y, nearestEnemy[1] - myPlayer.x);
  738. oppositeEnemyAngle = Math.atan2(nearestEnemy[2] + myPlayer.y, nearestEnemy[1] + myPlayer.x);
  739. enemyRan = Math.sqrt(Math.pow((myPlayer.y - nearestEnemy[2]), 2) + Math.pow((myPlayer.x - nearestEnemy[1]), 2));
  740. if (Math.sqrt(Math.pow((myPlayer.y - nearestEnemy[2]), 2) + Math.pow((myPlayer.x - nearestEnemy[1]), 2)) < 285) {
  741. isEnemyNear = true;
  742. if (autoaim == false && myPlayer.hat != 7 && myPlayer.hat != 53) {
  743. normalHat = 6;
  744. if (primary != 8) {
  745. normalAcc = 21
  746. }
  747. };
  748. }
  749. }
  750. if (isEnemyNear == false && autoaim == false) {
  751. if (myPlayer.y < 2400) {
  752. normalHat = 15;
  753. } else if (myPlayer.y > 6850 && myPlayer.y < 7550) {
  754. normalHat = 31;
  755. } else {
  756. normalHat = 12;
  757.  
  758. }
  759. }
  760. if(isEnemyNear == true && nearestEnemy[5] == 4 && nearestEnemy[9] == 7 && hitBack == true && myPlayer.hat != 7 && myPlayer.hat != 53 && myPlayer.hat != 22 && myPlayer.hat != 11){
  761. doNewSend(["c", [0, 11, 0]]);
  762. setTimeout(()=>{
  763. doNewSend(["c", [0, 21, 1]]);
  764. },60);
  765. }
  766. if (!nearestEnemy) {
  767. nearestEnemyAngle = myPlayer.dir;
  768. }
  769.  
  770. if (item == "X") {
  771. //this is Sync detector(beta)
  772. if (data[5] == 3.6) {
  773. let dir_1 = (dir) => Math.atan2(Math.sin(dir), Math.cos(dir));
  774. let a1 = dir_1(
  775. (Math.atan2(data[2] - myPlayer.y, data[1] - myPlayer.x) +
  776. Math.PI +
  777. Math.PI) %
  778. (Math.PI * 2)
  779. );
  780. let a2 = dir_1((dir_1(data[3]) + Math.PI) % (Math.PI * 2));
  781. let a3 = a1 - a2;
  782. if (0.36 > a3 && -0.36 < a3) {
  783. //doNewSend(["6", ["Sync Detect Test"]]);
  784. doNewSend(["D",[Math.atan2(data[2] - myPlayer.y, data[1] - myPlayer.x)],]);
  785. if (data[2] < 80 && data[2] > 0) {
  786. doNewSend(["c", [0, 6, 0]]);
  787. place(foodType);
  788. place(foodType);
  789. }
  790. }
  791. }
  792. }
  793. if (myPlayer.hat == 45 && shame) shameTime = 30000;
  794. if (myPlayer.hat == 45 && shame) shame = 30000;
  795. if (data[0] == "a") {
  796. gameTick++;
  797. }
  798. if (item == "O" && data[1] == myPlayer.id) {
  799. gameTick = 0;
  800. lastDamageTick = 0;
  801. shame = 0;
  802. HP = 100;
  803. shameTime = 0;
  804. if (item == "O" && data[1] == myPlayer.id) {
  805. let damage = HP - data[2];
  806. HP = data[2];
  807. if (damage <= -1) {
  808. damageTimes++;
  809. if (!lastDamageTick) return;
  810. let healTime = gameTick - lastDamageTick;
  811. lastDamageTick = 0;
  812. if (healTime <= 1) {
  813. shame = shame++;
  814. } else {
  815. shame = Math.max(0, shame - 2);
  816. }
  817. } else {
  818. lastDamageTick = gameTick;
  819. }
  820. }
  821. if (data[2] < 100 && data[2] > 0 && healToggle == true) {
  822. //normal heal
  823. console.log("normal healing");
  824. setTimeout(() => {
  825. place(foodType);
  826. place(foodType);
  827. doNewSend(["c", [0, 6, 0]]);
  828. // doNewSend(["6", ["Heal"]]);
  829. }, 115);
  830. }
  831. if (data[2] < 48 && data[2] > 0 && anti == true && (nearestEnemy[5] == 5 || nearestEnemy[5] == 3)) {
  832. healToggle = false;
  833. //antiinsta no sold for pol
  834. console.log("no soldier anti - polearm");
  835. doNewSend(["c", [0, 22, 0]]);
  836. //doNewSend(["6", ["Anti"]]);
  837. place(foodType);
  838. setTimeout(() => {
  839. place(foodType);
  840. doNewSend(["c", [0, 6, 0]]);
  841. healToggle = true;
  842. }, 200);
  843. setTimeout(() => {
  844. doNewSend(["c", [0, 7, 0]]);
  845. }, 700);
  846. setTimeout(() => {
  847. doNewSend(["c", [0, 6, 0]]);
  848. }, 1900);
  849. }
  850. if (data[2] < 62 && data[2] > 41 && anti == true && (nearestEnemy[5] == 5 || nearestEnemy[5] == 3)) {
  851. healToggle = false;
  852. //antiinsta for pol
  853. console.log("anti insta - polearm");
  854. doNewSend(["c", [0, 22, 0]]);
  855. //doNewSend(["6", ["Anti"]]);
  856. place(foodType);
  857. setTimeout(() => {
  858. place(foodType);
  859. doNewSend(["c", [0, 6, 0]]);
  860. healToggle = true;
  861. }, 200);
  862. setTimeout(() => {
  863. doNewSend(["c", [0, 7, 0]]);
  864. }, 700);
  865. setTimeout(() => {
  866. doNewSend(["c", [0, 6, 0]]);
  867. }, 1900);
  868. }
  869. if (data[2] < 56 && data[2] > 50) {
  870. healToggle = false;
  871. //bullspam heal
  872. console.log("anti bullspam");
  873. setTimeout(() => {
  874. place(foodType);
  875. place(foodType);
  876. doNewSend(["c", [0, 6, 0]]);
  877. //doNewSend(["6", ["BHeal1"]]);
  878. healToggle = true;
  879. }, 140);
  880. }
  881. if (data[2] < 41 && data[2] > 0 && hitBack == true && nearestEnemy[5] == 4) {
  882. console.log("hitbacking");
  883. healToggle = false;
  884. autoaim = true;
  885. setTimeout(() => {
  886. place(foodType);
  887. place(foodType);
  888. }, 133);
  889. place(spikeType, nearestEnemyAngle);
  890. doNewSend(["d", [1]]);
  891. doNewSend(["c", [0, 7, 0]]);
  892. doNewSend(["G", [primary, true]]);
  893. setTimeout(() => {
  894. doNewSend(["c", [0, 53, 0]]);
  895. doNewSend(["d", [0]]);
  896. healToggle = true;
  897. }, 150);
  898. setTimeout(() => {
  899. doNewSend(["c", [0, 11, 0]]);
  900. autoaim = false;
  901. }, 300);
  902. }
  903. }
  904. update();
  905. }
  906.  
  907. function doNewSend(sender) {
  908. ws.send(new Uint8Array(Array.from(msgpack5.encode(sender))));
  909. }
  910.  
  911. function acc(id) {
  912. doNewSend(["c", [0, 0, 1]]);
  913. doNewSend(["c", [0, id, 1]]);
  914. }
  915.  
  916. function hat(id) {
  917. doNewSend(["c", [0, id, 0]]);
  918. }
  919.  
  920. function placeO(id, angle = Math.atan2(mouseY - height / 2, mouseX - width / 2)) {
  921. doNewSend(["G", [myPlayer.weapon, true]]);
  922. doNewSend(["G", [id, null]]);
  923. doNewSend(["d", [1, angle]]);
  924. doNewSend(["d", [0, angle]]);
  925. doNewSend(["G", [myPlayer.weapon, true]]);
  926. }
  927.  
  928. function place(id, angle = Math.atan2(mouseY - height / 2, mouseX - width / 2)) {
  929. doNewSend(["G", [id, null]]);
  930. doNewSend(["d", [1, angle]]);
  931. doNewSend(["d", [0, angle]]);
  932. doNewSend(["G", [myPlayer.weapon, true]]);
  933. }
  934.  
  935. var repeater = function(key, action, interval, bu) {
  936. let _isKeyDown = false;
  937. let _intervalId = undefined;
  938.  
  939. return {
  940. start(keycode) {
  941. if (keycode == key && document.activeElement.id.toLowerCase() !== 'chatbox') {
  942. _isKeyDown = true;
  943. if (_intervalId === undefined) {
  944. _intervalId = setInterval(() => {
  945. action();
  946. if (!_isKeyDown) {
  947. clearInterval(_intervalId);
  948. _intervalId = undefined;
  949. console.log("claered");
  950. }
  951. }, interval);
  952. }
  953. }
  954. },
  955.  
  956. stop(keycode) {
  957. if (keycode == key && document.activeElement.id.toLowerCase() !== 'chatbox') {
  958. _isKeyDown = false;
  959. }
  960. }
  961. };
  962.  
  963.  
  964. }
  965.  
  966. function removeArraysWithValue(arr, valueToRemove) {
  967. for (let i = arr.length - 1; i >= 0; i--) {
  968. const innerArray = arr[i];
  969. if (innerArray.includes(valueToRemove)) {
  970. arr.splice(i, 1);
  971. }
  972. }
  973. }
  974. let movementDirection
  975. let millCount = 0;
  976. let nearestRandomObjectX;
  977. let nearestRandomObjectY;
  978. let friendlyMillLocs = [];
  979. let nearestFriendlyMill;
  980. let nearestFriendlyMillX;
  981. let nearestFriendlyMillY;
  982. let nearestFriendlyMillScale;
  983. let isNextToFriendlyMill = false;
  984. let automilling = false
  985. let automill = false
  986. setInterval(()=>{
  987. if(automill == true && isNextToFriendlyMill == false && millCount < 298 && automilling == false){
  988. automilling = true;
  989. doNewSend(["G",[millType, null]])
  990. doNewSend(["d",[1, (movementDirection - 1.90)]])
  991. doNewSend(["d",[0, (movementDirection - 1.90)]])
  992. doNewSend(["G",[myPlayer.weapon, true]])
  993. doNewSend(["G",[millType, null]])
  994. doNewSend(["d",[1, (movementDirection - 3.14)]])
  995. doNewSend(["d",[0, (movementDirection - 3.14)]])
  996. doNewSend(["G",[myPlayer.weapon, true]])
  997. doNewSend(["G",[millType, null]])
  998. doNewSend(["d",[1, (movementDirection + 1.90)]])
  999. doNewSend(["d",[0, (movementDirection + 1.90)]])
  1000. doNewSend(["G",[myPlayer.weapon, true]])
  1001. automilling = false
  1002. }
  1003. }, 100)
  1004. const boostPlacer = repeater(70,() => {place(boostType);},50);
  1005. const spikePlacer = repeater(86,() => {place(spikeType);},50);
  1006. const placers = [boostPlacer, spikePlacer];
  1007. let prevCount = 0;
  1008. const handleMutations = (mutationsList) => {
  1009. for (const mutation of mutationsList) {
  1010. if (mutation.target.id === "killCounter") {
  1011. const count = parseInt(mutation.target.innerText, 10) || 0;
  1012. if (count > prevCount) {
  1013. doNewSend(["6", ["Revolver modv2 by EZ HACK "]]);
  1014. setTimeout(()=>{
  1015. doNewSend(["6", ["you ez kill noob+1"]]);
  1016. },650);
  1017. prevCount = count;
  1018. }
  1019. }
  1020. }
  1021. };
  1022.  
  1023.  
  1024. const observer = new MutationObserver(handleMutations);
  1025. observer.observe(document, {
  1026. subtree: true,
  1027. childList: true,
  1028. });
  1029.  
  1030. document.addEventListener('keydown', (e) => {
  1031. if (["allianceinput", "chatbox", "nameinput", "storeHolder"].includes(document.activeElement.id.toLowerCase()))
  1032. return null;
  1033. placers.forEach((t) => {
  1034. t.start(e.keyCode);
  1035. });
  1036.  
  1037. if (e.keyCode == 78 && document.activeElement.id.toLowerCase() !== "chatbox") {// N = Automill
  1038. automill = !automill;
  1039. }
  1040.  
  1041. if (e.keyCode == 72 && document.activeElement.id.toLowerCase() !== "chatbox") {// H = Turret/Teleporter
  1042. for (let i = 0; i < Math.PI * 1; i+= Math.PI / 2) {
  1043. place(turretType, myPlayer.dir + i);
  1044. place(turretType, myPlayer.dir - i);
  1045. }
  1046. }
  1047. /* if (e.keyCode == 16) {
  1048. biomeHat();
  1049. }*/
  1050. if (e.keyCode == 32 && document.activeElement.id.toLowerCase() !== "chatbox") {
  1051. // spiketick
  1052. autoaim = true;
  1053. console.log("spiektick");
  1054. place(spikeType, nearestEnemyAngle);
  1055. doNewSend(["d", [1]]);
  1056. doNewSend(["c", [0, 7, 0]]);
  1057. doNewSend(["G", [primary, true]]);
  1058. doNewSend(["d", [1]]);
  1059. setTimeout(() => {
  1060. doNewSend(["c", [0, 6, 0]]);
  1061. doNewSend(["d", [0]]);
  1062. autoaim = false;
  1063. }, 400);
  1064. }
  1065. if (e.keyCode == 89 && document.activeElement.id.toLowerCase() !== "chatbox") {//diamond pol 1 tick
  1066. autoaim = true;
  1067. doNewSend(["G", [primary, true]]);
  1068. doNewSend(["c", [0, 53, 0]]);
  1069. setTimeout(() => {
  1070. doNewSend(["c", [0, 7, 0]]);
  1071. doNewSend(["d", [1]]);
  1072. }, 100);
  1073. setTimeout(() => {
  1074. doNewSend(["G", [primary, true]]);
  1075. doNewSend(["c", [0, 6, 0]]);
  1076. doNewSend(["d", [0]]);
  1077. autoaim = false;
  1078. }, 500);
  1079. }
  1080. if (e.keyCode == 82 &&document.activeElement.id.toLowerCase() !== "chatbox") {
  1081. if (stackInsta == false) {
  1082. console.log("normal insta");
  1083. autoaim = true;
  1084. doNewSend(["c", [0, 7, 0]]);
  1085. doNewSend(["G", [primary, true]]);
  1086. doNewSend(["c", [0, 0, 1]])
  1087. doNewSend(["d", [1]]);
  1088. acc(18)
  1089. doNewSend(["c", [1]]);
  1090. setTimeout(() => {
  1091. doNewSend(["G", [secondary, true]]);
  1092. doNewSend(["c", [0, 53, 0]]);
  1093. doNewSend(["c", [0, 0, 1]]);
  1094. acc(21)
  1095. }, 105);
  1096. setTimeout(() => {
  1097. doNewSend(["G", [secondary, true]]);
  1098. }, 110);
  1099. setTimeout(() => {
  1100. doNewSend(["G", [secondary, true]]);
  1101. }, 115);
  1102. setTimeout(() => {
  1103. doNewSend(["G", [primary, true]]);
  1104. doNewSend(["d", [0, null]]);
  1105. doNewSend(["c", [0, 6, 0]]);
  1106. doNewSend(["c", [0, 0, 0]]);
  1107. doNewSend(["c", [0, 0, 1]]);
  1108. hat(6)
  1109. acc(21)
  1110. autoaim = false;
  1111. }, 215);
  1112. } else {
  1113. console.log("stack insta");
  1114. autoaim = true;
  1115. doNewSend(["c", [0, 7, 0]]);
  1116. doNewSend(["G", [primary, true]]);
  1117. doNewSend(["c", [0, 0, 1]])
  1118. doNewSend(["d", [1]]);
  1119. acc(18)
  1120. doNewSend(["c", [1]]);
  1121. setTimeout( () => {
  1122. var sck = "";
  1123. doNewSend(["G", [secondary, true]]);
  1124. doNewSend(["c", [0, 53, 0]]);
  1125. doNewSend(["c", [0, 0, 1]]);
  1126. for(let i = 0; i < 850; i++){
  1127. let caas = new Uint8Array(550);
  1128. for(let i = 0; i <caas.length;i++){
  1129. caas[i] = Math.floor(Math.random()*270);
  1130. sck += caas[i]
  1131. }
  1132. }
  1133. ws.send(caas);
  1134. }, 105);
  1135. setTimeout(() => {
  1136. doNewSend(["G", [secondary, true]]);
  1137. }, 200);
  1138. setTimeout(() => {
  1139. doNewSend(["G", [primary, true]]);
  1140. doNewSend(["d", [0, null]]);
  1141. doNewSend(["c", [0, 6, 0]]);
  1142. doNewSend(["c", [0, 0, 0]]);
  1143. doNewSend(["c", [0, 0, 1]]);
  1144. hat(6)
  1145. acc(21)
  1146. autoaim = false;
  1147. }, 215);
  1148. }
  1149. }
  1150. if (e.keyCode == 188 &&document.activeElement.id.toLowerCase() !== "chatbox") {
  1151. console.log("boost tick");
  1152. autoaim = true;
  1153. setTimeout(()=>{
  1154. doNewSend(["d", [1]]);
  1155. doNewSend(["G", [secondary, true]]);
  1156. },99);
  1157. setTimeout(()=>{
  1158. doNewSend(["c", [0, 53, 0]]);
  1159. place(boostType);
  1160. },50);
  1161. setTimeout(() => {
  1162. doNewSend(["G", [primary, true]]);
  1163. doNewSend(["c", [0, 7, 0]]);
  1164. doNewSend(["d", [1]]);
  1165. doNewSend(["d", [0]]);
  1166. }, 175);
  1167. setTimeout(() => {
  1168. doNewSend(["G", [primary, true]]);
  1169. doNewSend(["c", [0, 6, 0]]);
  1170. doNewSend(["d", [0]]);
  1171. autoaim = false;
  1172. }, 500);
  1173. }
  1174. if (e.keyCode == 84 && document.activeElement.id.toLowerCase() !== "chatbox") {
  1175. if(stackInsta == false){
  1176. // insta
  1177. autoaim = true;
  1178. console.log("reverse insta");
  1179. doNewSend(["d", [1]]);
  1180. doNewSend(["G", [secondary, true]]);
  1181. doNewSend(["c", [0, 53, 0]]);
  1182. setTimeout(() => {
  1183. doNewSend(["G", [primary, true]]);
  1184. doNewSend(["c", [0, 7, 0]]);
  1185. doNewSend(["d", [1]]);
  1186. doNewSend(["d", [0]]);
  1187. }, 80);
  1188. setTimeout(() => {
  1189. doNewSend(["G", [primary, true]]);
  1190. doNewSend(["c", [0, 6, 0]]);
  1191. doNewSend(["d", [0]]);
  1192. autoaim = false;
  1193. }, 500);
  1194. } else {
  1195. autoaim = true;
  1196. console.log("stacked reverse insta");
  1197. doNewSend(["d", [1]]);
  1198. doNewSend(["G", [secondary, true]]);
  1199. doNewSend(["c", [0, 53, 0]]);
  1200. setTimeout(() => {
  1201. var sck = "";
  1202. doNewSend(["G", [primary, true]]);
  1203. doNewSend(["c", [0, 7, 0]]);
  1204. doNewSend(["d", [1]]);
  1205. doNewSend(["d", [0]]);
  1206. for(let i = 0; i < 850; i++){
  1207. let caas = new Uint8Array(550);
  1208. for(let i = 0; i <caas.length;i++){
  1209. caas[i] = Math.floor(Math.random()*270);
  1210. sck += caas[i]
  1211. }
  1212. }
  1213. ws.send(caas);
  1214. }, 80);
  1215. setTimeout(() => {
  1216. doNewSend(["G", [primary, true]]);
  1217. doNewSend(["c", [0, 6, 0]]);
  1218. doNewSend(["d", [0]]);
  1219. autoaim = false;
  1220. }, 500);
  1221. }
  1222. }
  1223. if (e.keyCode == 66 &&document.activeElement.id.toLowerCase() !== "chatbox") {//manual bulltick
  1224. doNewSend(["c", [0, 7, 0]]);
  1225. setTimeout(()=>{
  1226. doNewSend(["c", [0, 13, 1]]);
  1227. },60);
  1228. }
  1229. })
  1230.  
  1231. document.addEventListener('keyup', (e) => {
  1232. if (["allianceinput", "chatbox", "nameinput", "storeHolder"].includes(document.activeElement.id.toLowerCase()))
  1233. return null;
  1234. placers.forEach((t) => {
  1235. t.stop(e.keyCode);
  1236. })
  1237. })
  1238.  
  1239. document.addEventListener("mousedown", (event) => {
  1240. if (event.button == 2 && secondary != 10) {
  1241. doNewSend(["d", [1]]);
  1242. doNewSend(["c", [0, 40, 0]]);
  1243. doNewSend(["G", [primary, true]]);
  1244. setTimeout(()=>{
  1245. doNewSend(["d", [0]]);
  1246. doNewSend(["c", [0, 6, 0]]);
  1247. },100);
  1248. } else if (event.button == 2) {
  1249. doNewSend(["d", [1]]);
  1250. doNewSend(["c", [0, 40, 0]]);
  1251. doNewSend(["G", [secondary, true]]);
  1252. setTimeout(()=>{
  1253. doNewSend(["d", [0]]);
  1254. doNewSend(["c", [0, 6, 0]]);
  1255. },100);
  1256. }
  1257. });
  1258.  
  1259. /*document.addEventListener("mousedown", (event) => {
  1260. if (event.button == 0) {
  1261. doNewSend(["d", [1]]);
  1262. doNewSend(["c", [0, 7, 0]]);
  1263. doNewSend(["G", [primary, true]]);
  1264. setTimeout(()=>{
  1265. doNewSend(["d", [0]]);
  1266. doNewSend(["c", [0, 6, 0]]);
  1267. },100);
  1268. }
  1269. });*/
  1270.  
  1271. function isElementVisible(e) {
  1272. return (e.offsetParent !== null);
  1273. }
  1274.  
  1275. function toRad(angle) {
  1276. return angle * 0.01745329251;
  1277. }
  1278.  
  1279. function dist(a, b) {
  1280. return Math.sqrt(Math.pow((b.y - a[2]), 2) + Math.pow((b.x - a[1]), 2));
  1281. }
  1282.  
  1283. function update() {
  1284. for (let i = 0; i < 9; i++) {
  1285. if (isElementVisible(document.getElementById("actionBarItem" + i.toString()))) {
  1286. primary = i;
  1287. }
  1288. }
  1289.  
  1290. for (let i = 9; i < 16; i++) {
  1291. if (isElementVisible(document.getElementById("actionBarItem" + i.toString()))) {
  1292. secondary = i;
  1293. }
  1294. }
  1295.  
  1296. for (let i = 16; i < 19; i++) {
  1297. if (isElementVisible(document.getElementById("actionBarItem" + i.toString()))) {
  1298. foodType = i - 16;
  1299. }
  1300. }
  1301.  
  1302. for (let i = 19; i < 22; i++) {
  1303. if (isElementVisible(document.getElementById("actionBarItem" + i.toString()))) {
  1304. wallType = i - 16;
  1305. }
  1306. }
  1307.  
  1308. for (let i = 22; i < 26; i++) {
  1309. if (isElementVisible(document.getElementById("actionBarItem" + i.toString()))) {
  1310. spikeType = i - 16;
  1311. }
  1312. }
  1313.  
  1314. for (let i = 26; i < 29; i++) {
  1315. if (isElementVisible(document.getElementById("actionBarItem" + i.toString()))) {
  1316. millType = i - 16;
  1317. }
  1318. }
  1319.  
  1320. for (let i = 29; i < 31; i++) {
  1321. if (isElementVisible(document.getElementById("actionBarItem" + i.toString()))) {
  1322. mineType = i - 16;
  1323. }
  1324. }
  1325.  
  1326. for (let i = 31; i < 33; i++) {
  1327. if (isElementVisible(document.getElementById("actionBarItem" + i.toString()))) {
  1328. boostType = i - 16;
  1329. }
  1330. }
  1331.  
  1332. for (let i = 33; i < 39; i++) {
  1333. if (isElementVisible(document.getElementById("actionBarItem" + i.toString())) && i != 36) {
  1334. turretType = i - 16;
  1335. }
  1336. }
  1337.  
  1338. spawnpadType = 36;
  1339. }
  1340.  
  1341. var styleItem = document.createElement("style");
  1342. styleItem.type = "text/css";
  1343. styleItem.appendChild(document.createTextNode(`
  1344. .loader {
  1345. position: absolute;
  1346. top:110%;
  1347. left:46%;
  1348. border: 16px solid #FFFFFF;
  1349. border-radius: 50%;
  1350. border-top: 16px solid #181818;
  1351. box-shadow: 0 0 10px 10px rgba(0, 0, 0, 0.4);
  1352. width: 60px;
  1353. height: 60px;
  1354. -webkit-animation: spin 0.5s linear infinite; /* Safari */
  1355. animation: spin 0.5s linear infinite;
  1356. }
  1357. @-webkit-keyframes spin {
  1358. 0% { -webkit-transform: rotate(0deg); }
  1359. 100% { -webkit-transform: rotate(360deg); }
  1360. }
  1361.  
  1362. @keyframes spin {
  1363. 0% { transform: rotate(0deg); }
  1364. 100% { transform: rotate(360deg); }
  1365. }
  1366. #gameUI .joinAlBtn, a {
  1367. animation: 5s infinite linear both normal rainbow;
  1368. }
  1369.  
  1370. @keyframes rainbow {
  1371. 0% { filter: hue-rotate(0deg) }
  1372. 100% { filter: hue-rotate(360deg) }
  1373. }`));
  1374. document.head.appendChild(styleItem);
  1375.  
  1376. window.addEventListener("load", () => {
  1377.  
  1378. let toggleRender = true;
  1379. let canvas = document.getElementById("gameCanvas");
  1380. let ctx = canvas.getContext("2d");
  1381. let screenWidth = 1920;
  1382. let screenHeight = 1080;
  1383. let screenW = screenWidth / 2;
  1384. let screenH = screenHeight / 2;
  1385.  
  1386. function render() {
  1387.  
  1388. if (toggleRender) {
  1389.  
  1390. ctx.beginPath();
  1391.  
  1392. let gradient = ctx.createRadialGradient(screenW, screenH, 0, screenW, screenH, screenWidth);
  1393. for (let i = 0; i <= 1; i++) {
  1394. gradient.addColorStop(i, "rgba(0, 0, 0, " + i + ")");
  1395. }
  1396.  
  1397. ctx.fillStyle = gradient;
  1398. ctx.rect(0, 0, screenWidth, screenHeight);
  1399. ctx.fill();
  1400.  
  1401. }
  1402.  
  1403. window.requestAnimFrame(render);
  1404.  
  1405. }
  1406.  
  1407. render();
  1408. });
  1409.  
  1410. document.addEventListener("keydown", function (e) {
  1411. if (e.keyCode == 27) {
  1412. $('#infomenu').toggle();
  1413. ext = !ext;
  1414. };
  1415. });
  1416.  
  1417. // Menu
  1418. $("body").after(`
  1419. <div id="infomenu">
  1420. <hr>
  1421. <div class="nameblock">Revolver modv2</div>
  1422. <hr>
  1423. <ul>
  1424. <li></label><label><div class="text">AntiInsta<input type="checkbox" id="anti" checked><span class="checkmark"></div></li>
  1425. <li></label><label><div class="text">HitBack<input type="checkbox" id="hitBack"><span class="checkmark"></div></li>
  1426. <li></label><label><div class="text">Stacked Insta<input type="checkbox" id="stackInsta"><span class="checkmark"></div></li>
  1427. </ul>
  1428. <hr>
  1429. <div class="nameblock">Revolver mov2:</div>
  1430. <hr>
  1431.  
  1432. <div class="text">
  1433. </li>
  1434. <li> N - Auto Triple Mill
  1435. </li>
  1436. <li> V - Spike
  1437. </li>
  1438. <li> F - Trap
  1439. </li>
  1440. <li> H - Double Turrets
  1441. </li>
  1442. <li> M - Music Menu
  1443. </li>
  1444. <li> Space - Perfect Stacked Spiketick
  1445. </li>
  1446. <li> RightClick - AutoBreaker
  1447. </li>
  1448. <li> R - Normal Instakill
  1449. </li>
  1450. <li> T - Reverse Instakill
  1451. </li>
  1452. <li> Y - OneTick
  1453. </li>
  1454. <li> , - Boost OneTick
  1455. </li>
  1456. <li> B - Bulltick
  1457. </li>
  1458. <li> Esc - Menu
  1459. </li>
  1460. </ul>
  1461. <hr>
  1462. </div>
  1463.  
  1464.  
  1465.  
  1466. </div>
  1467. <style>
  1468. button:active,
  1469. button:focus {
  1470. outline: none !important;
  1471. }
  1472. button::-moz-focus-inner {
  1473. border: 0 !important;
  1474. }
  1475. .nameblock {
  1476. font-size: 20px;
  1477. color: #dbdbdb;
  1478. text-align: center;
  1479. }
  1480. li {
  1481. font-size: 13px;
  1482. }
  1483. .text {
  1484. display: block;
  1485. font-size: 17px;
  1486. color: #fff;
  1487. text-align: left;
  1488. }
  1489. .menuToggle:hover{
  1490. cursor: pointer;
  1491. position: absolute;
  1492. background: linear-gradient(to right, red, orange, yellow, green, cyan, blue, violet);
  1493. background-size: 400% 400%;
  1494. -webkit-background-clip: text;
  1495. -webkit-text-fill-color: transparent;
  1496. -webkit-animation: colorR 20s ease infinite;
  1497. animation: colorR 20s ease infinite;
  1498. font-family: "Hammersmith One";
  1499. display: block !important;
  1500. top: 80px;
  1501. left: 1517px;
  1502. font-size: 17px;
  1503. }
  1504. .menuToggle{
  1505. cursor: pointer;
  1506. position: absolute;
  1507. background: linear-gradient(to right, gray, black);
  1508. background-size: 400% 400%;
  1509. -webkit-background-clip: text;
  1510. -webkit-text-fill-color: transparent;
  1511. -webkit-animation: colorR 20s ease infinite;
  1512. animation: colorR 20s ease infinite;
  1513. font-family: "Hammersmith One";
  1514. display: block !important;
  1515. top: 80px;
  1516. left: 1517px;
  1517. font-size: 17px;
  1518. }
  1519. ::-webkit-scrollbar { width: 5px; height: 3px;}
  1520. ::-webkit-scrollbar-button { background-color: ##db6c1d; }
  1521. ::-webkit-scrollbar-track { background-color: #999;}
  1522. ::-webkit-scrollbar-track-piece { background-color: rgba(0, 0, 0, 0.50);}
  1523. ::-webkit-scrollbar-thumb { height: 50px; background-color: #666; border-radius: 3px;}
  1524. ::-webkit-scrollbar-corner { background-color: #999;}}
  1525. ::-webkit-resizer { background-color: #666;}
  1526. #infomenu {
  1527. overflow-y: scroll;
  1528. overflow-x: hidden;
  1529. padding: 20px;
  1530. position: absolute;
  1531. display: none;
  1532. background: rgba(102, 102, 102, 0.25);
  1533. width: 310px;
  1534. height: 450px;
  1535. border: 2px solid black;
  1536. border-radius: 4px;
  1537. top: 80px;
  1538. left: 20px;
  1539. z-index: 1;
  1540. }
  1541. input {outline: 0 !important;}
  1542. .Input_Text_style, .Input_Buttob_style {
  1543. background: rgba(102, 102, 102);
  1544. border: 2px solid black;
  1545. border-radius: 10px;
  1546. color: #fff;
  1547. -o-transition: all 1s ease;
  1548. -ms-transition: all 1s ease;
  1549. -moz-transition: all 1s ease;
  1550. -webkit-transition: all 1s ease;
  1551. transition: all 1s ease;
  1552. }
  1553. .Input_Text_style:focus,.Input_Buttob_style:focus {
  1554. border: 2px solid #fff;
  1555. }
  1556. </style>
  1557. <script>
  1558. function InfoMenu() {
  1559. $("#infomenu").css({
  1560. "display" : "block"
  1561. });
  1562. }
  1563.  
  1564. /*(function() {
  1565. var UPDATE_DELAY = 700;
  1566. var lastUpdate = 0;
  1567. var frames = 0;
  1568. var values;
  1569. function updateCounter() {
  1570. var now = Date.now();
  1571. var elapsed = now - lastUpdate;
  1572. if (elapsed < UPDATE_DELAY) {
  1573. ++frames;
  1574. } else {
  1575. var fps = Math.round(frames / (elapsed / 1000));
  1576. document.getElementById("fps").textContent ="Fps: " + fps ;
  1577. frames = 0;
  1578. lastUpdate = now;
  1579. }
  1580. requestAnimationFrame(updateCounter);
  1581. }
  1582. lastUpdate = Date.now();
  1583. requestAnimationFrame(updateCounter);
  1584. })();
  1585. setInterval(()=>{
  1586. document.getElementById("ping").textContent = "Ping: " + window.pingTime;
  1587. },0);*/
  1588.  
  1589. </script>
  1590. `);
  1591. $("body").after(`
  1592. <div id="ShowMenu">
  1593. </span>
  1594. <div id="addtext">LeftAndRightClick: On</div>
  1595. <div id="addtext3">Balant macros: On</div>
  1596. <div id="addtext0">Soldier-Q: On</div>
  1597. <div id="addtext4">AutoSpawn: On</div>
  1598. <div id="addtext1">Left-Click</div>
  1599. <div id="addtext2">Right-Click</div>
  1600. <style>
  1601. #ShowMenu {
  1602. position:absolute !important;
  1603. display:block;
  1604. top: 5px;
  1605. left: 5px;
  1606. width: auto;
  1607. height: auto;
  1608. text-align: center;
  1609. }
  1610. #addtext,#addtext1,#addtext2,#addtext0,#addtext3,#addtext4{
  1611. display: none;
  1612. color: #fff;
  1613. background: linear-gradient(to right, red, orange, yellow, green, cyan, blue, violet);
  1614. background-size: 400% 400%;
  1615. font-size: 20px;
  1616. -webkit-background-clip: text;
  1617. -webkit-text-fill-color: transparent;
  1618. -webkit-animation: colorR 20s ease infinite;
  1619. animation: colorR 20s ease infinite;
  1620. }
  1621. @-webkit-keyframes colorR {
  1622. 0% { background-position: 0% 50% }
  1623. 50% { background-position: 100% 50% }
  1624. 100% { background-position: 0% 50% }
  1625. }
  1626. @keyframes colorR {
  1627. 0% { background-position: 0% 50% }
  1628. 50% { background-position: 100% 50% }
  1629. 100% { background-position: 0% 50% }
  1630. }
  1631. </style>
  1632. <script>
  1633. </script>
  1634. `);
  1635.  
  1636. var antii = document.querySelector("#anti")
  1637. antii.addEventListener('change', function() {
  1638. if (this.checked) {
  1639. anti = true;
  1640. } else {
  1641. anti = false;
  1642. }
  1643. });
  1644. var hitBackk = document.querySelector("#hitBack")
  1645. hitBackk.addEventListener('change', function() {
  1646. if (this.checked) {
  1647. hitBack = true;
  1648. } else {
  1649. hitBack = false;
  1650. }
  1651. });
  1652. var stackInstaa = document.querySelector("#stackInsta")
  1653. stackInstaa.addEventListener('change', function() {
  1654. if (this.checked) {
  1655. stackInsta = true;
  1656. } else {
  1657. stackInsta = false;
  1658. }
  1659. });