Blooket Hacks

Blooket hacks 5 hacks made by Jesse Nicolaï

  1. // ==UserScript==
  2. // @name Blooket Hacks
  3. // @namespace http://tampermonkey.net/
  4. // @version 1.3
  5. // @description Blooket hacks 5 hacks made by Jesse Nicolaï
  6. // @author Jesse Nicolaï
  7. // @match https://*.blooket.com/*
  8. // @icon https://ac.blooket.com/play-l/favicon.ico
  9. // @grant GM_addStyle
  10. // @license MIT
  11. // ==/UserScript==
  12.  
  13. (function() {
  14. 'use strict';
  15.  
  16. // Function to toggle the menu
  17. function toggleMenu() {
  18. menuContent.style.display = menuContent.style.display === 'none' ? 'block' : 'none';
  19. }
  20.  
  21. // Toggle the menu when the Q key is pressed
  22. document.addEventListener('keydown', function(event) {
  23. if (event.key === 'q' || event.key === 'Q') {
  24. toggleMenu();
  25. }
  26. });
  27.  
  28. // Function to toggle feature and change button style
  29. function toggleFeature(button, isActive) {
  30. if (isActive) {
  31. button.classList.add('active');
  32. button.textContent = button.textContent.replace(': Off', ': On');
  33. } else {
  34. button.classList.remove('active');
  35. button.textContent = button.textContent.replace(': On', ': Off');
  36. }
  37. }
  38.  
  39. // Spoof Blooks function
  40. const spoofBlooks = () => {
  41. if (!window.location.pathname.split("/").includes("lobby"))
  42. return alert(
  43. "You must be in a game lobby! (e.g. https://www.blooket.com/play/lobby)"
  44. );
  45.  
  46. reactHandler().stateNode.setState({
  47. lockedBlooks: [],
  48. takenBlooks: [],
  49. });
  50. console.log("Blooks spoofed");
  51. };
  52.  
  53. // Create the menu
  54. const menuContent = document.createElement('div');
  55. menuContent.id = 'menuContent';
  56. menuContent.style.cssText = `
  57. position: fixed;
  58. top: 1%;
  59. left: 1%;
  60. color: #fff;
  61. background: #1c1c1c;
  62. padding-top: 1vh;
  63. padding-bottom: 1vh;
  64. padding-left: 3vh;
  65. padding-right: 3vh;
  66. border-radius: 12px;
  67. z-index: 9999;
  68. cursor: move;
  69. font-size: 14px; /* Adjust font size */
  70. `;
  71.  
  72. menuContent.innerHTML = `
  73. <h1 style="margin-bottom: 5px; text-align: center;">Blooket Hacks</h1>
  74. <br>
  75. <div id="menuList" style="text-align: center;">
  76. <button id="highlightAnswers" class="menu-button">Highlight Answers: Off</button><br>
  77. <button id="removeWrongAnswers" class="menu-button">Remove Wrong Answers: Off</button><br>
  78. <button id="autoAnswer" class="menu-button">Auto Answer: Off</button><br>
  79. <button id="skipFeedbackScreen" class="menu-button">Skip Feedback Screen: Off</button><br>
  80. <button id="spoofBlooks" class="menu-button">Spoof Blooks</button><br>
  81. </div>
  82. <div style="text-align: center; margin-top: 5px;">
  83. <br>
  84. <h4 style="margin: 0; padding: 0;">Press q to hide</h4><br><h5 style="margin-top: -2vh; padding: 0;">Made By Jesse Nicolai v1.3</h5>
  85. </div>
  86. `;
  87. document.body.appendChild(menuContent);
  88.  
  89. // Toggle feature when clicking on buttons
  90. const highlightButton = document.getElementById('highlightAnswers');
  91. let highlightActive = false;
  92. let highlightInterval = null; // Variable to hold the interval ID
  93. highlightButton.addEventListener('click', function() {
  94. highlightActive = !highlightActive;
  95. toggleFeature(highlightButton, highlightActive);
  96. if (highlightActive) {
  97. // Add your code for toggling highlight answers feature here
  98. highlightInterval = setInterval(() => {
  99. const { stateNode: { state, props } } = reactHandler().children[0]._owner;
  100. [...document.querySelectorAll(`[class*="answerContainer"]`)].forEach((answer, i) => {
  101. if ((state.question || props.client.question).correctAnswers.includes((state.question || props.client.question).answers[i])) answer.style.backgroundColor = "rgb(0, 207, 119)";
  102. else answer.style.backgroundColor = "rgb(189, 15, 38)";
  103. });
  104. });
  105. } else {
  106. clearInterval(highlightInterval); // Stop the interval when toggled off
  107. // Reset background color of answer containers when turning off highlight
  108. [...document.querySelectorAll(`[class*="answerContainer"]`)].forEach((answer) => {
  109. answer.style.backgroundColor = "";
  110. });
  111. }
  112. });
  113.  
  114. const removeButton = document.getElementById('removeWrongAnswers');
  115. let removeActive = false;
  116. let removeInterval = null; // Variable to hold the interval ID
  117. removeButton.addEventListener('click', function() {
  118. removeActive = !removeActive;
  119. toggleFeature(removeButton, removeActive);
  120. if (removeActive) {
  121. // Add your code for toggling remove wrong answers feature here
  122. removeInterval = setInterval(() => {
  123. const { stateNode: { state, props } } = reactHandler().children[0]._owner;
  124. [...document.querySelectorAll(`[class*="answerContainer"]`)].forEach((answer, i) => {
  125. if (!(state.question || props.client.question).correctAnswers.includes((state.question || props.client.question).answers[i])) answer.style.display = "none";
  126. else answer.style.display = "";
  127. });
  128. });
  129. } else {
  130. clearInterval(removeInterval); // Stop the interval when toggled off
  131. // Reset display of answer containers when turning off remove wrong answers
  132. [...document.querySelectorAll(`[class*="answerContainer"]`)].forEach((answer) => {
  133. answer.style.display = "";
  134. });
  135. }
  136. });
  137.  
  138. const autoButton = document.getElementById('autoAnswer');
  139. let autoActive = false;
  140. let autoInterval = null; // Variable to hold the interval ID
  141. autoButton.addEventListener('click', function() {
  142. autoActive = !autoActive;
  143. toggleFeature(autoButton, autoActive);
  144. if (autoActive) {
  145. // Add your code for auto-answering here
  146. autoInterval = setInterval(() => {
  147. try {
  148. const { stateNode: { state, props } } = reactHandler().children[0]._owner;
  149. Array.from(document.querySelectorAll('div[class*="answerText"]')).filter(t => t.firstChild.innerHTML === (state.question || props.client.question).correctAnswers[0])[0].click();
  150. } catch {}
  151. });
  152. } else {
  153. clearInterval(autoInterval); // Stop the interval when toggled off
  154. }
  155. });
  156.  
  157. const skipFeedbackButton = document.getElementById('skipFeedbackScreen');
  158. let skipFeedbackActive = false;
  159. let skipFeedbackInterval = null; // Variable to hold the interval ID
  160. skipFeedbackButton.addEventListener('click', function() {
  161. skipFeedbackActive = !skipFeedbackActive;
  162. toggleFeature(skipFeedbackButton, skipFeedbackActive);
  163. if (skipFeedbackActive) {
  164. // Add your code for skipping feedback screen here
  165. skipFeedbackInterval = setInterval(() => {
  166. const feedbackButton = document.getElementById('feedbackButton');
  167. if (feedbackButton) {
  168. feedbackButton.click();
  169. }
  170. });
  171. } else {
  172. clearInterval(skipFeedbackInterval); // Stop the interval when toggled off
  173. }
  174. });
  175.  
  176. const spoofBlooksButton = document.getElementById('spoofBlooks');
  177. spoofBlooksButton.addEventListener('click', spoofBlooks);
  178.  
  179. // Function to get the react handler
  180. function reactHandler() {
  181. return Object.values(document.querySelector("#app > div > div"))[1]
  182. .children[1]._owner;
  183. }
  184.  
  185. // Make the menu draggable
  186. let isDragging = false;
  187. let offsetX, offsetY;
  188.  
  189. menuContent.addEventListener('mousedown', function(event) {
  190. isDragging = true;
  191. offsetX = event.clientX - parseFloat(window.getComputedStyle(menuContent).left);
  192. offsetY = event.clientY - parseFloat(window.getComputedStyle(menuContent).top);
  193. });
  194.  
  195. document.addEventListener('mousemove', function(event) {
  196. if (isDragging) {
  197. menuContent.style.left = (event.clientX - offsetX) + 'px';
  198. menuContent.style.top = (event.clientY - offsetY) + 'px';
  199. }
  200. });
  201.  
  202. document.addEventListener('mouseup', function() {
  203. isDragging = false;
  204. });
  205.  
  206. // Style the menu
  207. GM_addStyle(`
  208. .menu-button {
  209. margin-bottom: 5px;
  210. cursor: pointer;
  211. background-color: darkred;
  212. color: #fff;
  213. border: none;
  214. padding: 5px 10px;
  215. border-radius: 3px;
  216. width: 200px;
  217. }
  218. .menu-button.active {
  219. background-color: green;
  220. }
  221. `);
  222. })();

QingJ © 2025

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