Vortex Forge Deadshot.io

Vortex Forge Web Client with Scope Autoshoot,Sniper Mode,Player Rank Search & FPS Booster

  1. // ==UserScript==
  2. // @name Vortex Forge Deadshot.io
  3. // @namespace http://tampermonkey.net/
  4. // @version 2.5
  5. // @description Vortex Forge Web Client with Scope Autoshoot,Sniper Mode,Player Rank Search & FPS Booster
  6. // @author NOOB
  7. // @match https://deadshot.io/*
  8. // @grant none
  9. // ==/UserScript==
  10.  
  11. (function () {
  12. 'use strict';
  13.  
  14. let featuresEnabled = true;
  15. let sniperModeEnabled = false;
  16. let fireworkInterval = null;
  17. let kKeyInterval = null;
  18. let isRightMousePressed = false;
  19. let spacebarLockEnabled = false;
  20. let fpsDisplay = null;
  21. let lastFrameTime = performance.now();
  22. let frameCount = 0;
  23. let fps = 0;
  24. const fpsThreshold = 30;
  25.  
  26. const newSettingsContent = `
  27. <div class="setting toggle" style="margin-top: 30px; padding: 9px 30px; background-color: rgba(255, 255, 255, 0.03);">
  28. <p style="font-size: 21px;">Search My Rank</p>
  29. <button id="searchRankButton" style="padding: 5px 10px; font-size: 16px; cursor: pointer;">Search</button>
  30. </div>
  31. <div class="setting toggle" style="padding: 9px 30px;">
  32. <p style="font-size: 21px;">Sniper Mode</p>
  33. <label>
  34. <input id="vfSniperMode" class="checkbox" type="checkbox">
  35. <span></span>
  36. </label>
  37. </div>
  38. <div class="setting toggle" style="padding: 9px 30px; background-color: rgba(255, 255, 255, 0.03);">
  39. <p style="font-size: 21px;">Vortex Forge Mode</p>
  40. <label>
  41. <input id="vfsettings" class="checkbox" type="checkbox" checked="">
  42. <span></span>
  43. </label>
  44. </div>
  45. `;
  46.  
  47. function createSearchPopup() {
  48. const popup = document.createElement('div');
  49. popup.style.position = 'fixed';
  50. popup.style.top = '50%';
  51. popup.style.left = '50%';
  52. popup.style.transform = 'translate(-50%, -50%)';
  53. popup.style.backgroundColor = 'rgba(0, 0, 0, 0.9)';
  54. popup.style.padding = '20px';
  55. popup.style.borderRadius = '10px';
  56. popup.style.color = 'white';
  57. popup.style.zIndex = '10000';
  58.  
  59. const input = document.createElement('input');
  60. input.type = 'text';
  61. input.placeholder = 'Enter username';
  62. input.style.padding = '10px';
  63. input.style.fontSize = '16px';
  64. input.style.marginRight = '10px';
  65.  
  66. const searchButton = document.createElement('button');
  67. searchButton.innerText = 'Search';
  68. searchButton.style.padding = '10px';
  69. searchButton.style.fontSize = '16px';
  70. searchButton.style.cursor = 'pointer';
  71.  
  72. const closeButton = document.createElement('button');
  73. closeButton.innerText = 'Close';
  74. closeButton.style.marginLeft = '10px';
  75. closeButton.style.padding = '10px';
  76. closeButton.style.fontSize = '16px';
  77. closeButton.style.cursor = 'pointer';
  78.  
  79. closeButton.onclick = () => popup.remove();
  80. searchButton.onclick = async () => {
  81. const username = input.value.trim();
  82. if (username) {
  83. const rank = await fetchLeaderboardRank(username);
  84. showRankPopup(username, rank);
  85. }
  86. };
  87.  
  88. popup.appendChild(input);
  89. popup.appendChild(searchButton);
  90. popup.appendChild(closeButton);
  91. document.body.appendChild(popup);
  92. }
  93.  
  94. async function fetchLeaderboardRank(username) {
  95. try {
  96. const response = await fetch('https://login.deadshot.io/leaderboards');
  97. const data = await response.json();
  98.  
  99. const categories = ["daily", "weekly", "alltime"];
  100.  
  101. for (const category of categories) {
  102. if (data[category] && data[category].kills) {
  103. const leaderboard = data[category].kills;
  104.  
  105. leaderboard.sort((a, b) => b.kills - a.kills);
  106.  
  107. const player = leaderboard.find(player => player.name === username);
  108.  
  109. if (player) {
  110. const rank = leaderboard.indexOf(player);
  111. return `Rank: ${rank + 1} in ${category} leaderboard`;
  112. }
  113. }
  114. }
  115.  
  116. return 'Not found in any leaderboard';
  117. } catch (error) {
  118. console.error('Error fetching leaderboard:', error);
  119. return 'Error';
  120. }
  121. }
  122.  
  123.  
  124. function showRankPopup(username, rank) {
  125. const popup = document.createElement('div');
  126. popup.style.position = 'fixed';
  127. popup.style.top = '50%';
  128. popup.style.left = '50%';
  129. popup.style.transform = 'translate(-50%, -50%)';
  130. popup.style.backgroundColor = 'rgba(0, 0, 0, 0.9)';
  131. popup.style.padding = '20px';
  132. popup.style.borderRadius = '10px';
  133. popup.style.color = 'white';
  134. popup.style.zIndex = '10000';
  135. popup.innerText = rank === 'Not found' ? `User ${username} not found in the leaderboard.` : `User ${username} is ranked #${rank}`;
  136.  
  137. const closeButton = document.createElement('button');
  138. closeButton.innerText = 'Close';
  139. closeButton.style.marginTop = '10px';
  140. closeButton.style.padding = '10px';
  141. closeButton.style.fontSize = '16px';
  142. closeButton.style.cursor = 'pointer';
  143. closeButton.onclick = () => popup.remove();
  144.  
  145. popup.appendChild(closeButton);
  146. document.body.appendChild(popup);
  147. }
  148.  
  149. document.addEventListener('DOMContentLoaded', () => {
  150. const searchButton = document.getElementById('searchRankButton');
  151. if (searchButton) {
  152. searchButton.addEventListener('click', createSearchPopup);
  153. }
  154. });
  155.  
  156. //Make space by removing left handed mode(rubbish)
  157. function removeLeftHandedSetting() {
  158. const leftHandedDiv = document.querySelector('.setting.toggle input#lefthand')?.closest('.setting.toggle');
  159. if (leftHandedDiv) {
  160. leftHandedDiv.remove();
  161. console.log("Left-Handed setting removed.");
  162. }
  163. }
  164. function removeADSToggle() {
  165. const leftHandedDiv = document.querySelector('.setting.toggle input#toggleads')?.closest('.setting.toggle');
  166. if (leftHandedDiv) {
  167. leftHandedDiv.remove();
  168. console.log("Toggle ADS removed.");
  169. }
  170. }
  171.  
  172. function addCustomSettingsToTop() {
  173. const settingsDiv = document.getElementById('settingsDiv');
  174. if (settingsDiv && !document.getElementById('vfSniperMode')) {
  175. const customDiv = document.createElement('div');
  176. customDiv.innerHTML = newSettingsContent;
  177. settingsDiv.insertBefore(customDiv, settingsDiv.firstChild);
  178.  
  179. const searchButton = document.getElementById('searchRankButton');
  180. if (searchButton) {
  181. searchButton.addEventListener('click', createSearchPopup);
  182. }
  183. }
  184. }
  185.  
  186.  
  187. function waitForSettingsDiv() {
  188. const retryInterval = setInterval(() => {
  189. const settingsDiv = document.getElementById('settingsDiv');
  190. if (settingsDiv) {
  191. removeLeftHandedSetting();
  192. removeADSToggle();
  193. addCustomSettingsToTop();
  194. setupSniperModeToggle();
  195. setupVortexForgeModeToggle();
  196. clearInterval(retryInterval);
  197. }
  198. }, 500);
  199. }
  200.  
  201. function setupSniperModeToggle() {
  202. const sniperModeCheckbox = document.getElementById('vfSniperMode');
  203. if (sniperModeCheckbox) {
  204. sniperModeCheckbox.addEventListener('change', (event) => {
  205. sniperModeEnabled = event.target.checked;
  206. });
  207. }
  208. }
  209.  
  210. function setupVortexForgeModeToggle() {
  211. const vfCheckbox = document.getElementById('vfsettings');
  212. if (vfCheckbox) {
  213. vfCheckbox.addEventListener('change', (event) => {
  214. featuresEnabled = event.target.checked;
  215. toggleFeatures(featuresEnabled);
  216. });
  217. }
  218. }
  219.  
  220. function toggleFeatures(enabled) {
  221. if (!enabled) {
  222. stopKKeyPress();
  223. isRightMousePressed = false;
  224. }
  225. }
  226.  
  227. function startKKeyPress() {
  228. if (!kKeyInterval) {
  229. kKeyInterval = setInterval(() => {
  230. const kKeyEvent = new KeyboardEvent('keydown', {
  231. key: 'K',
  232. code: 'KeyK',
  233. keyCode: 75,
  234. which: 75,
  235. bubbles: true,
  236. cancelable: true,
  237. });
  238. document.dispatchEvent(kKeyEvent);
  239. }, 100);
  240. }
  241. }
  242.  
  243. function stopKKeyPress() {
  244. if (kKeyInterval) {
  245. clearInterval(kKeyInterval);
  246. kKeyInterval = null;
  247.  
  248. const kKeyUpEvent = new KeyboardEvent('keyup', {
  249. key: 'K',
  250. code: 'KeyK',
  251. keyCode: 75,
  252. which: 75,
  253. bubbles: true,
  254. cancelable: true,
  255. });
  256. document.dispatchEvent(kKeyUpEvent);
  257. }
  258. }
  259.  
  260. function startShooting() {
  261. const shootKeyEvent = new KeyboardEvent('keydown', {
  262. key: 'K',
  263. code: 'KeyK',
  264. keyCode: 75,
  265. which: 75,
  266. bubbles: true,
  267. cancelable: true,
  268. });
  269. document.dispatchEvent(shootKeyEvent);
  270.  
  271. const shootKeyUpEvent = new KeyboardEvent('keyup', {
  272. key: 'K',
  273. code: 'KeyK',
  274. keyCode: 75,
  275. which: 75,
  276. bubbles: true,
  277. cancelable: true,
  278. });
  279. document.dispatchEvent(shootKeyUpEvent);
  280. }
  281.  
  282. document.addEventListener('mousedown', (e) => {
  283. if (!featuresEnabled) return;
  284.  
  285. if (e.button === 2) {
  286. if (!isRightMousePressed) {
  287. isRightMousePressed = true;
  288.  
  289. if (!sniperModeEnabled) {
  290. startKKeyPress();
  291. }
  292. }
  293. }
  294. });
  295.  
  296. document.addEventListener('mouseup', (e) => {
  297. if (e.button === 2) {
  298. if (sniperModeEnabled) {
  299. startShooting();
  300. }else{
  301. stopKKeyPress();
  302. }
  303.  
  304. isRightMousePressed = false;
  305. }
  306. });
  307.  
  308. //Fps settings
  309. function createFPSDisplay() {
  310. fpsDisplay = document.createElement('div');
  311. fpsDisplay.style.position = 'fixed';
  312. fpsDisplay.style.bottom = '10px';
  313. fpsDisplay.style.right = '10px';
  314. fpsDisplay.style.backgroundColor = 'rgba(0, 0, 0, 0.7)';
  315. fpsDisplay.style.padding = '10px';
  316. fpsDisplay.style.borderRadius = '5px';
  317. fpsDisplay.style.color = 'white';
  318. fpsDisplay.style.fontSize = '14px';
  319. fpsDisplay.style.zIndex = '10000';
  320. document.body.appendChild(fpsDisplay);
  321. }
  322.  
  323. function updateFPS() {
  324. const now = performance.now();
  325. frameCount++;
  326.  
  327. if (now - lastFrameTime >= 1000) {
  328. fps = frameCount;
  329. frameCount = 0;
  330. lastFrameTime = now;
  331. fpsDisplay.innerText = `FPS: ${fps}`;
  332. if (fps < fpsThreshold) {
  333. boostFPS();
  334. }
  335. }
  336. requestAnimationFrame(updateFPS);
  337. }
  338.  
  339. function boostFPS() {
  340. document.querySelectorAll('canvas').forEach(canvas => {
  341. canvas.style.imageRendering = 'pixelated';
  342. });
  343. reduceGraphicsQuality();
  344. }
  345.  
  346. function reduceGraphicsQuality() {
  347. const elementsToModify = [
  348. ...document.querySelectorAll('img, video, canvas')
  349. ];
  350. elementsToModify.forEach(el => {
  351. el.style.filter = 'brightness(0.9) contrast(0.9)';
  352. });
  353. }
  354.  
  355. window.addEventListener('load', () => {
  356. waitForSettingsDiv();
  357. createFPSDisplay();
  358. updateFPS();
  359. });
  360. })();

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址