Agar.io Neon Fake Ban GUI

Neon-themed fake ban GUI with tech UI for Agar.io

  1. // ==UserScript==
  2. // @name Agar.io Neon Fake Ban GUI
  3. // @namespace http://tampermonkey.net/
  4. // @version 0.3
  5. // @description Neon-themed fake ban GUI with tech UI for Agar.io
  6. // @author You
  7. // @match *://agar.io/*
  8. // @grant none
  9. // @run-at document-end
  10. // ==/UserScript==
  11.  
  12. (function() {
  13. 'use strict';
  14.  
  15. // Create the GUI elements
  16. const createBanGUI = () => {
  17. const container = document.createElement('div');
  18. container.style.position = 'fixed';
  19. container.style.top = '10px';
  20. container.style.right = '10px';
  21. container.style.backgroundColor = '#222';
  22. container.style.color = '#00ff00';
  23. container.style.padding = '20px';
  24. container.style.borderRadius = '12px';
  25. container.style.zIndex = '1000';
  26. container.style.cursor = 'move';
  27. container.style.boxShadow = '0 0 15px rgba(0, 255, 0, 0.5)';
  28. container.style.transition = 'all 0.3s ease';
  29.  
  30. const title = document.createElement('h3');
  31. title.textContent = 'Fake Ban GUI';
  32. title.style.textShadow = '0 0 10px rgba(0, 255, 0, 0.7)';
  33. container.appendChild(title);
  34.  
  35. const input = document.createElement('input');
  36. input.type = 'text';
  37. input.placeholder = 'Enter ban time (mm:ss)';
  38. input.style.marginRight = '10px';
  39. input.style.padding = '10px';
  40. input.style.border = '2px solid #00ff00';
  41. input.style.backgroundColor = '#111';
  42. input.style.color = '#00ff00';
  43. input.style.borderRadius = '8px';
  44. input.style.transition = 'all 0.3s ease';
  45. input.onfocus = () => input.style.borderColor = '#00ff77';
  46. input.onblur = () => input.style.borderColor = '#00ff00';
  47. container.appendChild(input);
  48.  
  49. const button = document.createElement('button');
  50. button.textContent = 'Ban';
  51. button.style.padding = '10px 20px';
  52. button.style.border = 'none';
  53. button.style.backgroundColor = '#00ff00';
  54. button.style.color = '#111';
  55. button.style.fontSize = '16px';
  56. button.style.borderRadius = '8px';
  57. button.style.cursor = 'pointer';
  58. button.style.boxShadow = '0 0 10px rgba(0, 255, 0, 0.5)';
  59. button.style.transition = 'all 0.3s ease';
  60. button.onmouseover = () => button.style.backgroundColor = '#00ff77';
  61. button.onmouseout = () => button.style.backgroundColor = '#00ff00';
  62. button.onclick = () => {
  63. const [minutes, seconds] = input.value.split(':').map(num => parseInt(num, 10));
  64. if (isNaN(minutes) || isNaN(seconds)) {
  65. alert('Invalid time format. Use mm:ss.');
  66. return;
  67. }
  68. const banTime = (minutes * 60 + seconds) * 1000; // Convert to milliseconds
  69.  
  70. // Store the ban end time in localStorage
  71. localStorage.setItem('banEndTime', Date.now() + banTime);
  72. localStorage.setItem('isBanned', 'true');
  73.  
  74. showBanPopup(banTime);
  75. };
  76. container.appendChild(button);
  77.  
  78. document.body.appendChild(container);
  79.  
  80. // Make the GUI draggable
  81. let isDragging = false;
  82. let offsetX, offsetY;
  83.  
  84. container.onmousedown = (e) => {
  85. isDragging = true;
  86. offsetX = e.clientX - container.getBoundingClientRect().left;
  87. offsetY = e.clientY - container.getBoundingClientRect().top;
  88. };
  89.  
  90. document.onmousemove = (e) => {
  91. if (isDragging) {
  92. container.style.left = (e.clientX - offsetX) + 'px';
  93. container.style.top = (e.clientY - offsetY) + 'px';
  94. }
  95. };
  96.  
  97. document.onmouseup = () => {
  98. isDragging = false;
  99. };
  100. };
  101.  
  102. const showBanPopup = (banTime) => {
  103. const popup = document.createElement('div');
  104. popup.style.position = 'fixed';
  105. popup.style.top = '50%';
  106. popup.style.left = '50%';
  107. popup.style.transform = 'translate(-50%, -50%)';
  108. popup.style.backgroundColor = '#222';
  109. popup.style.color = '#00ff00';
  110. popup.style.padding = '30px';
  111. popup.style.borderRadius = '12px';
  112. popup.style.zIndex = '1000';
  113. popup.style.textAlign = 'center';
  114. popup.style.fontSize = '20px';
  115. popup.style.fontWeight = 'bold';
  116. popup.style.boxShadow = '0 0 25px rgba(0, 255, 0, 0.7)';
  117. popup.style.transition = 'opacity 0.5s ease';
  118. popup.style.opacity = '0';
  119. popup.style.animation = 'popup-fade 0.5s forwards';
  120.  
  121. const message = document.createElement('div');
  122. message.textContent = `You are banned for ${Math.floor(banTime / 60000)} minutes and ${Math.floor((banTime % 60000) / 1000)} seconds.`;
  123. popup.appendChild(message);
  124.  
  125. document.body.appendChild(popup);
  126.  
  127. // Disable game interaction
  128. document.body.style.pointerEvents = 'none';
  129. };
  130.  
  131. const checkBanStatus = () => {
  132. const isBanned = localStorage.getItem('isBanned') === 'true';
  133. const banEndTime = parseInt(localStorage.getItem('banEndTime'), 10);
  134.  
  135. if (isBanned && Date.now() < banEndTime) {
  136. showBanPopup(banEndTime - Date.now());
  137. } else if (isBanned && Date.now() >= banEndTime) {
  138. localStorage.removeItem('isBanned');
  139. localStorage.removeItem('banEndTime');
  140. document.body.style.pointerEvents = 'auto'; // Re-enable interaction
  141. }
  142. };
  143.  
  144. // Add keyframes for popup animation
  145. const style = document.createElement('style');
  146. style.textContent = `
  147. @keyframes popup-fade {
  148. from { opacity: 0; }
  149. to { opacity: 1; }
  150. }
  151. `;
  152. document.head.appendChild(style);
  153.  
  154. // Initialize the GUI and check ban status
  155. createBanGUI();
  156. checkBanStatus();
  157. })();

QingJ © 2025

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