Greasy Fork is available in English.

Nuker (Original by DOGEWARE) - Krunker.io script / WORKING

Krunker's Mod Menu Aimbot targets nearest VISIBLE player. Adjust Smoothing for precision. Use Xray to see through walls, wireframe for players & world, and more

  1. // ==UserScript==
  2. // @name Nuker (Original by DOGEWARE) - Krunker.io script / WORKING
  3. // @namespace http://tampermonkey.net/
  4. // @version 1.3
  5. // @description Krunker's Mod Menu Aimbot targets nearest VISIBLE player. Adjust Smoothing for precision. Use Xray to see through walls, wireframe for players & world, and more
  6. // @author GreasyNigga
  7. // @match *://krunker.io/*
  8. // @match *://browserfps.com/*
  9. // @exclude *://krunker.io/social*
  10. // @exclude *://krunker.io/editor*
  11. // @icon https://cdn.pixabay.com/animation/2022/10/03/09/01/09-01-52-110_512.gif
  12. // @grant none
  13. // @require https://unpkg.com/three@0.150.0/build/three.min.js
  14. // @antifeature ads
  15. // ==/UserScript==
  16.  
  17.  
  18. let WorldScene;
  19. let intersections;
  20. let DOGEWARE = {
  21. player: {
  22. wireframe: false,
  23. opacity: 1,
  24. charmsColor: "#Ff0000"
  25. },
  26. spin: {
  27. spinbot: false,
  28. speed: 0.1,
  29. spinAngle: 0
  30. },
  31. ESP: {
  32. BoxESP: true,
  33. Charms: true,
  34. wireframe: false,
  35. layer: 2,
  36. opacity: 0.3
  37. },
  38. Cam: {
  39. x: 0,
  40. y: 0,
  41. z: 0
  42. },
  43. aimbot: {
  44. krunkAimbot: false,
  45. smoothingFactor: 0.6,
  46. AimOffset: 0,
  47. far: 1,
  48. },
  49. }
  50. let norms = {
  51. allowTarget: true,
  52. console: console.log,
  53. injectTime: 3000
  54. }
  55. const origialArrayPush = Array.prototype.push
  56. const getMainScene = function(object) {
  57. if(object && object.parent && object.parent.type === "Scene" && object.parent.name === "Main") {
  58. WorldScene = object.parent;
  59. norms.console(WorldScene)
  60. Array.prototype.push = origialArrayPush;
  61. }
  62. return origialArrayPush.apply(this, arguments);
  63. };
  64.  
  65. const ESPMatrix = new THREE.EdgesGeometry(new THREE.BoxGeometry( 5, 13, 0.02 ).translate(0,5,0));
  66.  
  67. const ESPMaterial = new THREE.RawShaderMaterial({
  68. vertexShader: `
  69. attribute vec3 position;
  70.  
  71. uniform mat4 projectionMatrix;
  72. uniform mat4 modelViewMatrix;
  73.  
  74. void main() {
  75. vec4 pos = projectionMatrix * modelViewMatrix * vec4(position, 1.0);
  76. pos.z = 0.9999;
  77. gl_Position = pos;
  78. }
  79. `,
  80. fragmentShader: `
  81. void main() {
  82. gl_FragColor = vec4(1.0, 0.0, 0.0, 1.0);
  83. }
  84. `,
  85. depthTest: false,
  86. depthWrite: false,
  87. transparent: true
  88. });
  89. function HBO() {
  90. requestAnimationFrame.call(window, HBO);
  91. if(!WorldScene) {
  92. window.setTimeout(() => {
  93. Array.prototype.push = getMainScene;
  94. }, norms.injectTime)
  95. }
  96. const entities = []
  97. let myController
  98. let PlayerTarget
  99. let RangeFactor = Infinity
  100.  
  101. WorldScene.children.forEach(child => {
  102. if(child.material)child.material.wireframe = DOGEWARE.ESP.wireframe
  103. if(child.type === 'Object3D') {
  104. try {
  105. const Camera = child.children[0]?.children[0]
  106. if(Camera && Camera.type === 'PerspectiveCamera') {
  107. myController = child
  108. } else {
  109. entities.push(child)
  110. }
  111. } catch {}
  112. }
  113. });
  114. if(!myController) {
  115. Array.prototype.push = getMainScene
  116. return
  117. }
  118. function DoSpin(){
  119. DOGEWARE.spin.spinAngle += DOGEWARE.spin.speed
  120. const targetRotationY = DOGEWARE.spin.spinAngle % (Math.PI * 2)
  121. myController.children[0].rotation.y += (targetRotationY - myController.children[0].rotation.y) * DOGEWARE.aimbot.smoothingFactor
  122. }
  123. entities.forEach(player => {
  124. try{
  125. if(player.children[0].children[4].children[0].name === "head"){
  126. const charmsColor = new THREE.Color(DOGEWARE.player.charmsColor);
  127. const material = player.children[0].children[0].material
  128. material.transparent = true
  129. material.fog = false;
  130. material.color.copy(charmsColor);
  131. material.emissive.copy(charmsColor);
  132. material.depthTest = DOGEWARE.ESP.Charms ? false : true;
  133. material.depthWrite = false
  134. material.wireframe = DOGEWARE.player.wireframe;
  135. material.opacity = DOGEWARE.player.opacity;
  136. const vertex = new THREE.LineSegments(ESPMatrix, ESPMaterial)
  137. if (!player.vertex) player.add(vertex)
  138. vertex.frustumCulled = false
  139. player.vertex = vertex;
  140. player.vertex.visible = DOGEWARE.ESP.BoxESP
  141. const { x: playerX, z: playerZ } = player.position;
  142. const { x: controllerX, z: controllerZ } = myController.position;
  143.  
  144. if (playerX !== controllerX || playerZ !== controllerZ) {
  145. const dist = player.position.distanceTo(myController.position)
  146. if(dist < RangeFactor) {
  147. PlayerTarget = player
  148. RangeFactor = dist
  149. }
  150. }
  151. }
  152. }catch(e){}
  153. });
  154. if(DOGEWARE.spin.spinbot)DoSpin()
  155. const Vector = new THREE.Vector3()
  156. const HoldObject = new THREE.Object3D()
  157. HoldObject.rotation.order = 'YXZ'
  158. HoldObject.matrix.copy(myController.matrix).invert()
  159. myController.children[0].position.set(DOGEWARE.Cam.x,DOGEWARE.Cam.y,DOGEWARE.Cam.z)
  160. if( myController !== undefined && PlayerTarget !== undefined) {
  161. if(DOGEWARE.aimbot.krunkAimbot){
  162. try{
  163. const dist = PlayerTarget.position.distanceTo(myController.position)
  164. Vector.setScalar(0)
  165. PlayerTarget.children[0].children[4].children[0].localToWorld(Vector)
  166. HoldObject.position.copy(myController.position)
  167. HoldObject.lookAt(Vector.x, Vector.y, Vector.z)
  168.  
  169. const targetRotationX = -HoldObject.rotation.x + DOGEWARE.aimbot.AimOffset / dist * 5
  170. const targetRotationY = HoldObject.rotation.y + Math.PI
  171. myController.children[0].rotation.x += (targetRotationX - myController.children[0].rotation.x) * DOGEWARE.aimbot.smoothingFactor
  172. myController.rotation.y += (targetRotationY - myController.rotation.y) * DOGEWARE.aimbot.smoothingFactor
  173.  
  174. }catch{}
  175. }
  176.  
  177. } else {}
  178. }
  179. function createMenuItem() {
  180. const styleTag = document.createElement('style')
  181. styleTag.textContent = `
  182. .menuItem1:hover img{
  183. transform: scale(1.1);
  184. }
  185. `;
  186. document.head.appendChild(styleTag)
  187. const menuItemDiv = document.createElement('div')
  188. menuItemDiv.classList.add('menuItem')
  189. menuItemDiv.classList.add('menuItem1')
  190. menuItemDiv.setAttribute('onmouseenter', 'playTick()');
  191. menuItemDiv.setAttribute('onclick', 'playSelect()');
  192. const iconSpan = document.createElement('span')
  193. iconSpan.innerHTML = `<img src="https://cdn.pixabay.com/animation/2022/10/03/09/01/09-01-52-110_512.gif" width='60' height='60'>`
  194. iconSpan.style.color = '#ff6a0b';
  195. const titleDiv = document.createElement('div')
  196. titleDiv.classList.add('menuItemTitle1')
  197. titleDiv.classList.add('menuItemTitle')
  198. titleDiv.id = 'menuBtnProfile';
  199. titleDiv.style.fontSize = '18px';
  200. titleDiv.textContent = 'Nuker';
  201. menuItemDiv.addEventListener('click', openCheats)
  202. menuItemDiv.appendChild(iconSpan);
  203. menuItemDiv.appendChild(titleDiv);
  204. const menuItemContainer = document.getElementById('menuItemContainer')
  205. if(menuItemContainer) {
  206. menuItemContainer.appendChild(menuItemDiv)
  207. } else {
  208. alert('Error: #menuItemContainer not found.')
  209. }
  210. }
  211. setTimeout(function() {
  212. createMenuItem()
  213. }, 700)
  214. let Update;
  215.  
  216. fetch('https://raw.githubusercontent.com/SigmaMaleSnow/UpdateLogKrunker/main/Update.txt')
  217. .then(response => {
  218. if (response.ok) {
  219. return response.text();
  220. } else {
  221. throw new Error('Failed to fetch data');
  222. }
  223. })
  224. .then(data => {
  225. Update = data;
  226. console.log('Fetched data:', Update);
  227. })
  228. .catch(error => {
  229. console.error('Error:', error);
  230. });
  231.  
  232. const style = document.createElement('style');
  233. style.innerHTML = `
  234. /* Dark theme styling */
  235.  
  236.  
  237. #menuContainer *{
  238. color: #ffffff !important;
  239. font-family: monospace !important;
  240. letter-spacing: -0.5px;
  241. }
  242. #menuContainer {
  243. background-color: #1a1a1a !important;
  244. font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif !important;
  245. margin: 0 !important;
  246. padding: 0 !important;
  247. position: fixed !important;
  248. top: 50% !important;
  249. left: 50% !important;
  250. transform: translate(-50%, -50%) !important;
  251. padding: 20px !important;
  252. border-radius: 10px !important;
  253. box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2) !important;
  254. z-index: 1000 !important;
  255. width: 345px;
  256. }
  257.  
  258. .menuHeaderText1 {
  259. font-size: 20px !important;
  260. text-align: center !important;
  261. width: 170px;
  262. }
  263.  
  264. .menuItemTitle1 {
  265. font-size: 18px !important;
  266. animation: rgbAnimation 0.5s infinite alternate !important;
  267. }
  268.  
  269.  
  270. @keyframes rgbAnimation {
  271. 0% { color: rgb(255, 0, 0); }
  272. 25% { color: rgb(255, 255, 0); }
  273. 50% { color: rgb(0, 255, 0); }
  274. 75% { color: rgb(0, 255, 255); }
  275. 100% { color: rgb(255, 0, 255); }
  276. }
  277.  
  278. .tab {
  279. display: flex;
  280. justify-content: space-around;
  281. gap: 8px;
  282. margin-bottom: 20px;
  283. }
  284.  
  285. .tab button {
  286. background-color: transparent;
  287. border: none;
  288. padding: 8px 12px;
  289. font-weight: 400;
  290. outline: none;
  291. color: #ffffff;
  292. cursor: pointer;
  293. transition: all 0.3s ease;
  294. }
  295.  
  296. .tab button:hover,
  297. .tab button.active {
  298. background-color: rgba(255, 255, 255, 0.2);
  299. border-radius: 5px;
  300. }
  301.  
  302. .tabcontent {
  303. display: none;
  304. margin-top: 20px;
  305. }
  306.  
  307. .tabcontent.active {
  308. display: block;
  309. }
  310.  
  311. .dropdown-toggle {
  312. appearance: none;
  313. -webkit-appearance: none;
  314. -moz-appearance: none;
  315. background-color: #1f1f1f;
  316. color: #ffffff;
  317. border: none;
  318. margin-top: 7px;
  319. padding: 13px;
  320. border-radius: 5px;
  321. cursor: pointer;
  322. float: right 1;
  323. margin-left: 139.8px !important;
  324. border: 1px solid #333333;
  325. font-weight: 400;
  326. translate: 5px;
  327. width: 90px;
  328. height: 50px;
  329. }
  330.  
  331. .dropdown-toggle:focus {
  332. outline: none;
  333. }
  334.  
  335. .dropdown-toggle option {
  336. background-color: #1f1f1f;
  337. color: #ffffff;
  338. }
  339.  
  340. .dropdown-toggle:hover,
  341. .dropdown-toggle:focus {
  342. background-color: #333333;
  343. }
  344.  
  345. input[type="text"] {
  346. width: 140px;
  347. padding: 12px;
  348. margin-bottom: 10px;
  349. border-radius: 5px;
  350. border: 1px solid #333333;
  351. background-color: #1f1f1f;
  352. color: #ffffff;
  353. float: right;
  354. margin-left: 10px;
  355. height: 20px;
  356. margin-top: 7px;
  357.  
  358. }
  359.  
  360. /* Add a class for labels to float them left and make them inline-block */
  361. .label-inline {
  362. float: left;
  363. display: inline-block;
  364. width: 100px;
  365. margin-right: 10px;
  366. margin-top: 30px;
  367. padding: 0;
  368. font-size: 18.5px;
  369. }
  370. .overlay {
  371. position: fixed !important;
  372. top: 0;
  373. left: 0;
  374. width: 100% !important;
  375. height: 100% !important;
  376. background-color: rgba(0, 0, 0, 0.5) !important;
  377. backdrop-filter: blur(5px);
  378. z-index: 999 !important;
  379. display: none;
  380. }
  381.  
  382. .overlay.show {
  383. display: block; /* Show overlay when menu is visible */
  384. }
  385. .bg1{
  386. background: linear-gradient(to right, rgb(90, 100, 200), rgb(200, 90, 100));
  387. border-radius: 3px;
  388. }
  389. .inlineNames{
  390. display: flex;
  391. justify-content: space-around;
  392. width: min-content;
  393. gap: 8px;
  394. }
  395. .inlineNames img{
  396. object-fit: cover;
  397. border-radius: 10px;
  398. }
  399. `;
  400. document.head.appendChild(style);
  401.  
  402. const overlay = document.createElement('div');
  403. overlay.classList.add('overlay');
  404. document.body.appendChild(overlay);
  405. const notification = document.createElement('div');
  406. notification.innerHTML = `
  407. <style>
  408.  
  409. #notification {
  410. position: fixed;
  411. top: -300px;
  412. left: 50%;
  413. transform: translateX(-50%);
  414. background-color: #1a1a1a;
  415. color: #fff;
  416. padding: 15px;
  417. border-radius: 5px;
  418. transition: top 0.5s ease;
  419. z-index: 999999; /* Set z-index as high as possible */
  420. font-size: 16px; /* Adjust font size */
  421. box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1); /* Add box shadow for depth */
  422. width: 300px;
  423. }
  424.  
  425. .notification-text * {
  426. font-family: monospace !important;
  427. margin-bottom: 10px;
  428. color: #fff;
  429. }
  430. @keyframes slideWidth {
  431. 0% {
  432. width: 0%;
  433. }
  434. 100% {
  435. width: 100%;
  436. }
  437. }
  438. .slider-container {
  439. margin-top: 5px;
  440. height: 4px;
  441. border-radius: 0px;
  442. animation: slideWidth 7.7s linear forwards;
  443. background-color: #ccc;
  444. position: relative;
  445. overflow: hidden;
  446. transition: width 0.3s ease;
  447. background: linear-gradient(to right, rgb(90, 100, 200), rgb(100, 150, 200));
  448.  
  449. }
  450.  
  451. </style>
  452. <div id="notification">
  453. <div class="notification-text">
  454. <h2 style="text-align: center; font-weight: 600px;">Update 0.8:</h2>
  455. <p id="dogeupdate">${Update}</p>
  456. <h3 style="text-align: center; font-weight: 600px;">[O]HIDE MENU</h3>
  457. </div>
  458. <div class="slider-container">
  459. </div>
  460. </div>
  461. `;
  462.  
  463. document.body.appendChild(notification);
  464.  
  465. setTimeout(() => {
  466. const notificationDiv = document.getElementById("notification")
  467.  
  468. notificationDiv.style.top = "20px"
  469. setTimeout(() => {
  470. notificationDiv.style.top = "-1000px"
  471. }, 8000)
  472.  
  473. }, 500)
  474. setInterval(function(){
  475. if(Update)document.getElementById('dogeupdate').innerHTML = Update
  476. })
  477.  
  478. const menuContainer = document.createElement('div');
  479. menuContainer.id = 'menuContainer';
  480. document.body.appendChild(menuContainer);
  481. const header = document.createElement('div')
  482. header.innerHTML = `
  483. <div class="header">
  484. <section class="inlineNames">
  485. <img width="60" height="60" src="https://cdn.pixabay.com/animation/2022/10/03/09/01/09-01-52-110_512.gif">
  486. <p class='menuHeaderText1'>Nuker</p>
  487. </section>
  488. <div class="bg1" style="height: 6px;"></div>
  489. </div>
  490. <div style="height: 18px;"></div>
  491. `
  492. menuContainer.appendChild(header)
  493. function createTab(tabName) {
  494. const tabButton = document.createElement('button');
  495. tabButton.textContent = tabName.charAt(0).toUpperCase() + tabName.slice(1);
  496. tabButton.addEventListener('click', () => openTab(tabName));
  497. tabLinks.appendChild(tabButton);
  498.  
  499. const tabContent = document.createElement('div');
  500. tabContent.classList.add('tabcontent');
  501. menuContainer.appendChild(tabContent);
  502. tabContents[tabName] = tabContent;
  503.  
  504. populateTab(tabName);
  505. }
  506.  
  507. function populateTab(tabName) {
  508. const tabContent = tabContents[tabName];
  509. const tabOptions = DOGEWARE[tabName];
  510. for (const option in tabOptions) {
  511. if (typeof tabOptions[option] !== 'object') {
  512. const label = document.createElement('label');
  513. label.textContent = option.charAt(0).toUpperCase() + option.slice(1);
  514. label.classList.add('label-inline');
  515. tabContent.appendChild(label);
  516.  
  517. if (typeof tabOptions[option] === 'boolean') {
  518. const dropdownContainer = document.createElement('div');
  519. dropdownContainer.classList.add('dropdown-container');
  520.  
  521. const dropdownButton = document.createElement('button');
  522. dropdownButton.classList.add('dropdown-toggle');
  523. dropdownButton.textContent = tabOptions[option] ? 'Enabled' : 'Disabled';
  524. dropdownButton.addEventListener('click', event => {
  525. tabOptions[option] = !tabOptions[option];
  526. dropdownButton.textContent = tabOptions[option] ? 'Enabled' : 'Disabled';
  527. DOGEWARE[tabName][option] = tabOptions[option];
  528. });
  529. dropdownContainer.appendChild(dropdownButton);
  530.  
  531. tabContent.appendChild(dropdownContainer);
  532. } else {
  533. const inputField = document.createElement('input');
  534. inputField.type = 'text';
  535. inputField.value = tabOptions[option];
  536. inputField.classList.add('input-field');
  537. inputField.addEventListener('input', event => {
  538. tabOptions[option] = event.target.value;
  539. DOGEWARE[tabName][option] = tabOptions[option];
  540. });
  541. tabContent.appendChild(inputField);
  542. }
  543. tabContent.appendChild(document.createElement('br'));
  544. }
  545. }
  546. }
  547.  
  548. function openTab(tabName) {
  549. const tabs = document.querySelectorAll('.tabcontent');
  550. tabs.forEach(tab => tab.classList.remove('active'));
  551. const tabButtons = document.querySelectorAll('.tab button');
  552. tabButtons.forEach(tabButton => tabButton.classList.remove('active'));
  553. const tabContent = tabContents[tabName];
  554. tabContent.classList.add('active');
  555. const tabButton = [...tabLinks.querySelectorAll('button')].find(button => button.textContent === tabName.charAt(0).toUpperCase() + tabName.slice(1));
  556. tabButton.classList.add('active');
  557. }
  558.  
  559.  
  560. const tabLinks = document.createElement('div')
  561. tabLinks.classList.add('tab')
  562. menuContainer.appendChild(tabLinks)
  563.  
  564. const tabContents = {}
  565. const tabNames = Object.keys(DOGEWARE)
  566. tabNames.forEach(tabName => {
  567. createTab(tabName)
  568. });
  569. openTab(tabNames[0]);
  570. let firstOpen = false
  571. overlay.classList.add('show')
  572.  
  573.  
  574. setInterval(function(){
  575. console.log(DOGEWARE)
  576. },2000)
  577.  
  578. function openCheats() {
  579. const displayStyle = menuContainer.style.display;
  580. menuContainer.style.transition = 'opacity 0.3s ease';
  581. menuContainer.style.opacity = '0';
  582.  
  583. if (displayStyle === 'none') {
  584. menuContainer.style.display = 'block';
  585. setTimeout(() => {
  586. menuContainer.style.opacity = '1';
  587. overlay.classList.add('show')
  588. }, 10);
  589. } else {
  590. menuContainer.style.opacity = '0';
  591. setTimeout(() => {
  592. menuContainer.style.display = 'none';
  593. overlay.classList.remove('show')
  594. }, 300);
  595. }
  596. }
  597.  
  598. document.addEventListener('keydown', function(event) {
  599. if(event.keyCode === 79) {
  600. openCheats()
  601. }
  602. });
  603.  
  604. HBO()