1v1.LOL Aimbot, ESP & Wireframe View

Let's you see players behind walls. Comes with a wireframe view mode too. Press M and N to toggle them.

目前为 2024-01-09 提交的版本。查看 最新版本

  1. // ==UserScript==
  2. // @name 1v1.LOL Aimbot, ESP & Wireframe View
  3. // @namespace http://tampermonkey.net/
  4. // @version 1.0
  5. // @description Let's you see players behind walls. Comes with a wireframe view mode too. Press M and N to toggle them.
  6. // @author Zertalious (Zert)
  7. // @match *://1v1.lol/*
  8. // @match *://1v1.school/*
  9. // @icon https://www.google.com/s2/favicons?domain=1v1.lol
  10. // @grant none
  11. // @run-at document-start
  12. // @antifeature ads
  13. // ==/UserScript==
  14.  
  15. const isSchoolLink = window.location.hostname.indexOf( '1v1.school' ) > - 1;
  16.  
  17. const searchSize = 300;
  18. const threshold = 4.5;
  19. const aimbotSpeed = 0.15;
  20.  
  21. let aimbotEnabled = false;
  22. let espEnabled = true;
  23. let wireframeEnabled = true;
  24.  
  25. const WebGL = WebGL2RenderingContext.prototype;
  26.  
  27. HTMLCanvasElement.prototype.getContext = new Proxy( HTMLCanvasElement.prototype.getContext, {
  28. apply( target, thisArgs, args ) {
  29.  
  30. if ( args[ 1 ] ) {
  31.  
  32. args[ 1 ].preserveDrawingBuffer = true;
  33.  
  34. }
  35.  
  36. return Reflect.apply( ...arguments );
  37.  
  38. }
  39. } );
  40.  
  41. WebGL.shaderSource = new Proxy( WebGL.shaderSource, {
  42. apply( target, thisArgs, args ) {
  43.  
  44. if ( args[ 1 ].indexOf( 'gl_Position' ) > - 1 ) {
  45.  
  46. if ( args[ 1 ].indexOf( 'OutlineEnabled' ) > - 1 ) {
  47.  
  48. args[ 0 ].isPlayerShader = true;
  49.  
  50. }
  51.  
  52. args[ 1 ] = args[ 1 ].replace( 'void main', `
  53.  
  54. out float vDepth;
  55. uniform bool enabled;
  56. uniform float threshold;
  57.  
  58. void main
  59.  
  60. ` ).replace( /return;/, `
  61.  
  62. vDepth = gl_Position.z;
  63.  
  64. if ( enabled && vDepth > threshold ) {
  65.  
  66. gl_Position.z = 1.0;
  67.  
  68. }
  69.  
  70. ` );
  71.  
  72. } else if ( args[ 1 ].indexOf( 'SV_Target0' ) > - 1 ) {
  73.  
  74. args[ 1 ] = args[ 1 ].replace( 'void main', `
  75.  
  76. in float vDepth;
  77. uniform bool enabled;
  78. uniform float threshold;
  79.  
  80. void main
  81.  
  82. ` ).replace( /return;/, `
  83.  
  84. if ( enabled && vDepth > threshold ) {
  85.  
  86. SV_Target0 = vec4( 1.0, 0.0, 0.0, 1.0 );
  87.  
  88. }
  89.  
  90. ` );
  91.  
  92. }
  93.  
  94. args[ 0 ].src = args[ 1 ];
  95.  
  96. return Reflect.apply( ...arguments );
  97.  
  98. }
  99. } );
  100.  
  101. WebGL.attachShader = new Proxy( WebGL.attachShader, {
  102. apply( target, thisArgs, [ program, shader ] ) {
  103.  
  104. if ( shader.isPlayerShader ) program.isPlayerProgram = true;
  105.  
  106. return Reflect.apply( ...arguments );
  107.  
  108. }
  109. } );
  110.  
  111. WebGL.getUniformLocation = new Proxy( WebGL.getUniformLocation, {
  112. apply( target, thisArgs, [ program, name ] ) {
  113.  
  114. const result = Reflect.apply( ...arguments );
  115.  
  116. if ( result ) {
  117.  
  118. result.name = name;
  119. result.program = program;
  120.  
  121. }
  122.  
  123. return result;
  124.  
  125. }
  126. } );
  127.  
  128. WebGL.uniform4fv = new Proxy( WebGL.uniform4fv, {
  129. apply( target, thisArgs, args ) {
  130.  
  131. if ( args[ 0 ].name === 'hlslcc_mtx4x4unity_ObjectToWorld' ||
  132. args[ 0 ].name === 'hlslcc_mtx4x4unity_ObjectToWorld[0]' ) {
  133.  
  134. args[ 0 ].program.isUIProgram = true;
  135.  
  136. }
  137.  
  138. return Reflect.apply( ...arguments );
  139.  
  140. }
  141. } );
  142.  
  143. let movementX = 0, movementY = 0;
  144. let count = 0;
  145.  
  146. let gl;
  147.  
  148. const handler = {
  149. apply( target, thisArgs, args ) {
  150.  
  151. const program = thisArgs.getParameter( thisArgs.CURRENT_PROGRAM );
  152.  
  153. if ( ! program.uniforms ) {
  154.  
  155. program.uniforms = {
  156. enabled: thisArgs.getUniformLocation( program, 'enabled' ),
  157. threshold: thisArgs.getUniformLocation( program, 'threshold' )
  158. };
  159.  
  160. }
  161.  
  162. const couldBePlayer = ( isSchoolLink || program.isPlayerProgram ) && args[ 1 ] > 3000;
  163.  
  164. program.uniforms.enabled && thisArgs.uniform1i( program.uniforms.enabled, ( espEnabled || aimbotEnabled ) && couldBePlayer );
  165. program.uniforms.threshold && thisArgs.uniform1f( program.uniforms.threshold, threshold );
  166.  
  167. args[ 0 ] = wireframeEnabled && ! program.isUIProgram && args[ 1 ] > 6 ? thisArgs.LINES : args[ 0 ];
  168.  
  169. if ( couldBePlayer ) {
  170.  
  171. gl = thisArgs;
  172.  
  173. }
  174.  
  175. Reflect.apply( ...arguments );
  176.  
  177. }
  178. };
  179.  
  180. WebGL.drawElements = new Proxy( WebGL.drawElements, handler );
  181. WebGL.drawElementsInstanced = new Proxy( WebGL.drawElementsInstanced, handler );
  182.  
  183. window.requestAnimationFrame = new Proxy( window.requestAnimationFrame, {
  184. apply( target, thisArgs, args ) {
  185.  
  186. args[ 0 ] = new Proxy( args[ 0 ], {
  187. apply() {
  188.  
  189. update();
  190.  
  191. return Reflect.apply( ...arguments );
  192.  
  193. }
  194. } );
  195.  
  196. return Reflect.apply( ...arguments );
  197.  
  198. }
  199. } );
  200.  
  201. function update() {
  202.  
  203. const isPlaying = document.querySelector( 'canvas' ).style.cursor === 'none';
  204. rangeEl.style.display = isPlaying && aimbotEnabled ? '' : 'none';
  205.  
  206. if ( aimbotEnabled && gl ) {
  207.  
  208. const width = Math.min( searchSize, gl.canvas.width );
  209. const height = Math.min( searchSize, gl.canvas.height );
  210.  
  211. const pixels = new Uint8Array( width * height * 4 );
  212.  
  213. const centerX = gl.canvas.width / 2;
  214. const centerY = gl.canvas.height / 2;
  215.  
  216. const x = Math.floor( centerX - width / 2 );
  217. const y = Math.floor( centerY - height / 2 );
  218.  
  219. gl.readPixels( x, y, width, height, gl.RGBA, gl.UNSIGNED_BYTE, pixels );
  220.  
  221. for ( let i = 0; i < pixels.length; i += 4 ) {
  222.  
  223. if ( pixels[ i ] === 255 && pixels[ i + 1 ] === 0 && pixels[ i + 2 ] === 0 && pixels[ i + 3 ] === 255 ) {
  224.  
  225. const idx = i / 4;
  226.  
  227. const dx = idx % width;
  228. const dy = ( idx - dx ) / width;
  229.  
  230. movementX += ( x + dx - centerX );
  231. movementY += - ( y + dy - centerY );
  232.  
  233. count ++;
  234.  
  235. }
  236.  
  237. }
  238.  
  239. }
  240.  
  241. if ( count > 0 && isPlaying ) {
  242.  
  243. const f = aimbotSpeed / count;
  244.  
  245. movementX *= f;
  246. movementY *= f;
  247.  
  248. window.dispatchEvent( new MouseEvent( 'mousemove', { movementX, movementY } ) );
  249.  
  250. rangeEl.classList.add( 'range-active' );
  251.  
  252. } else {
  253.  
  254. rangeEl.classList.remove( 'range-active' );
  255.  
  256. }
  257.  
  258. movementX = 0;
  259. movementY = 0;
  260. count = 0;
  261.  
  262. gl = null;
  263.  
  264. }
  265.  
  266. const value = parseInt( new URLSearchParams( window.location.search ).get( 'showAd' ), 16 );
  267.  
  268. const shouldShowAd = isNaN( value ) || Date.now() - value < 0 || Date.now() - value > 10 * 60 * 1000;
  269.  
  270. const el = document.createElement( 'div' );
  271.  
  272. el.innerHTML = `<style>
  273.  
  274. .dialog {
  275. position: absolute;
  276. left: 50%;
  277. top: 50%;
  278. padding: 20px;
  279. background: #1e294a;
  280. color: #fff;
  281. transform: translate(-50%, -50%);
  282. text-align: center;
  283. z-index: 999999;
  284. font-family: cursive;
  285. }
  286.  
  287. .dialog * {
  288. color: #fff;
  289. }
  290.  
  291. .close {
  292. position: absolute;
  293. right: 5px;
  294. top: 5px;
  295. width: 20px;
  296. height: 20px;
  297. opacity: 0.5;
  298. cursor: pointer;
  299. }
  300.  
  301. .close:before, .close:after {
  302. content: ' ';
  303. position: absolute;
  304. left: 50%;
  305. top: 50%;
  306. width: 100%;
  307. height: 20%;
  308. transform: translate(-50%, -50%) rotate(-45deg);
  309. background: #fff;
  310. }
  311.  
  312. .close:after {
  313. transform: translate(-50%, -50%) rotate(45deg);
  314. }
  315.  
  316. .close:hover {
  317. opacity: 1;
  318. }
  319.  
  320. .btn {
  321. cursor: pointer;
  322. padding: 0.5em;
  323. background: red;
  324. border: 3px solid rgba(0, 0, 0, 0.2);
  325. }
  326.  
  327. .btn:active {
  328. transform: scale(0.8);
  329. }
  330.  
  331. .msg {
  332. position: absolute;
  333. left: 10px;
  334. top: 10px;
  335. background: #1e294a;
  336. color: #fff;
  337. font-family: cursive;
  338. font-weight: bolder;
  339. padding: 15px;
  340. animation: msg 0.5s forwards, msg 0.5s reverse forwards 3s;
  341. z-index: 999999;
  342. pointer-events: none;
  343. }
  344.  
  345. @keyframes msg {
  346. from {
  347. transform: translate(-120%, 0);
  348. }
  349.  
  350. to {
  351. transform: none;
  352. }
  353. }
  354.  
  355. .range {
  356. position: absolute;
  357. left: 50%;
  358. top: 50%;
  359. width: ${searchSize}px;
  360. height: ${searchSize}px;
  361. max-width: 100%;
  362. max-height: 100%;
  363. border: 1px solid white;
  364. transform: translate(-50%, -50%);
  365. }
  366.  
  367. .range-active {
  368. border: 2px solid red;
  369. }
  370.  
  371. </style>
  372. <div class="dialog">${shouldShowAd ? `<big>Loading ad...</big>` : `<div class="close" onclick="this.parentNode.style.display='none';"></div>
  373. <big>ESP & Wireframe</big>
  374. <br>
  375. <br>
  376. [T] to toggle aimbot
  377. <br>
  378. [M] to toggle ESP
  379. <br>
  380. [N] to toggle wireframe
  381. <br>
  382. [H] to show/hide help
  383. <br>
  384. <br>
  385. By Zertalious
  386. <br>
  387. <br>
  388. <div style="display: grid; grid-template-columns: 1fr 1fr; grid-gap: 5px;">
  389. <div class="btn" onclick="window.open('https://discord.gg/K24Zxy88VM', '_blank')">Discord</div>
  390. <div class="btn" onclick="window.open('https://www.instagram.com/zertalious/', '_blank')">Instagram</div>
  391. <div class="btn" onclick="window.open('https://twitter.com/Zertalious', '_blank')">Twitter</div>
  392. <div class="btn" onclick="window.open('https://gf.qytechs.cn/en/users/662330-zertalious', '_blank')">More scripts</div>
  393. </div>
  394. ` }
  395. </div>
  396. <div class="msg" style="display: none;"></div>
  397. <div class="range" style="display: none;"></div>`;
  398.  
  399. const msgEl = el.querySelector( '.msg' );
  400. const dialogEl = el.querySelector( '.dialog' );
  401.  
  402. const rangeEl = el.querySelector( '.range' );
  403.  
  404. window.addEventListener( 'DOMContentLoaded', function () {
  405.  
  406. while ( el.children.length > 0 ) {
  407.  
  408. document.body.appendChild( el.children[ 0 ] );
  409.  
  410. }
  411.  
  412. if ( shouldShowAd ) {
  413.  
  414. const url = new URL( window.location.href );
  415.  
  416. url.searchParams.set( 'showAd', Date.now().toString( 16 ) );
  417. url.searchParams.set( 'scriptVersion', GM.info.script.version );
  418.  
  419. window.location.href = 'https://zertalious.xyz?ref=' + new TextEncoder().encode( url.href ).toString();
  420.  
  421. }
  422.  
  423. } );
  424.  
  425. window.addEventListener( 'keyup', function ( event ) {
  426.  
  427. switch ( String.fromCharCode( event.keyCode ) ) {
  428.  
  429. case 'M' :
  430. espEnabled = ! espEnabled;
  431. showMsg( 'ESP', espEnabled );
  432. break;
  433.  
  434. case 'N' :
  435. wireframeEnabled = ! wireframeEnabled;
  436. showMsg( 'Wireframe', wireframeEnabled );
  437. break;
  438.  
  439. case 'T' :
  440. aimbotEnabled = ! aimbotEnabled;
  441. showMsg( 'Aimbot', aimbotEnabled );
  442. break;
  443.  
  444. case 'H' :
  445. dialogEl.style.display = dialogEl.style.display === '' ? 'none' : '';
  446. break;
  447.  
  448. }
  449.  
  450. } );
  451.  
  452. function showMsg( name, bool ) {
  453.  
  454. msgEl.innerText = name + ': ' + ( bool ? 'ON' : 'OFF' );
  455.  
  456. msgEl.style.display = 'none';
  457.  
  458. void msgEl.offsetWidth;
  459.  
  460. msgEl.style.display = '';
  461.  
  462. }

QingJ © 2025

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