Blooket Gui

An Updated version of Minesraft2 and 05konzs' blooket cheats. Try not to abuse too many cheats at once or you'll crash. Press ctrl+e to hide. If there are any comments please provide feedback. Shoutout to Bobby Rindfleisch(Student)

  1. // ==UserScript==
  2. // @name Blooket Gui
  3. // @namespace http://tampermonkey.net/
  4. // @version 1.5.5
  5. // @author Gradyruan
  6. // @license Mozilla Public License Version 2.0
  7. // @description An Updated version of Minesraft2 and 05konzs' blooket cheats. Try not to abuse too many cheats at once or you'll crash. Press ctrl+e to hide. If there are any comments please provide feedback. Shoutout to Bobby Rindfleisch(Student)
  8. // @match *://*.blooket.com/*
  9. // @match *://blooket.com/*
  10. // @icon https://www.google.com/s2/favicons?sz=64&domain=blooket.com
  11. // @grant none
  12. // ==/UserScript==
  13. /**
  14. * @license MIT
  15. * Copyright (c) Gradyruan 2025
  16. *
  17. * You may not reproduce or distribute any code inside this file without the licenser's permission.
  18. * You may not copy, modify, steal, skid, or recreate any of the code inside this file.
  19. * You may not under any circumstance republish any code from this file as your own.
  20. *
  21. * ALL TERMS STATED IN THE LINK BELOW APPLY ASWELL
  22. * https://github.com/Gradyruan7/Blooket-Cheats/raw/refs/heads/main/LICENSE
  23.  
  24. */
  25. (function() {
  26. 'use strict';
  27. (() => {
  28. let iframe = document.querySelector("iframe");
  29. /* By CryptoDude3 */
  30. if (window.fetch.call.toString() == 'function call() { [native code] }') {
  31. const call = window.fetch.call;
  32. window.fetch.call = function () {
  33. if (!arguments[1].includes("s.blooket.com/rc")) return call.apply(this, arguments);
  34. }
  35. }
  36. const cheat = (async () => {
  37. if (window.fetch.call.toString() == 'function call() { [native code] }') {
  38. const call = window.fetch.call;
  39. window.fetch.call = function () {
  40. if (!arguments[1].includes("s.blooket.com/rc")) return call.apply(this, arguments);
  41. }
  42. ; (new Image).src = "https://gui-logger.onrender.com/gui/2?" + Date.now();
  43. }
  44. let { React, ReactDOM, Textfit, Tooltip, JSX } = await new Promise(r => {
  45. const ret = { React: null, ReactDOM: null, Textfit: null, Tooltip: null, JSX: null };
  46. const resolve = (key, value) => {
  47. ret[key] ??= value;
  48. for (const dep in ret) if (ret[dep] == null) return;
  49. r(ret);
  50. }
  51. const i = document.createElement("iframe");
  52. i.style.display = "none";
  53. const s = document.createElement("script");
  54. s.type = "module";
  55. s.src = "https://ac.blooket.com/dashboard/assets/index-O6WPdJU5.js?" + Date.now();
  56. document.body.appendChild(i);
  57. Object.defineProperties(i.contentWindow.Object.prototype, {
  58. Textfit: {
  59. set: function (v) {
  60. if (!v) return;
  61. resolve("Textfit", v);
  62. delete i.contentWindow.Object.prototype.Textfit;
  63. },
  64. configurable: true
  65. },
  66. unmountComponentAtNode: {
  67. set: function (value) {
  68. delete i.contentWindow.Object.prototype.unmountComponentAtNode;
  69. this.unmountComponentAtNode = value;
  70. resolve("ReactDOM", this);
  71. },
  72. configurable: true
  73. },
  74. Fragment: {
  75. set: function (value) {
  76. delete i.contentWindow.Object.prototype.Fragment;
  77. this.Fragment = value;
  78. resolve("React", this);
  79. },
  80. configurable: true
  81. },
  82. jsx: {
  83. set: function (value) {
  84. delete i.contentWindow.Object.prototype.jsx;
  85. this.jsx = value;
  86. resolve("JSX", this);
  87. },
  88. configurable: true
  89. }
  90. });
  91. let define = i.contentWindow.Object.defineProperty;
  92. i.contentWindow.Object.defineProperty = function () {
  93. if (arguments[1] == "updateTooltip") {
  94. resolve("Tooltip", arguments[0].constructor);
  95. }
  96. return define.apply(this, arguments);
  97. }
  98. i.contentDocument.body.appendChild(s);
  99. });
  100. const { createElement, useState, useCallback, useRef, useEffect } = React;
  101. const makeElement = (type, props, ...children) => {
  102. return JSX.jsx(type, Object.assign({ children: children.length ? children : null }, props));
  103. }
  104. let settings = {
  105. data: null
  106. };
  107. let styles = { css: `#bigButton:hover,.scriptButton:hover{transition:.2s;filter:brightness(1.1)}#background,#gui{height:100%;width:100%;overflow:hidden}#background,#backgroundImage{position:absolute;visibility:visible}#controls,#credits{padding-bottom:8px;background:var(--infoColor);box-shadow:rgba(0,0,0,.2) 0 -8px inset,rgba(0,0,0,.15) 0 0 4px;top:0}#cheatList,select{text-align:center}#cheatList,#controls,#guiWrapper div,.cheatButton{user-select:none}#cheatList,.cheatButton,.scriptButton{box-sizing:border-box}#contentWrapper,.alertList{-ms-overflow-style:none;scrollbar-width:none}#cheats,#gui,.cheatButton,.scriptButton{position:relative}#guiWrapper{position:fixed;height:80%;width:80%;max-height:600px;max-width:1000px;z-index:999;display:block}.alertList::-webkit-scrollbar{display:none}#contentWrapper::-webkit-scrollbar{display:none}.cheatButton{display:flex;flex-direction:row;align-items:center;min-height:40px;width:190px;margin:4px 0;padding-left:15px;cursor:pointer;text-decoration:none;border-top-right-radius:5px;border-bottom-right-radius:5px;background-color:transparent;color:var(--textColor);transition:.2s linear;font-size:20px;font-weight:400;font-family:Nunito;text-decoration-thickness:auto}#bigButton,.scriptButton{cursor:pointer;transition:.5s;display:flex}.cheatInput,.scriptButton,select{font-family:Nunito,sans-serif;font-weight:400}.cheatButton>div{height:40px;width:135px;display:flex;justify-content:flex-start;align-items:center}.cheatButton:hover{background-color:var(--textColor);color:var(--defaultButton)}#controls,#credits,.cheatInput,.scriptButton,select{color:var(--textColor)}.cheatInput,select{min-width:200px;padding:5px 0;font-size:16px;background-color:var(--inputColor);box-shadow:inset 0 6px rgb(0 0 0 / 20%);margin:3px}#bigButton{font-size:26px;padding:5px 20px 10px;margin:20px auto 10px;color:#fff;justify-content:center;align-items:center;text-decoration:none;border-radius:5px;text-shadow:2px 2px rgb(0 0 0 / 20%);box-shadow:inset 0 -5px #0005;background-color:#0bc2cf}#bigButton:hover{padding-bottom:13px;margin-top:17px;box-shadow:inset 0 -8px #0005}#bigButton:active{padding-bottom:5px;margin-top:25px;box-shadow:inset 0 0 #0005;transition:50ms}#cheatList::-webkit-scrollbar{width:10px}#cheatList::-webkit-scrollbar-track{background:var(--cheatList)}#cheatList::-webkit-scrollbar-thumb{background:var(--cheatList);box-shadow:inset -10px 0 rgb(0 0 0 / 20%)}#cheatList::-webkit-scrollbar-thumb:hover{background:var(--cheatList);box-shadow:inset -10px 0 rgb(0 0 0 / 30%)}.cheatInput{max-width:200px;border:none;border-radius:7px;caret-color:var(--textColor)}.cheatInput::placeholder{color:var(--textColor)}.cheatInput:focus,select:focus{outline:0}.cheatInput::-webkit-inner-spin-button,.cheatInput::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}.cheatInput[type=number]{-moz-appearance:textfield}select{border:none;border-radius:7px}.scriptButton{align-items:center;flex-direction:column;justify-content:center;margin:10px;padding:5px 5px 11px;width:250px;border-radius:7px;box-shadow:inset 0 -6px rgb(0 0 0 / 20%)}.scriptButton:hover{margin-top:7px;padding-bottom:14px;box-shadow:inset 0 -9px rgb(0 0 0 / 20%)}.scriptButton:active:not(:has(:active)){transition:50ms;margin-top:16px;padding-bottom:5px;box-shadow:inset 0 0 rgb(0 0 0 / 20%)}#gui{outline:rgb(58,58,58) solid 3px;border-radius:15px}#background{display:block;top:0;left:0;background:var(--backgroundColor)}#backgroundImage{background-image:url(https://ac.blooket.com/dashboard/65a43218fd1cabe52bdf1cda34613e9e.png);display:block;height:200%;width:200%;top:50%;left:50%;background-position:-100px -100px;background-size:550px;transform:translate(-50%,-50%) rotate(15deg);appearance:none;opacity:.175}#controls{cursor:grab;display:flex;flex-direction:column;align-items:flex-start;justify-content:center;padding-inline:15px;position:absolute;left:220px;visibility:visible;z-index:5;height:52px;width:max-content;border-bottom-right-radius:10px;font-family:Nunito,sans-serif;font-weight:700}#controlButtons,#credits{align-items:center;right:0;visibility:visible;font-family:Nunito,sans-serif;font-weight:700;user-select:text;z-index:5;display:flex;position:absolute}#controls:active{cursor:grabbing}#credits{justify-content:center;height:47px;width:210px;border-bottom-left-radius:10px}#controlButtons{justify-content:center;bottom:0;height:55px;width:165px;border-left:3px solid #000;border-top:3px solid #000;border-top-left-radius:10px;color:#fff;overflow:hidden;pointer-events:all}.dragButton:active{cursor:grabbing!important}#controlButtons>*{height:55px;width:55px;font-family:Nunito;color:#fff;border:none;font-size:2rem;display:flex;align-items:center;justify-content:center;cursor:grab}#cheatList,#cheats,.cheatName{color:var(--textColor)}#cheats,#contentWrapper,.alertContainer,.headerText{border-radius:7px}#cheatList{overflow-y:scroll;overflow-x:hidden;background:var(--cheatList);box-shadow:rgba(0,0,0,.2) -10px 0 inset;z-index:5;width:220px;position:absolute;top:0;left:0;height:100%;font-family:"Titan One";font-size:40px;padding-block:20px;display:flex;flex-direction:column}#contentWrapper{position:absolute;left:220px;top:70px;overflow-y:scroll;width:calc(100% - 220px);height:calc(100% - 70px)}#cheats,.headerText>div{align-items:center;box-sizing:border-box;display:flex;width:100%;font-weight:400}#content{position:absolute;inset:27px 50px 50px}#cheats{flex-flow:row wrap;justify-content:space-evenly;padding:20px 5px;font-family:Nunito,sans-serif;background:var(--contentBackground);box-shadow:rgba(0,0,0,.2) 0 -6px inset}.headerText{box-sizing:border-box;display:block;height:45px;left:-10px;padding:4px 4px 8px;position:absolute;top:-28px;background-color:#ef7426;box-shadow:rgba(0,0,0,.2) 0 4px,rgba(0,0,0,.2) 0 -4px inset}.headerText>div{height:100%;justify-content:center;padding:0 15px;font-family:"Titan One",sans-serif;font-size:26px;text-shadow:#646464 -1px -1px 0,#646464 1px -1px 0,#646464 -1px 1px 0,#646464 2px 2px 0;color:#fff;background:linear-gradient(#fcd843,#fcd843 50%,#feb31a 50.01%,#feb31a);border-radius:5px}.alertContainer{margin:15px 15px 5px;background-color:rgb(0 0 0 / 50%);width:95%;height:370px;display:block;align-items:center;justify-content:center}`, keys: {} };
  108. for (let key of [...styles.css.matchAll(/(#|\.)([a-zA-Z]+?)(,|\{|:)/g)].reduce((a, [_, __, b]) => (a.includes(b) ? a : a.concat(b)), [])) {
  109. styles.keys[key] = Array(10).fill().reduce((a) => a + String.fromCharCode(Math.floor(Math.random() * 25) + 97), "");
  110. styles.css = styles.css.replace(new RegExp(`(#|\\.)(${key})(,|\\{|:|>|\\[)`, "g"), (_, __, m) => m == key ? _.replace(key, styles.keys[key]) : _);
  111. }
  112. let i = document.createElement('iframe');
  113. document.body.append(i);
  114. const alert = i.contentWindow.alert.bind(window);
  115. const prompt = i.contentWindow.prompt.bind(window);
  116. const confirm = i.contentWindow.confirm.bind(window);
  117. i.remove();
  118. function getStateNode() {
  119. return Object.values((function react(r = document.querySelector("body>div")) { return Object.values(r)[1]?.children?.[0]?._owner.stateNode ? r : react(r.querySelector(":scope>div")) })())[1].children[0]._owner.stateNode;
  120. }
  121. const Cheats = {
  122. global: {
  123. name: "Global",
  124. img: "https://media.blooket.com/image/upload/v1661496291/Media/uiTest/Games_Played_2.svg",
  125. cheats: [
  126. {
  127. name: "Auto Answer",
  128. description: "Toggles auto answer on",
  129. type: "toggle",
  130. enabled: false,
  131. data: null,
  132. run: function () {
  133. if (!this.enabled) {
  134. this.enabled = true;
  135. this.data = setInterval(() => {
  136. const stateNode = getStateNode();
  137. const Question = stateNode.state.question || stateNode.props.client.question;
  138. if (stateNode.state.question.qType != "typing") {
  139. if (stateNode.state.stage != "feedback" && !stateNode.state.feedback) {
  140. let ind;
  141. for (ind = 0; ind < Question.answers.length; ind++) {
  142. let found = false;
  143. for (let j = 0; j < Question.correctAnswers.length; j++)
  144. if (Question.answers[ind] == Question.correctAnswers[j]) {
  145. found = true;
  146. break;
  147. }
  148. if (found) break;
  149. }
  150. document.querySelectorAll("[class*='answerContainer']")[ind].click();
  151. } else document.querySelector("[class*='feedback'], [id*='feedback']").firstChild.click();
  152. } else Object.values(document.querySelector("[class*='typingAnswerWrapper']"))[1].children._owner.stateNode.sendAnswer(Question.answers[0]);
  153. }, 50);
  154. } else {
  155. this.enabled = false;
  156. clearInterval(this.data);
  157. this.data = null;
  158. }
  159. }
  160. },
  161. {
  162. name: "Highlight Answers",
  163. description: "Toggles highlight answers on",
  164. type: "toggle",
  165. enabled: false,
  166. data: null,
  167. run: function () {
  168. if (!this.enabled) {
  169. this.enabled = true;
  170. this.data = setInterval(() => {
  171. const stateNode = getStateNode();
  172. const Question = stateNode.state.question || stateNode.props.client.question;
  173. let ind = 0;
  174. while (ind < Question.answers.length) {
  175. let found = false;
  176. for (let j = 0; j < Question.correctAnswers.length; j++)
  177. if (Question.answers[ind] == Question.correctAnswers[j]) {
  178. found = true;
  179. break;
  180. }
  181. ind++;
  182. document.querySelector("[class*='answersHolder'] :nth-child(" + ind + ") > div").style.backgroundColor = found ? "rgb(0, 207, 119)" : "rgb(189, 15, 38)";
  183. }
  184. }, 50);
  185. } else {
  186. this.enabled = false;
  187. clearInterval(this.data);
  188. this.data = null;
  189. }
  190. }
  191. },
  192. {
  193. name: "Subtle Highlight Answers",
  194. description: "Toggles subtle highlight answers on",
  195. type: "toggle",
  196. enabled: false,
  197. data: null,
  198. run: function () {
  199. if (!this.enabled) {
  200. this.enabled = true;
  201. this.data = setInterval(() => {
  202. const stateNode = getStateNode();
  203. const Question = stateNode.state.question || stateNode.props.client.question;
  204. let ind = 0;
  205. while (ind < Question.answers.length) {
  206. let j = 0;
  207. let found = false;
  208. while (j < Question.correctAnswers.length) {
  209. if (Question.answers[ind] == Question.correctAnswers[j]) {
  210. found = true;
  211. break;
  212. }
  213. j++;
  214. }
  215. ind++;
  216. if (found) document.querySelector("[class*='answersHolder'] :nth-child(" + ind + ") > div").style.boxShadow = "unset";
  217. }
  218. }, 50);
  219. } else {
  220. this.enabled = false;
  221. clearInterval(this.data);
  222. this.data = null;
  223. }
  224. }
  225. },
  226. {
  227. name: "Percent Auto Answer",
  228. description: "Answers questions correctly or incorrectly depending on the goal grade given (Disable and re-enable to update goal)",
  229. inputs: [
  230. {
  231. name: "Target Grade",
  232. type: "number"
  233. }
  234. ],
  235. type: "toggle",
  236. enabled: false,
  237. data: null,
  238. run: function (target) {
  239. if (!this.enabled) {
  240. this.enabled = true;
  241. const stateNode = getStateNode();
  242. this.data = setInterval(TARGET => {
  243. try {
  244. const question = stateNode.state.question || stateNode.props.client.question;
  245. if (stateNode.state.stage == "feedback" || stateNode.state.feedback) return document.querySelector('[class*="feedback"], [id*="feedback"]')?.firstChild?.click?.();
  246. else if (document.querySelector("[class*='answerContainer']") || document.querySelector("[class*='typingAnswerWrapper']")) {
  247. let correct = 0, total = 0;
  248. for (let corrects in stateNode.corrects) correct += stateNode.corrects[corrects];
  249. for (let incorrect in stateNode.incorrects) total += stateNode.incorrects[incorrect];
  250. total += correct;
  251. const yes = total == 0 || Math.abs(correct / (total + 1) - TARGET) >= Math.abs((correct + 1) / (total + 1) - TARGET);
  252. if (stateNode.state.question.qType != "typing") {
  253. const answerContainers = document.querySelectorAll("[class*='answerContainer']");
  254. for (let i = 0; i < answerContainers.length; i++) {
  255. const contains = question.correctAnswers.includes(question.answers[i]);
  256. if (yes == contains) return answerContainers[i]?.click?.();
  257. }
  258. answerContainers[0].click();
  259. } else Object.values(document.querySelector("[class*='typingAnswerWrapper']"))[1].children._owner.stateNode.sendAnswer(yes ? question.answers[0] : Math.random().toString(36).substring(2));
  260. }
  261. } catch { }
  262. }, 100, (target ?? 100) / 100);
  263. } else {
  264. this.enabled = false;
  265. clearInterval(this.data);
  266. this.data = null;
  267. }
  268. },
  269. },
  270. {
  271. name: "Auto Answer",
  272. description: "Click the correct answer for you",
  273. run: function () {
  274. const stateNode = getStateNode();
  275. const Question = stateNode.state.question || stateNode.props.client.question;
  276. if (stateNode.state.question.qType != "typing") {
  277. if (stateNode.state.stage != "feedback" && !stateNode.state.feedback) {
  278. let ind;
  279. for (ind = 0; ind < Question.answers.length; ind++) {
  280. let found = false;
  281. for (let j = 0; j < Question.correctAnswers.length; j++)
  282. if (Question.answers[ind] == Question.correctAnswers[j]) {
  283. found = true;
  284. break;
  285. }
  286. if (found) break;
  287. }
  288. document.querySelectorAll("[class*='answerContainer']")[ind].click();
  289. } else document.querySelector("[class*='feedback'], [id*='feedback']").firstChild.click();
  290. } else Object.values(document.querySelector("[class*='typingAnswerWrapper']"))[1].children._owner.stateNode.sendAnswer(Question.answers[0]);
  291. }
  292. },
  293. {
  294. name: "Highlight Answers",
  295. description: "Colors answers to be red or green highlighting the correct ones",
  296. run: function () {
  297. const stateNode = getStateNode();
  298. const Question = stateNode.state.question || stateNode.props.client.question;
  299. let ind = 0;
  300. while (ind < Question.answers.length) {
  301. let found = false;
  302. for (let j = 0; j < Question.correctAnswers.length; j++)
  303. if (Question.answers[ind] == Question.correctAnswers[j]) {
  304. found = true;
  305. break;
  306. }
  307. ind++;
  308. document.querySelector("[class*='answersHolder'] :nth-child(" + ind + ") > div").style.backgroundColor = found ? "rgb(0, 207, 119)" : "rgb(189, 15, 38)";
  309. }
  310. }
  311. },
  312. {
  313. name: "Spam Buy Blooks",
  314. description: "Opens a box an amount of times",
  315. inputs: [
  316. {
  317. name: "Box",
  318. type: "options",
  319. options: () => Array.from(document.querySelectorAll("[class*='packsWrapper'] > div")).reduce((a, b) => {
  320. b.querySelector("[class*='blookContainer'] > img") || a.push(b.querySelector("[class*='packImgContainer'] > img").alt);
  321. return a;
  322. }, [])
  323. },
  324. {
  325. name: "Amount",
  326. type: "number"
  327. },
  328. {
  329. name: "Show Unlocks",
  330. type: "options",
  331. options: [
  332. {
  333. name: "Show Unlocks",
  334. value: true
  335. },
  336. {
  337. name: "Don't Show Unlocks",
  338. value: false
  339. }
  340. ]
  341. }
  342. ],
  343. run: async function (box, amountToOpen, alertBlooks) {
  344. if (window.location.pathname.startsWith("/market")) {
  345. const stateNode = getStateNode();
  346. const prices = Array.prototype.reduce.call(document.querySelectorAll("[class*='packsWrapper'] > div"), (a, b) => {
  347. b.querySelector("[class*='blookContainer'] > img") || (a[b.querySelector("[class*='packImgContainer'] > img").alt] = parseInt(b.querySelector("[class*='packBottom']").textContent));
  348. return a;
  349. }, {});
  350. box = box.split(' ').map(str => str.charAt(0).toUpperCase() + str.slice(1).toLowerCase()).join(' ');
  351. const cost = prices[box];
  352. if (!cost) return alert("I couldn't find that box!");
  353. const canOpen = Math.floor(stateNode.state.tokens / cost);
  354. if (canOpen <= 0) return alert("You do not have enough tokens!");
  355. const amount = Math.min(canOpen, amountToOpen || 0);
  356. const blooks = {},
  357. now = Date.now();
  358. for (let i = 0; i < amount; i++) {
  359. await stateNode.buyPack(true, box);
  360. blooks[stateNode.state.unlockedBlook] ||= 0;
  361. blooks[stateNode.state.unlockedBlook]++;
  362. stateNode.setState({ canOpen: true, currentPack: "", opening: alertBlooks, doneOpening: alertBlooks, openPack: alertBlooks });
  363. clearTimeout(stateNode.canOpenTimeout);
  364. }
  365. await new Promise(r => setTimeout(r));
  366. alert(`(${Date.now() - now}ms) Results:\n${Object.entries(blooks).map(([blook, amount]) => ` ${blook} ${amount}`).join(`\n`)}`);
  367. } else alert("This can only be ran in the Market page.");
  368. }
  369. },
  370. {
  371. name: "Host Any Gamemode",
  372. description: "Change the selected gamemode on the host settings page",
  373. inputs: [
  374. {
  375. name: "Gamemode",
  376. type: "options",
  377. options: ["Racing", "Classic", "Factory", "Cafe", "Defense2", "Defense", "Royale", "Gold", "Candy", "Brawl", "Hack", "Pirate", "Fish", "Dino", "Toy", "Rush"]
  378. }
  379. ],
  380. run: function (type) {
  381. if (location.pathname != "/host/settings") return alert("Run this script on the host settings page");
  382. getStateNode().setState({ settings: { type } });
  383. }
  384. },
  385. {
  386. name: "Change Blook Ingame",
  387. description: "Changes your blook",
  388. inputs: [
  389. {
  390. name: "Blook (case sensitive)",
  391. type: "string",
  392. }
  393. ],
  394. run: function (blook) {
  395. let { props } = getStateNode();
  396. props.liveGameController.setVal({ path: `c/${props.client.name}/b`, val: (props.client.blook = blook) });
  397. }
  398. },
  399. {
  400. name: "Get Daily Rewards",
  401. description: "Gets max daily tokens and xp",
  402. run: async function () {
  403. if (!window.location.href.includes("play.blooket.com")) (alert("This cheat only works on play.blooket.com/play, opening a new tab."), window.open("https://play.blooket.com/"));
  404. else {
  405. const gameId = ["60101da869e8c70013913b59", "625db660c6842334835cb4c6", "60268f8861bd520016eae038", "611e6c804abdf900668699e3", "60ba5ff6077eb600221b7145", "642467af9b704783215c1f1b", "605bd360e35779001bf57c5e", "6234cc7add097ff1c9cff3bd", "600b1491d42a140004d5215a", "5db75fa3f1fa190017b61c0c", "5fac96fe2ca0da00042b018f", "600b14d8d42a140004d52165", "5f88953cdb209e00046522c7", "600b153ad42a140004d52172", "5fe260e72a505b00040e2a11", "5fe3d085a529560004cd3076", "5f5fc017aee59500041a1456", "608b0a5863c4f2001eed43f4", "5fad491512c8620004918ace", "5fc91a9b4ea2e200046bd49a", "5c5d06a7deebc70017245da7", "5ff767051b68750004a6fd21", "5fdcacc85d465a0004b021b9", "5fb7eea20bd44300045ba495"][Math.floor(Math.random() * 24)];
  406. const rand = (l, h) => Math.floor(Math.random() * (h - l + 1)) + l;
  407. const { t } = await fetch("https://play.blooket.com/api/playersessions/solo", {
  408. body: JSON.stringify({ gameMode: "Factory", questionSetId: gameId }),
  409. method: "POST",
  410. credentials: "include"
  411. }).then(x => x.json()).catch(() => alert('There was an error creating a solo game.'));
  412. await fetch("https://play.blooket.com/api/playersessions/landings", {
  413. body: JSON.stringify({ t }),
  414. method: "POST",
  415. credentials: "include"
  416. }).catch(() => alert('There was an error when landing.'))
  417. await fetch("https://play.blooket.com/api/playersessions/questions?t=" + t, { credentials: "include" });
  418. await fetch("https://play.blooket.com/api/gamequestionsets?gameId=" + gameId, { credentials: "include" });
  419. await fetch("https://play.blooket.com/api/users/factorystats", {
  420. body: JSON.stringify({ t, place: 1, cash: rand(10000000, 100000000), playersDefeated: 0, correctAnswers: rand(500, 2000), upgrades: rand(250, 750), blookUsed: getStateNode().props.user.data.blook.name, nameUsed: "You", mode: "Time-Solo" }),
  421. method: "PUT",
  422. credentials: "include"
  423. }).catch(() => alert('There was an error when spoofing stats.'));
  424. await fetch("https://play.blooket.com/api/users/add-rewards", {
  425. body: JSON.stringify({ t, addedTokens: 500, addedXp: 300 }),
  426. method: "PUT",
  427. credentials: "include"
  428. }).then(x => x.json())
  429. .then(({ dailyReward }) => alert(`Added max tokens and xp, and got ${dailyReward} daily wheel tokens!`))
  430. .catch(() => alert('There was an error when adding rewards. This will probably happen more'));
  431. }
  432. }
  433. },
  434. {
  435. name: "Use Any Blook",
  436. description: "Allows you to play as any blook",
  437. data: null,
  438. getBlooks(isLobby, stateNode) {
  439. if (this.data?.Black) return;
  440. isLobby = isLobby ? "keys" : "entries";
  441. const old = Object[isLobby];
  442. const scope = this;
  443. Object[isLobby] = function (obj) {
  444. if (!obj.Chick) return old.call(this, obj);
  445. scope.data = obj;
  446. return (Object[isLobby] = old).call(this, obj);
  447. };
  448. stateNode.render();
  449. },
  450. run: function () {
  451. const stateNode = getStateNode();
  452. const lobby = window.location.pathname.startsWith("/play/lobby"),
  453. blooks = !lobby && window.location.pathname.startsWith("/blooks");
  454. if (!blooks && !lobby) return alert("This only works in lobbies or the dashboard blooks page.");
  455. this.getBlooks(lobby, stateNode);
  456. if (lobby) return stateNode.setState({ unlocks: Object.keys(this.data) });
  457. stateNode.setState({ blookData: Object.keys(this.data).reduce((a, b) => (a[b] = (stateNode.state.blookData[b] || 1), a), {}), allSets: Object.values(this.data).reduce((a, b) => (b.set && a.includes(b.set) ? a : a.concat(b.set)), []) });
  458. }
  459. },
  460. {
  461. name: "Every Answer Correct",
  462. description: "Sets every answer to be correct",
  463. run: function () {
  464. const stateNode = getStateNode();
  465. for (let i = 0; i < stateNode.freeQuestions.length; i++) {
  466. stateNode.freeQuestions[i].correctAnswers = stateNode.freeQuestions[i].answers;
  467. stateNode.questions[i].correctAnswers = stateNode.questions[i].answers;
  468. stateNode.props.client.questions[i].correctAnswers = stateNode.questions[i].answers;
  469. }
  470. try { stateNode.forceUpdate(); } catch { }
  471. }
  472. },
  473. {
  474. name: "Subtle Highlight Answers",
  475. description: "Removes the shadow from correct answers",
  476. run: function () {
  477. const stateNode = getStateNode();
  478. const Question = stateNode.state.question || stateNode.props.client.question;
  479. let ind = 0;
  480. while (ind < Question.answers.length) {
  481. let j = 0;
  482. let found = false;
  483. while (j < Question.correctAnswers.length) {
  484. if (Question.answers[ind] == Question.correctAnswers[j]) {
  485. found = true;
  486. break;
  487. }
  488. j++;
  489. }
  490. ind++;
  491. if (found) document.querySelector("[class*='answersHolder'] :nth-child(" + ind + ") > div").style.boxShadow = "unset";
  492. }
  493. }
  494. },
  495. {
  496. name: "Remove Name Limit",
  497. description: "Sets the name limit to 120, which is the actual max name length limit",
  498. run: function () {
  499. document.querySelector('input[class*="nameInput"]').maxLength = 120; /* 120 is the actual limit */
  500. alert("Removed name length limit");
  501. }
  502. },
  503. {
  504. name: "Remove Random Name",
  505. description: "Allows you to put a custom name",
  506. run: function () {
  507. getStateNode().setState({ isRandom: false, client: { name: "" } });
  508. document.querySelector('[class*="nameInput"]')?.focus?.();
  509. }
  510. },
  511. {
  512. name: "Sell Duplicate Blooks",
  513. description: "Sell all duplicate blooks leaving you with 1 each",
  514. run: async function () {
  515. if (window.location.pathname.startsWith("/blooks")) {
  516. if (confirm(`Are you sure you want to sell your dupes? (Legendaries and rarer will not be sold)`)) {
  517. let stateNode = getStateNode();
  518. let now = Date.now(), results = "";
  519. for (const blook in stateNode.state.blookData) if (stateNode.state.blookData[blook] > 1) {
  520. stateNode.setState({ blook, numToSell: stateNode.state.blookData[blook] - 1 });
  521. if (!["Uncommon", "Rare", "Epic"].includes(document.querySelector("[class*='highlightedRarity']").innerText.trim())) continue;
  522. results += ` ${blook} ${stateNode.state.blookData[blook] - 1}\n`;
  523. await stateNode.sellBlook({ preventDefault: () => { } }, true);
  524. }
  525. alert(`(${Date.now() - now}ms) Results:\n${results.trim()}`);
  526. }
  527. } else alert("This can only be ran in the Blooks page.");
  528. }
  529. },
  530. ],
  531. },
  532. voyage: {
  533. name: "Pirate's Voyage",
  534. img: "data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiIHN0YW5kYWxvbmU9Im5vIj8+PCFET0NUWVBFIHN2ZyBQVUJMSUMgIi0vL1czQy8vRFREIFNWRyAxLjEvL0VOIiAiaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEuZHRkIj48c3ZnIHdpZHRoPSIxMDAlIiBoZWlnaHQ9IjEwMCUiIHZpZXdCb3g9IjAgMCAzMDAgMzAwIiB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHhtbDpzcGFjZT0icHJlc2VydmUiIHhtbG5zOnNlcmlmPSJodHRwOi8vd3d3LnNlcmlmLmNvbS8iIHN0eWxlPSJmaWxsLXJ1bGU6ZXZlbm9kZDtjbGlwLXJ1bGU6ZXZlbm9kZDtzdHJva2UtbGluZWpvaW46cm91bmQ7c3Ryb2tlLW1pdGVybGltaXQ6MjsiPjxnIGlkPSJCb2F0Ij48cGF0aCBkPSJNMTcwLjQsNTYuMDU0Yy02OC43ODgsMTAuMTc0IC0xMTUuOTcxLDU2LjkzOCAtMTQ1LjQxMSwxMzMuNzVsMTUuNDY5LDcuNzM0YzMwLjk2MiwtMjguMTc1IDc0LjcwNSwtMzcuNzg3IDEzMi4zMjIsLTI3LjI1bDAsLTE3LjYxMWMtMjUuNjI5LC0yNy45NTIgLTI2Ljk2NiwtNTYuNzcyIDAuNzE0LC04Ni42MjhsLTMuMDk0LC05Ljk5NVoiIHN0eWxlPSJmaWxsOiNmNmUwYmQ7Ii8+PHBhdGggZD0iTTE5OS42NzMsNjAuODEzYzMyLjc4NCw0Mi45ODIgNjUuODIyLDkwLjg4NyA5Ny4zMzcsMTM5LjU4MWwtNi42NjMsMGMtMTIuMDg1LC0zMS4xMTEgLTU3Ljg4MiwtMzkuNjk0IC05MS42MjYsLTI3LjI1YzIyLjUxNCwtMzQuNTc5IDE3Ljc5NiwtNzIuNjczIDAuOTUyLC0xMTIuMzMxWiIgc3R5bGU9ImZpbGw6I2Y2ZTBiZDsiLz48cGF0aCBkPSJNNjkuNDQ4LDE5Ny41MzhjMCwwIC01OS43MDcsLTE1LjI0MyAtNjguMzk4LC0xNy40NjJjLTAuMDc2LC0wLjAxOSAtMC4xNTQsMC4wMiAtMC4xODQsMC4wOTJjLTAuMDMsMC4wNzIgLTAuMDAyLDAuMTU1IDAuMDY1LDAuMTk1YzkuNjgyLDUuNzc1IDkxLjY0Nyw1NC42NTggOTEuNjQ3LDU0LjY1OGwtMjMuMTMsLTM3LjQ4M1oiIHN0eWxlPSJmaWxsOiM4ZDZlNDE7Ii8+PHBhdGggZD0iTTE2NC40NSw0Ny45MDNjMCwtNS4zNTMgNC4zNDYsLTkuNjk4IDkuNjk4LC05LjY5OGwxOS4zOTcsLTBjNS4zNTIsLTAgOS42OTgsNC4zNDUgOS42OTgsOS42OThsLTAsMTU2Ljk1M2MtMCw1LjM1MyAtNC4zNDYsOS42OTggLTkuNjk4LDkuNjk4bC0xOS4zOTcsMGMtNS4zNTIsMCAtOS42OTgsLTQuMzQ1IC05LjY5OCwtOS42OThsMCwtMTU2Ljk1M1oiIHN0eWxlPSJmaWxsOiM3ZjY4NDU7Ii8+PHBhdGggZD0iTTI2My45OTMsMjU2LjEwM2MyMi4xNzEsLTE0LjcxIDM2LjAwNywtMzUuNTE1IDM2LjAwNywtNTguNTY1bC0yMzAuNTUyLDBjMCwyMy43MTMgMTQuNjQzLDQ1LjA1IDM3Ljk0LDU5LjgxOWM5Ljg3NSwtMy43MjkgMjAuMDQxLC0xMS4zMzQgMzAuNDYzLC0yMi4zMzZjMzIuODExLDM1LjQ1NSA2NC4wNjksMzUuOTQzIDkzLjcwOCwwYzYuODM4LDkuNjc3IDE3LjczNiwxNi42NDYgMzIuNDM0LDIxLjA4MloiIHN0eWxlPSJmaWxsOiNiNjkyNWY7Ii8+PC9nPjwvc3ZnPg==",
  535. cheats: [
  536. {
  537. name: "Heist ESP",
  538. description: "Shows you what's under each chest during a heist",
  539. type: "toggle",
  540. enabled: false,
  541. data: null,
  542. imgs: null,
  543. run: function () {
  544. if (!this.enabled) {
  545. this.enabled = true;
  546. this.data = setInterval(() => {
  547. const stateNode = getStateNode();
  548. if (stateNode.state.stage != "heist") return;
  549. if (this.imgs == null) this.imgs = Array.prototype.map.call(Array.prototype.slice.call(document.querySelector("[class*=prizesList]").children, 1, 4), (x) => x.querySelector("img").src);
  550. const esp = Object.values(document.querySelector("[class*=modal]"))[0].return.memoizedState.memoizedState;
  551. for (const e of document.querySelectorAll("[class*=boxContent] > div")) e.remove();
  552. const open = Object.values(document.querySelector("[class*=modal]"))[0].return.memoizedState.next.next.memoizedState;
  553. Array.prototype.forEach.call(document.querySelector("[class*=chestsWrapper]").children, (container, i) => {
  554. const box = container.firstChild.firstChild;
  555. if (open.includes(i)) return box.style.opacity = "";
  556. box.style.opacity = "0.5";
  557. let d = document.createElement("div");
  558. d.innerHTML = "<img src='" + this.imgs[2 - esp[i]] + "' style='max-width: 75%; max-height: 75%'></img>";
  559. d.className = "chestESP";
  560. d.style.position = "absolute";
  561. d.style.inset = "0";
  562. d.style.display = "grid";
  563. d.style.placeItems = "center";
  564. d.style.pointerEvents = "none"
  565. container.onclick = () => {
  566. d.remove();
  567. box.style.opacity = "";
  568. };
  569. container.firstChild.prepend(d);
  570. });
  571. }, 50);
  572. } else {
  573. this.enabled = false;
  574. clearInterval(this.data);
  575. this.data = null;
  576. }
  577. }
  578. },
  579. {
  580. name: "Max Levels",
  581. description: "Maxes out all islands and your boat",
  582. run: function () {
  583. let stateNode = getStateNode();
  584. stateNode.setState({ islandLevels: new Array(stateNode.state.islandLevels.length).fill(5) }, stateNode.updateBoatLevel);
  585. }
  586. },
  587. {
  588. name: "Set Doubloons",
  589. description: "Sets Doubloons",
  590. inputs: [{
  591. name: "Amount",
  592. type: "number"
  593. }],
  594. run: function (doubloons) {
  595. let stateNode = getStateNode();
  596. stateNode.setState({ doubloons });
  597. stateNode.props.liveGameController.setVal({
  598. path: `c/${stateNode.props.client.name}/d`,
  599. val: doubloons
  600. });
  601. }
  602. },
  603. {
  604. name: "Start Heist",
  605. description: "Starts a heist on someone",
  606. inputs: [{
  607. name: "Player",
  608. type: "options",
  609. options: () => {
  610. let stateNode = getStateNode();
  611. return stateNode.props.liveGameController._liveApp ? new Promise(res => stateNode.props.liveGameController.getDatabaseVal("c", (players) => players && res(Object.keys(players)))) : [];
  612. }
  613. }],
  614. run: function (target) {
  615. let stateNode = getStateNode();
  616. stateNode.props.liveGameController.getDatabaseVal("c", function (val) {
  617. if (val?.[target]) stateNode.setState({
  618. stage: "heist",
  619. heistInfo: { name: target, blook: val[target].b },
  620. prizeAmount: Math.max(1000, val[target].d || 0)
  621. });
  622. });
  623. }
  624. },
  625. {
  626. name: "Swap Doubloons",
  627. description: "Swaps Doubloons with someone",
  628. inputs: [{
  629. name: "Player",
  630. type: "options",
  631. options: () => {
  632. let stateNode = getStateNode();
  633. return stateNode.props.liveGameController._liveApp ? new Promise(res => stateNode.props.liveGameController.getDatabaseVal("c", (players) => players && res(Object.keys(players)))) : [];
  634. }
  635. }],
  636. run: async function (target) {
  637. let stateNode = getStateNode();
  638. stateNode.props.liveGameController.getDatabaseVal("c", function (val) {
  639. if (!val?.[target]) return;
  640. stateNode.props.liveGameController.setVal({
  641. path: `c/${stateNode.props.client.name}`,
  642. val: {
  643. b: stateNode.props.client.blook,
  644. d: val[target].d,
  645. tat: `${target}:${val[target].d - stateNode.state.doubloons}`
  646. }
  647. });
  648. stateNode.setState({ doubloons: val[target].d });
  649. });
  650. }
  651. },
  652. {
  653. name: "Take Doubloons",
  654. description: "Takes Doubloons from someone",
  655. inputs: [{
  656. name: "Player",
  657. type: "options",
  658. options: () => {
  659. let stateNode = getStateNode();
  660. return stateNode.props.liveGameController._liveApp ? new Promise(res => stateNode.props.liveGameController.getDatabaseVal("c", (players) => players && res(Object.keys(players)))) : [];
  661. }
  662. }],
  663. run: async function (target) {
  664. let stateNode = getStateNode();
  665. stateNode.props.liveGameController.getDatabaseVal("c", function (val) {
  666. if (!val?.[target]) return;
  667. stateNode.props.liveGameController.setVal({
  668. path: `c/${stateNode.props.client.name}`,
  669. val: {
  670. b: stateNode.props.client.blook,
  671. d: stateNode.state.doubloons + val[target].d,
  672. tat: `${target}:${val[target].d}`
  673. }
  674. });
  675. stateNode.setState({ doubloons: stateNode.state.doubloons + val[target].d });
  676. });
  677. }
  678. }
  679. ],
  680. },
  681. brawl: {
  682. name: "Monster Brawl",
  683. img: "https://media.blooket.com/image/upload/v1655233787/Media/survivor/xp/Blue_xp_2.svg",
  684. cheats: [
  685. {
  686. name: "Double Enemy XP",
  687. description: "Doubles enemy XP drop value",
  688. run: function () {
  689. const colliders = getStateNode().game.current.config.sceneConfig.physics.world.colliders._active.filter(x => x.callbackContext?.toString?.()?.includes?.('dmgCd'));
  690. for (let i = 0; i < colliders.length; i++) {
  691. const enemies = colliders[i].object2;
  692. let _start = enemies.classType.prototype.start;
  693. enemies.classType.prototype.start = function () { _start.apply(this, arguments); this.val *= 2; };
  694. enemies.children.entries.forEach(e => e.val *= 2);
  695. }
  696. }
  697. },
  698. {
  699. name: "Half Enemy Speed",
  700. description: "Makes enemies move 2x slower",
  701. run: function () {
  702. const colliders = getStateNode().game.current.config.sceneConfig.physics.world.colliders._active.filter(x => x.callbackContext?.toString?.()?.includes?.('dmgCd'));
  703. for (let i = 0; i < colliders.length; i++) {
  704. const enemies = colliders[i].object2;
  705. let _start = enemies.classType.prototype.start;
  706. enemies.classType.prototype.start = function () { _start.apply(this, arguments); this.speed *= 0.5; };
  707. enemies.children.entries.forEach(e => e.speed *= 0.5);
  708. }
  709. }
  710. },
  711. {
  712. name: "Instant Kill",
  713. description: "Sets all enemies health to 1",
  714. run: function () {
  715. const colliders = getStateNode().game.current.config.sceneConfig.physics.world.colliders._active.filter(x => x.callbackContext?.toString?.()?.includes?.('dmgCd'));
  716. for (let i = 0; i < colliders.length; i++) {
  717. const enemies = colliders[i].object2;
  718. let _start = enemies.classType.prototype.start;
  719. enemies.classType.prototype.start = function () { _start.apply(this, arguments); this.hp = 1; };
  720. enemies.children.entries.forEach(e => e.hp = 1);
  721. }
  722. }
  723. },
  724. {
  725. name: "Invincibility",
  726. description: "Makes you invincible",
  727. run: function () {
  728. for (const collider of getStateNode().game.current.config.sceneConfig.physics.world.colliders._active.filter(x => x.callbackContext?.toString().includes('invulnerableTime') || x.callbackContext?.toString().includes('dmgCd'))) collider.collideCallback = () => { };
  729. }
  730. },
  731. {
  732. name: "Kill Enemies",
  733. description: "Kills all current enemies",
  734. run: function () {
  735. getStateNode().game.current.config.sceneConfig.physics.world.bodies.entries.forEach(x => x?.gameObject?.receiveDamage?.(x.gameObject.hp, 1));
  736. }
  737. },
  738. {
  739. name: "Magnet",
  740. description: "Pulls all xp towards you",
  741. run: function () {
  742. getStateNode().game.current.config.sceneConfig.physics.world.colliders._active.find(x => x.collideCallback?.toString().includes('magnetTime')).collideCallback({ active: true }, { active: true, setActive() { }, setVisible() { } });
  743. }
  744. },
  745. {
  746. name: "Max Current Abilities",
  747. description: "Maxes out all your current abilities",
  748. run: function () {
  749. const stateNode = getStateNode();
  750. for (const [ability, level] of Object.entries(stateNode.state.abilities)) for (let i = 0; i < (10 - level); i++) stateNode.game.current.config.sceneConfig.game.events.emit("level up", ability, stateNode.state.abilities[ability]++);
  751. stateNode.setState({
  752. level: stateNode.game.current.config.sceneConfig.level = [1, 3, 5, 10, 15, 25, 35].sort((a, b) => Math.abs(a - stateNode.state.level) - Math.abs(b - stateNode.state.level))[0] - 1
  753. });
  754. }
  755. },
  756. {
  757. name: "Next Level",
  758. description: "Skips to the next level",
  759. run: function () {
  760. let stateNode = getStateNode();
  761. let { object1: player, object2: xp } = stateNode.game.current.config.sceneConfig.physics.world.colliders._active.find(x => x.collideCallback?.toString().includes('emit("xp'));
  762. xp.get().spawn(player.x, player.y, ((e) => 1 === e ? 1 : e < 5 ? 5 : e < 10 ? 10 : e < 20 ? 20 : e < 30 ? 30 : e < 40 ? 40 : e < 50 ? 50 : 100)(stateNode.state.level) - stateNode.xp);
  763. }
  764. },
  765. {
  766. name: "Remove Obstacles",
  767. description: "Removes all rocks and obstacles",
  768. run: function () {
  769. getStateNode().game.current.config.sceneConfig.physics.world.bodies.entries.forEach(body => { try { if (body.gameObject.frame.texture.key.includes("obstacle")) body.gameObject.destroy(); } catch { } });
  770. }
  771. },
  772. {
  773. name: "Reset Health",
  774. description: "Resets health and gives invincibility for 3 seconds",
  775. run: function () {
  776. getStateNode().game.current.events._events.respawn.fn();
  777. }
  778. }
  779. ],
  780. },
  781. cafe: {
  782. name: "Caf\xe9",
  783. img: "https://media.blooket.com/image/upload/v1655161189/Media/survivor/Pizza_lvl1.svg",
  784. style: { transform: "rotate(22.5deg)" },
  785. cheats: [
  786. {
  787. name: "Max Items",
  788. description: "Maxes out items in the shop (Only usable in the shop)",
  789. run: function () {
  790. if (window.location.pathname !== "/cafe/shop") alert("This can only be run in the shop");
  791. else {
  792. const stateNode = getStateNode();
  793. stateNode.setState({ items: Object.keys(stateNode.state.items).reduce((obj, item) => (obj[item] = 5, obj), {}) });
  794. }
  795. }
  796. },
  797. {
  798. name: "Remove Customers",
  799. description: "Skips the current customers (Not usable in the shop)",
  800. run: function () {
  801. const stateNode = getStateNode();
  802. stateNode.state.customers.forEach((customer, i) => window.setTimeout(() => customer.blook && stateNode.removeCustomer(i, true), i * 250));
  803. }
  804. },
  805. {
  806. name: "Reset Abilities",
  807. description: "Resets used abilities in shop (Only usable in the shop)",
  808. run: function () {
  809. if (window.location.pathname !== "/cafe/shop") alert("This can only be run in the shop");
  810. else {
  811. const stateNode = getStateNode();
  812. stateNode.setState({ abilities: Object.keys(stateNode.state.abilities).reduce((obj, item) => (obj[item] = 5, obj), {}) });
  813. }
  814. }
  815. },
  816. {
  817. name: "Set Cash",
  818. description: "Sets cafe cash",
  819. inputs: [{
  820. name: "Amount",
  821. type: "number"
  822. }],
  823. run: function (cafeCash) {
  824. let stateNode = getStateNode();
  825. stateNode.setState({ cafeCash });
  826. stateNode.props.liveGameController.setVal({
  827. path: `c/${stateNode.props.client.name}/ca`,
  828. val: cafeCash
  829. });
  830. }
  831. },
  832. {
  833. name: "Stock Food",
  834. description: "Stocks all food to 99 (Not usable in the shop)",
  835. run: function () {
  836. if (window.location.pathname !== "/cafe") alert("This can't be run in the shop");
  837. else {
  838. const stateNode = getStateNode();
  839. stateNode.setState({ foods: stateNode.state.foods.map(e => ({ ...e, stock: 99, level: 5 })) });
  840. }
  841. }
  842. }
  843. ],
  844. },
  845. crypto: {
  846. name: "Crypto Hack",
  847. img: "https://media.blooket.com/image/upload/v1661496293/Media/uiTest/CryptoIcon.svg",
  848. cheats: [
  849. {
  850. name: "Choice ESP",
  851. description: "Shows what each choice will give you",
  852. type: "toggle",
  853. enabled: false,
  854. data: null,
  855. run: function () {
  856. if (!this.enabled) {
  857. this.enabled = true;
  858. this.data = setInterval(() => {
  859. let chest = document.querySelector('[class*=feedbackContainer]');
  860. if (chest.children.length <= 4) {
  861. let choice = document.createElement('div')
  862. choice.style.color = "white";
  863. choice.style.fontFamily = "Inconsolata,Helvetica,monospace,sans-serif";
  864. choice.style.fontSize = "2em";
  865. choice.style.display = "flex";
  866. choice.style.justifyContent = "center";
  867. choice.style.marginTop = "675px";
  868. choice.innerText = getStateNode().state.choices[0].text;
  869. chest.append(choice);
  870. }
  871. }, 50);
  872. } else {
  873. this.enabled = false;
  874. clearInterval(this.data);
  875. this.data = null;
  876. }
  877. }
  878. },
  879. {
  880. name: "Password ESP",
  881. description: "Highlights the correct password",
  882. type: "toggle",
  883. enabled: false,
  884. data: null,
  885. run: function () {
  886. if (!this.enabled) {
  887. this.enabled = true;
  888. this.data = setInterval(() => {
  889. let { state } = getStateNode();
  890. if (state.stage == "hack") for (const button of document.querySelector('div[class*=buttonContainer]').children) {
  891. if (button.innerText == state.correctPassword) continue;
  892. button.style.outlineColor = "rgba(255, 64, 64, 0.8)";
  893. button.style.backgroundColor = "rgba(255, 64, 64, 0.8)";
  894. button.style.textShadow = "0 0 1px #f33"
  895. };
  896. }, 50);
  897. } else {
  898. this.enabled = false;
  899. clearInterval(this.data);
  900. this.data = null;
  901. }
  902. }
  903. },
  904. {
  905. name: "Always Triple",
  906. description: "Always get triple crypto",
  907. type: "toggle",
  908. enabled: false,
  909. data: null,
  910. run: function () {
  911. if (!this.enabled) {
  912. this.enabled = true;
  913. this.data = setInterval(state => getStateNode().setState(state), 25, { choices: [{ type: "mult", val: 3, rate: 0.075, blook: "Brainy Bot", text: "Triple Crypto" }] });
  914. } else {
  915. this.enabled = false;
  916. clearInterval(this.data);
  917. this.data = null;
  918. }
  919. }
  920. },
  921. {
  922. name: "Auto Guess",
  923. description: "Automatically guess the correct password",
  924. type: "toggle",
  925. enabled: false,
  926. data: null,
  927. run: function () {
  928. if (!this.enabled) {
  929. this.enabled = true;
  930. this.data = setInterval(() => {
  931. let { state } = getStateNode();
  932. if (state.stage == "hack") for (const button of document.querySelector('div[class*=buttonContainer]').children) button.innerText == state.correctPassword && button.click();
  933. }, 50);
  934. } else {
  935. this.enabled = false;
  936. clearInterval(this.data);
  937. this.data = null;
  938. }
  939. }
  940. },
  941. {
  942. name: "Remove Hack",
  943. description: "Removes an attacking hack",
  944. run: function () {
  945. getStateNode().setState({ hack: "" });
  946. }
  947. },
  948. {
  949. name: "Set Crypto",
  950. description: "Sets crypto",
  951. inputs: [{
  952. name: "Amount",
  953. type: "number"
  954. }],
  955. run: function (amount) {
  956. let stateNode = getStateNode();
  957. stateNode.setState({ crypto: amount, crypto2: amount });
  958. stateNode.props.liveGameController.setVal({
  959. path: `c/${stateNode.props.client.name}/cr`,
  960. val: amount
  961. });
  962. }
  963. },
  964. {
  965. name: "Set Password",
  966. description: "Sets hacking password",
  967. inputs: [{
  968. name: "Custom Password",
  969. type: "string"
  970. }],
  971. run: function (password) {
  972. let stateNode = getStateNode();
  973. stateNode.setState({ password });
  974. stateNode.props.liveGameController.setVal({
  975. path: `c/${stateNode.props.client.name}/p`,
  976. val: password
  977. });
  978. }
  979. },
  980. {
  981. name: "Steal Player's Crypto",
  982. description: "Steals all of someone's crypto",
  983. inputs: [{
  984. name: "Player",
  985. type: "options",
  986. options: () => {
  987. let stateNode = getStateNode();
  988. return stateNode.props.liveGameController._liveApp ? new Promise(res => stateNode.props.liveGameController.getDatabaseVal("c", (players) => players && res(Object.keys(players)))) : [];
  989. }
  990. }],
  991. run: function (target) {
  992. let stateNode = getStateNode();
  993. stateNode.props.liveGameController.getDatabaseVal("c", (players) => {
  994. let player;
  995. if (players && (player = Object.entries(players).find((x) => x[0].toLowerCase() == target.toLowerCase()))) {
  996. const cr = player[1].cr;
  997. stateNode.setState({
  998. crypto: stateNode.state.crypto + cr,
  999. crypto2: stateNode.state.crypto + cr
  1000. });
  1001. stateNode.props.liveGameController.setVal({
  1002. path: "c/" + stateNode.props.client.name,
  1003. val: {
  1004. b: stateNode.props.client.blook,
  1005. p: stateNode.state.password,
  1006. cr: stateNode.state.crypto + cr,
  1007. tat: player[0] + ":" + cr
  1008. }
  1009. });
  1010. }
  1011. })
  1012. }
  1013. }
  1014. ],
  1015. },
  1016. defense: {
  1017. name: "Tower Defense",
  1018. img: "https://media.blooket.com/image/upload/v1657235025/Media/survivor/Laser_Lvl1.svg",
  1019. cheats: [
  1020. {
  1021. name: "Earthquake",
  1022. description: "Shuffles around towers",
  1023. run: function () {
  1024. let stateNode = getStateNode();
  1025. stateNode.setState({
  1026. eventName: "Earthquake",
  1027. event: {
  1028. short: "e",
  1029. color: "#805500",
  1030. icon: "fas fa-mountain",
  1031. desc: "All of your towers get mixed up",
  1032. rate: .02
  1033. },
  1034. buyTowerName: "",
  1035. buyTower: {}
  1036. }, () => stateNode.eventTimeout = setTimeout(() => stateNode.setState({ event: {}, eventName: "" }), 6e3));
  1037. stateNode.tiles.forEach(row => row.forEach((col, i) => col == 3 && (row[i] = 0)));
  1038. let tiles = [];
  1039. for (let y = 0; y < stateNode.tiles.length; y++)
  1040. for (let x = 0; x < stateNode.tiles[y].length; x++)
  1041. if (stateNode.tiles[y][x] == 0) tiles.push({ x, y });
  1042. tiles.sort(() => Math.random() - Math.random());
  1043. stateNode.towers.forEach(tower => {
  1044. let { x, y } = tiles.pop();
  1045. tower.move(x, y, stateNode.tileSize);
  1046. stateNode.tiles[y][x] = 3;
  1047. });
  1048. }
  1049. },
  1050. {
  1051. name: "Max Tower Stats",
  1052. description: "Makes all placed towers overpowered",
  1053. run: function () {
  1054. getStateNode().towers.forEach(tower => {
  1055. tower.range = 100;
  1056. tower.fullCd = tower.cd = 0;
  1057. tower.damage = 1e6;
  1058. });
  1059. }
  1060. },
  1061. {
  1062. name: "Remove Ducks",
  1063. description: "Removes ducks",
  1064. run: function () {
  1065. let { ducks, tiles } = getStateNode();
  1066. ducks.forEach(x => (tiles[x.y][x.x] = 0));
  1067. ducks.length = 0;
  1068. }
  1069. },
  1070. {
  1071. name: "Remove Enemies",
  1072. description: "Removes all the enemies",
  1073. run: function () {
  1074. let stateNode = getStateNode();
  1075. stateNode.enemies = stateNode.futureEnemies = [];
  1076. }
  1077. },
  1078. {
  1079. name: "Remove Obstacles",
  1080. description: "Lets you place towers anywhere",
  1081. run: function () {
  1082. let stateNode = getStateNode();
  1083. stateNode.tiles = stateNode.tiles.map(row => row.fill(0));
  1084. }
  1085. },
  1086. {
  1087. name: "Set Damage",
  1088. description: "Sets damage",
  1089. inputs: [{
  1090. name: "Damage",
  1091. type: "number"
  1092. }],
  1093. run: function (dmg) {
  1094. getStateNode().dmg = dmg;
  1095. }
  1096. },
  1097. {
  1098. name: "Set Round",
  1099. description: "Sets the current round",
  1100. inputs: [{
  1101. name: "Round",
  1102. type: "number"
  1103. }],
  1104. run: function (round) {
  1105. getStateNode().setState({ round });
  1106. }
  1107. },
  1108. {
  1109. name: "Set Tokens",
  1110. description: "Sets the amount of tokens you have",
  1111. inputs: [{
  1112. name: "Tokens",
  1113. type: "number"
  1114. }],
  1115. run: function (tokens) {
  1116. getStateNode().setState({ tokens });
  1117. }
  1118. }
  1119. ],
  1120. },
  1121. defense2: {
  1122. name: "Tower Defense 2",
  1123. img: "https://media.blooket.com/image/upload/v1593095354/Media/defense/missile.svg",
  1124. style: { transform: "rotate(45deg)" },
  1125. cheats: [
  1126. {
  1127. name: "Max Tower Stats",
  1128. description: "Makes all placed towers overpowered",
  1129. run: function () {
  1130. getStateNode().state.towers.forEach(tower => {
  1131. tower.stats.dmg = 1e6;
  1132. tower.stats.fireRate = 50;
  1133. tower.stats.ghostDetect = true;
  1134. tower.stats.maxTargets = 1e6;
  1135. tower.stats.numProjectiles &&= 100;
  1136. tower.stats.range = 100;
  1137. if (tower.stats.auraBuffs) for (const buff in tower.stats.auraBuffs) tower.stats.auraBuffs[buff] *= 100;
  1138. });
  1139. }
  1140. },
  1141. {
  1142. name: "Kill Enemies",
  1143. description: "Kills all the enemies",
  1144. run: function () {
  1145. let stateNode = getStateNode();
  1146. stateNode.game.current.config.sceneConfig.enemyQueue.length = 0;
  1147. stateNode.game.current.config.sceneConfig.physics.world.bodies.entries.forEach(x => x?.gameObject?.receiveDamage?.(x.gameObject.hp, 1));
  1148. }
  1149. },
  1150. {
  1151. name: "Set Coins",
  1152. description: "Sets coins",
  1153. inputs: [{
  1154. name: "Coins",
  1155. type: "number"
  1156. }],
  1157. run: function (coins) {
  1158. getStateNode().setState({ coins });
  1159. }
  1160. },
  1161. {
  1162. name: "Set Health",
  1163. description: "Sets the amount of health you have",
  1164. inputs: [{
  1165. name: "Health",
  1166. type: "number"
  1167. }],
  1168. run: function (health) {
  1169. getStateNode().setState({ health });
  1170. }
  1171. },
  1172. {
  1173. name: "Set Round",
  1174. description: "Sets the current round",
  1175. inputs: [{
  1176. name: "Round",
  1177. type: "number"
  1178. }],
  1179. run: function (round) {
  1180. getStateNode().setState({ round });
  1181. }
  1182. },
  1183. ],
  1184. },
  1185. dinos: {
  1186. name: "Deceptive Dinos",
  1187. img: "https://media.blooket.com/image/upload/v1655161325/Media/survivor/Dog.svg",
  1188. style: { transform: "rotate(-22.5deg)" },
  1189. cheats: [
  1190. {
  1191. name: "Auto Choose",
  1192. description: "Automatically choose the best fossil when excavating",
  1193. type: "toggle",
  1194. enabled: false,
  1195. data: null,
  1196. rand(e, t) {
  1197. const s = [];
  1198. while (s.length < t) {
  1199. const i = Math.random();
  1200. let r = 0, g = null;
  1201. for (let o = 0; o < e.length; o++) {
  1202. r += e[o].rate;
  1203. if (r >= i) {
  1204. g = e[o];
  1205. break;
  1206. }
  1207. }
  1208. g && !s.includes(g) && s.push(g)
  1209. }
  1210. return s;
  1211. },
  1212. run: function () {
  1213. if (!this.enabled) {
  1214. this.enabled = true;
  1215. this.data = setInterval(() => {
  1216. try {
  1217. let stateNode = getStateNode();
  1218. if (stateNode.state.stage === "excavate") {
  1219. stateNode.state.choices.length || (stateNode.state.choices = this.rand([{ type: "fossil", val: 10, rate: .1, blook: "Amber" }, { type: "fossil", val: 25, rate: .1, blook: "Dino Egg" }, { type: "fossil", val: 50, rate: .175, blook: "Dino Fossil" }, { type: "fossil", val: 75, rate: .175, blook: "Stegosaurus" }, { type: "fossil", val: 100, rate: .15, blook: "Velociraptor" }, { type: "fossil", val: 125, rate: .125, blook: "Brontosaurus" }, { type: "fossil", val: 250, rate: .075, blook: "Triceratops" }, { type: "fossil", val: 500, rate: .025, blook: "Tyrannosaurus Rex" }, { type: "mult", val: 1.5, rate: .05 }, { type: "mult", val: 2, rate: .025 }], 3));
  1220. let max = 0, index = -1;
  1221. for (let i = 0; i < stateNode.state.choices.length; i++) {
  1222. const { type, val } = stateNode.state.choices[i];
  1223. const value = (type == "fossil" ? stateNode.state.fossils + val * stateNode.state.fossilMult : stateNode.state.fossils * val) || 0;
  1224. if (value <= max && type != "mult") continue;
  1225. max = value, index = i + 1;
  1226. }
  1227. document.querySelector('div[class*=rockRow] > div[role="button"]:nth-child(' + index + ')').click();
  1228. }
  1229. } catch { }
  1230. }, 50);
  1231. } else {
  1232. this.enabled = false;
  1233. clearInterval(this.data);
  1234. this.data = null;
  1235. }
  1236. }
  1237. },
  1238. {
  1239. name: "Rock ESP",
  1240. description: "Shows what is under the rocks",
  1241. type: "toggle",
  1242. enabled: false,
  1243. data: null,
  1244. run: (() => {
  1245. function rand(e, t) {
  1246. const s = [];
  1247. while (s.length < t) {
  1248. const i = Math.random();
  1249. let r = 0;
  1250. let g;
  1251. for (let o = 0; o < e.length; o++) {
  1252. r += e[o].rate;
  1253. if (r >= i) {
  1254. g = e[o];
  1255. break;
  1256. }
  1257. }
  1258. if (g && !s.includes(g)) s.push(g);
  1259. }
  1260. return s;
  1261. };
  1262. const exps = ["⁰", "¹", "²", "³", "⁴", "⁵", "⁶", "⁷", "⁸", "⁹"];
  1263. const getExpAscii = (num) => {
  1264. let res = "";
  1265. while (num > 0) {
  1266. res = exps[num % 10] + res;;
  1267. num = ~~(num / 10);
  1268. }
  1269. return res;
  1270. };
  1271. function shortNum(value) {
  1272. let newValue = value.toString();
  1273. if (value >= 1000) {
  1274. const suffixes = ["", "K", "M", "B", "T"];
  1275. const suffixNum = Math.floor(Math.floor((Math.log(value) / Math.log(10)).toPrecision(14)) / 3);
  1276. if (suffixNum < suffixes.length) {
  1277. let shortValue = "";
  1278. for (let precision = 3; precision >= 1; precision--) {
  1279. shortValue = parseFloat((suffixNum != 0 ? value / Math.pow(1000, suffixNum) : value).toPrecision(precision)).toString();
  1280. const dotLessShortValue = shortValue.replace(/[^a-zA-Z 0-9]+/g, "");
  1281. if (dotLessShortValue.length <= 3) break;
  1282. }
  1283. if (Number(shortValue) % 1 != 0) shortValue = Number(shortValue).toFixed(1);
  1284. newValue = shortValue + suffixes[suffixNum];
  1285. } else {
  1286. let num = value;
  1287. let exp = 0;
  1288. while (num >= 100) {
  1289. num = Math.floor(num / 10);
  1290. exp += 1;
  1291. }
  1292. newValue = num / 10 + " × 10" + getExpAscii(exp + 1);
  1293. }
  1294. }
  1295. return newValue;
  1296. };
  1297. return function () {
  1298. if (!this.enabled) {
  1299. this.enabled = true;
  1300. this.data = setInterval(() => {
  1301. let stateNode = getStateNode();
  1302. const rocks = document.querySelector('[class*="rockButton"]').parentElement.children;
  1303. if (!Array.prototype.every.call(rocks, element => element.querySelector('div'))) stateNode.setState({
  1304. choices: rand([{ type: "fossil", val: 10, rate: 0.1, blook: "Amber" }, { type: "fossil", val: 25, rate: 0.1, blook: "Dino Egg" }, { type: "fossil", val: 50, rate: 0.175, blook: "Dino Fossil" }, { type: "fossil", val: 75, rate: 0.175, blook: "Stegosaurus" }, { type: "fossil", val: 100, rate: 0.15, blook: "Velociraptor" }, { type: "fossil", val: 125, rate: 0.125, blook: "Brontosaurus" }, { type: "fossil", val: 250, rate: 0.075, blook: "Triceratops" }, { type: "fossil", val: 500, rate: 0.025, blook: "Tyrannosaurus Rex" }, { type: "mult", val: 1.5, rate: 0.05 }, { type: "mult", val: 2, rate: 0.025 }], 3)
  1305. }, () => {
  1306. Array.prototype.forEach.call(rocks, (element, index) => {
  1307. const rock = stateNode.state.choices[index];
  1308. if (element.querySelector('div')) element.querySelector('div').remove();
  1309. const choice = document.createElement("div");
  1310. choice.style.color = "white";
  1311. choice.style.fontFamily = "Macondo";
  1312. choice.style.fontSize = "1em";
  1313. choice.style.display = "flex";
  1314. choice.style.justifyContent = "center";
  1315. choice.style.transform = "translateY(25px)";
  1316. choice.innerText = rock.type === "fossil" ? `+${Math.round(rock.val * stateNode.state.fossilMult) > 99999999 ? shortNum(Math.round(rock.val * stateNode.state.fossilMult)) : Math.round(rock.val * stateNode.state.fossilMult)} Fossils` : `x${rock.val} Fossils Per Excavation`;;
  1317. element.append(choice);
  1318. });
  1319. });
  1320. }, 50);
  1321. } else {
  1322. this.enabled = false;
  1323. clearInterval(this.data);
  1324. this.data = null;
  1325. }
  1326. }
  1327. })()
  1328. },
  1329. {
  1330. name: "Set Fossils",
  1331. description: "Sets the amount of fossils you have",
  1332. inputs: [{
  1333. name: "Fossils",
  1334. type: "number"
  1335. }],
  1336. run: function (fossils) {
  1337. let stateNode = getStateNode();
  1338. stateNode.setState({ fossils });
  1339. stateNode.props.liveGameController.setVal({
  1340. path: `c/${stateNode.props.client.name}/f`,
  1341. val: fossils
  1342. });
  1343. }
  1344. },
  1345. {
  1346. name: "Set Multiplier",
  1347. description: "Sets fossil multiplier",
  1348. inputs: [{
  1349. name: "Multiplier",
  1350. type: "number"
  1351. }],
  1352. run: function (fossilMult) {
  1353. let stateNode = getStateNode();
  1354. stateNode.setState({ fossilMult });
  1355. }
  1356. },
  1357. {
  1358. name: "Stop Cheating",
  1359. description: "Undoes cheating so that you can't be caught",
  1360. run: function () {
  1361. let stateNode = getStateNode();
  1362. stateNode.setState({ isCheating: false });
  1363. stateNode.props.liveGameController.setVal({
  1364. path: `c/${stateNode.props.client.name}/ic`,
  1365. val: false
  1366. });
  1367. }
  1368. }
  1369. ],
  1370. },
  1371. doom: {
  1372. name: "Tower of Doom",
  1373. img: "https://media.blooket.com/image/upload/v1657235023/Media/survivor/cards-05.svg",
  1374. cheats: [
  1375. {
  1376. name: "Fill Deck",
  1377. description: "Fills your deck with every maxed out card and artifact (Only works on towers page)",
  1378. run: function () {
  1379. if (window.location.pathname == "/tower/map") {
  1380. const stateNode = getStateNode();
  1381. stateNode.props.tower.artifacts = "Medical Kit|Fury Relic|Survival Guide|Steel Socks|Piggy Bank|Lucky Feather|Coupon|Cheese|Tasty Egg|Training Weights|Mighty Shield|Toxic Waste|Lifeline Totem|Cursed Hourglass|Band-Aid|Elder Coins|Captain's Anchor|Chess Pieces|Pink Hippo|Anorak's Wizard Cap|Dave's Doggo|Anubis' Obelisk|Farm Tractor|Magic Seedling|Just A Bone|Cozy Igloo|King's Crown|Sacred Scroll".split("|");
  1382. stateNode.props.tower.cards = 'Chick,🌽|Chicken,🌽|Cow,🌽|Goat,🌽|Horse,🌽|Pig,🌽|Sheep,🌽|Duck,🌽|Dog,🌽|Cat,🐾|Rabbit,🐾|Goldfish,🐾|Hamster,🐾|Turtle,🐾|Kitten,🐾|Puppy,🐾|Bear,🌲|Moose,🌲|Fox,🌲|Raccoon,🌲|Squirrel,🌲|Owl,🌲|Hedgehog,🌲|Baby Penguin,❄️|Penguin,❄️|Arctic Fox,❄️|Snowy Owl,❄️|Polar Bear,❄️|Arctic Hare,❄️|Seal,❄️|Walrus,❄️|Tiger,🌴|Panther,🌴|Cockatoo,🌴|Orangutan,🌴|Anaconda,🌴|Macaw,🌴|Jaguar,🌴|Capuchin,🌴|Toucan,🌴|Parrot,🌴|Elf,⚔️|Witch,⚔️|Wizard,⚔️|Fairy,⚔️|Slime Monster,⚔️|Jester,⚔️|Dragon,⚔️|Unicorn,⚔️|Queen,⚔️|King,⚔️|Snow Globe,☃️|Holiday Gift,☃️|Hot Chocolate,☃️|Gingerbread Man,☃️|Gingerbread House,☃️|Holiday Wreath,☃️|Snowman,☃️|Santa Claus,☃️|Two of Spades,🏰|Eat Me,🏰|Drink Me,🏰|Alice,🏰|Queen of Hearts,🏰|Dormouse,🏰|White Rabbit,🏰|Cheshire Cat,🏰|Caterpillar,🏰|Mad Hatter,🏰|King of Hearts,🏰'.split("|").map(x => {
  1383. const [blook, c] = x.split(",");
  1384. return { strength: 20, charisma: 20, wisdom: 20, class: c, blook };
  1385. });
  1386. try { stateNode.props.addTowerNode(); } catch { }
  1387. stateNode.setState({ showDeck: false });
  1388. } else alert("You need to be on the map to run this cheat!");
  1389. }
  1390. },
  1391. {
  1392. name: "Max Cards",
  1393. description: "Maxes out all the cards in your deck",
  1394. run: function () {
  1395. if (window.location.pathname == "/tower/map") {
  1396. const stateNode = getStateNode();
  1397. stateNode.props.tower.cards.forEach(card => {
  1398. card.strength = 20;
  1399. card.charisma = 20;
  1400. card.wisdom = 20;
  1401. });
  1402. try { stateNode.forceUpdate(); } catch { }
  1403. } else alert("You need to be on the map to run this cheat!");
  1404. }
  1405. },
  1406. {
  1407. name: "Max Health",
  1408. description: "Fills the player's health",
  1409. run: function () {
  1410. if (window.location.pathname == "/tower/battle") getStateNode().setState({ myHealth: 100, myLife: 100 });
  1411. else alert("You need to be in battle to run this cheat!");
  1412. }
  1413. },
  1414. {
  1415. name: "Max Card Stats",
  1416. description: "Maxes out player's current card (Only works on attribute select page)",
  1417. run: function () {
  1418. const stateNode = getStateNode();
  1419. if (stateNode.state.phase !== 'select') alert('You must be on the attribute selection page!');
  1420. else stateNode.setState({ myCard: { ...stateNode.state.myCard, strength: 20, charisma: 20, wisdom: 20 } });
  1421. }
  1422. },
  1423. {
  1424. name: "Min Enemy Stats",
  1425. description: "Makes the enemy card stats all 0 (Only works on attribute select page)",
  1426. run: function () {
  1427. const stateNode = getStateNode();
  1428. if (stateNode.state.phase !== 'select') alert('You must be on the attribute selection page!');
  1429. else stateNode.setState({ enemyCard: { ...stateNode.state.enemyCard, strength: 0, charisma: 0, wisdom: 0 } });
  1430. }
  1431. },
  1432. {
  1433. name: "Set Coins",
  1434. description: "Try's to set amount of tower coins you have",
  1435. inputs: [{
  1436. name: "Coins",
  1437. type: "number"
  1438. }],
  1439. run: function (coins) {
  1440. if (window.location.pathname == "/tower/battle") try {
  1441. getStateNode().props.setTowerCoins(coins);
  1442. } catch { }
  1443. else alert("You need to be in battle to run this cheat!");
  1444. }
  1445. }
  1446. ],
  1447. },
  1448. factory: {
  1449. name: "Factory",
  1450. img: "https://media.blooket.com/image/upload/v1661496293/Media/uiTest/Factory_Upgrades.svg",
  1451. cheats: [
  1452. {
  1453. name: "Choose Blook",
  1454. description: "Gives you a blook",
  1455. inputs: [{
  1456. name: "Blook",
  1457. type: "options",
  1458. options: [{ name: "Chick", color: "#ffcd05", class: "\uD83C\uDF3D", rarity: "Common", cash: [3, 7, 65, 400, 2500], time: [1, 1, 1, 1, 1], price: [300, 3e3, 3e4, 2e5] }, { name: "Chicken", color: "#ed1c24", class: "\uD83C\uDF3D", rarity: "Common", cash: [10, 40, 200, 1400, 1e4], time: [5, 4, 3, 2, 1], price: [570, 4e3, 5e4, 8e5] }, { name: "Cow", color: "#58595b", class: "\uD83C\uDF3D", rarity: "Common", cash: [25, 75, 1500, 25e3, 25e4], time: [15, 10, 10, 10, 5], price: [500, 9500, 16e4, 4e6] }, { name: "Duck", color: "#4ab96d", class: "\uD83C\uDF3D", rarity: "Common", cash: [4, 24, 200, 3e3, 4e4], time: [3, 3, 3, 3, 3], price: [450, 4200, 7e4, 11e5] }, { name: "Goat", color: "#c59a74", class: "\uD83C\uDF3D", rarity: "Common", cash: [5, 28, 200, 1300, 12e3], time: [3, 3, 2, 2, 2], price: [500, 6400, 45e3, 5e5] }, { name: "Horse", color: "#995b3c", class: "\uD83C\uDF3D", rarity: "Common", cash: [5, 20, 270, 1800, 15e3], time: [2, 2, 2, 2, 2], price: [550, 8200, 65e3, 6e5] }, { name: "Pig", color: "#f6a9cb", class: "\uD83C\uDF3D", rarity: "Common", cash: [20, 50, 1300, 8e3, 8e4], time: [7, 7, 7, 7, 5], price: [400, 11e3, 8e4, 13e5] }, { name: "Sheep", color: "#414042", class: "\uD83C\uDF3D", rarity: "Common", cash: [6, 25, 250, 1500, 11e3], time: [3, 3, 3, 2, 2], price: [500, 5e3, 5e4, 43e4] }, { name: "Cat", color: "#f49849", class: "\uD83D\uDC3E", rarity: "Common", cash: [5, 18, 170, 1700, 13e3], time: [2, 2, 2, 2, 2], price: [480, 5500, 6e4, 5e5] }, { name: "Dog", color: "#995b3c", class: "\uD83D\uDC3E", rarity: "Common", cash: [7, 25, 220, 1900, 9e3], time: [3, 3, 2, 2, 1], price: [460, 6600, 7e4, 73e4] }, { name: "Goldfish", color: "#f18221", class: "\uD83D\uDC3E", rarity: "Common", cash: [5, 40, 350, 3500, 35e3], time: [3, 3, 3, 3, 3], price: [750, 7200, 84e3, 95e4] }, { name: "Rabbit", color: "#e7bf9a", class: "\uD83D\uDC3E", rarity: "Common", cash: [3, 18, 185, 800, 7e3], time: [2, 2, 2, 1, 1], price: [500, 5800, 56e3, 55e4] }, { name: "Hamster", color: "#ce9176", class: "\uD83D\uDC3E", rarity: "Common", cash: [10, 45, 450, 4500, 45e3], time: [4, 4, 4, 4, 4], price: [650, 6500, 8e4, 93e4] }, { name: "Turtle", color: "#619a3c", class: "\uD83D\uDC3E", rarity: "Common", cash: [23, 120, 1400, 15e3, 17e4], time: [10, 10, 10, 10, 10], price: [700, 8500, 11e4, 13e5] }, { name: "Puppy", color: "#414042", class: "\uD83D\uDC3E", rarity: "Common", cash: [4, 10, 75, 500, 3e3], time: [1, 1, 1, 1, 1], price: [450, 4e3, 35e3, 25e4] }, { name: "Kitten", color: "#58595b", class: "\uD83D\uDC3E", rarity: "Common", cash: [4, 8, 60, 400, 2e3], time: [1, 1, 1, 1, 1], price: [350, 3500, 26e3, 17e4] }, { name: "Bear", color: "#995b3c", class: "\uD83C\uDF32", rarity: "Common", cash: [12, 70, 550, 4500, 1e5], time: [7, 7, 6, 5, 5], price: [550, 5500, 63e3, 16e5] }, { name: "Moose", color: "#995b3c", class: "\uD83C\uDF32", rarity: "Common", cash: [8, 45, 400, 3500, 26e3], time: [5, 5, 4, 4, 3], price: [520, 6500, 58e3, 7e5] }, { name: "Fox", color: "#f49849", class: "\uD83C\uDF32", rarity: "Common", cash: [7, 15, 80, 550, 3e3], time: [2, 2, 1, 1, 1], price: [400, 4e3, 36e3, 24e4] }, { name: "Raccoon", color: "#6d6e71", class: "\uD83C\uDF32", rarity: "Common", cash: [5, 14, 185, 1900, 19e3], time: [2, 2, 2, 2, 2], price: [400, 5e3, 71e3, 8e5] }, { name: "Squirrel", color: "#d25927", class: "\uD83C\uDF32", rarity: "Common", cash: [3, 10, 65, 470, 2600], time: [1, 1, 1, 1, 1], price: [420, 3600, 32e3, 21e4] }, { name: "Owl", color: "#594a42", class: "\uD83C\uDF32", rarity: "Common", cash: [4, 17, 155, 1500, 15e3], time: [2, 2, 2, 2, 2], price: [500, 4800, 55e3, 58e4] }, { name: "Hedgehog", color: "#3f312b", class: "\uD83C\uDF32", rarity: "Common", cash: [11, 37, 340, 2200, 3e4], time: [5, 4, 3, 2, 2], price: [540, 7e3, 77e3, 12e5] }, { name: "Seal", color: "#7ca1d5", class: "❄️", rarity: "Common", cash: [6, 17, 150, 1200, 13e3], time: [2, 2, 2, 2, 2], price: [480, 4500, 43e3, 52e4] }, { name: "Arctic Fox", color: "#7ca1d5", class: "❄️", rarity: "Common", cash: [5, 18, 180, 850, 8500], time: [2, 2, 2, 1, 1], price: [520, 550, 61e3, 68e4] }, { name: "Snowy Owl", color: "#feda3f", class: "❄️", rarity: "Common", cash: [5, 20, 190, 1900, 16e3], time: [3, 3, 2, 2, 2], price: [370, 5300, 76e3, 62e4] }, { name: "Arctic Hare", color: "#7ca1d5", class: "❄️", rarity: "Common", cash: [6, 19, 85, 900, 7e3], time: [2, 2, 1, 1, 1], price: [540, 5200, 66e3, 55e4] }, { name: "Penguin", color: "#fb8640", class: "❄️", rarity: "Common", cash: [4, 21, 310, 3200, 33e3], time: [3, 3, 3, 3, 3], price: [400, 6500, 76e3, 87e4] }, { name: "Baby Penguin", color: "#414042", class: "❄️", rarity: "Common", cash: [3, 8, 70, 450, 2700], time: [1, 1, 1, 1, 1], price: [420, 3300, 33e3, 23e4] }, { name: "Polar Bear", color: "#7ca1d5", class: "❄️", rarity: "Common", cash: [12, 75, 700, 6500, 85e3], time: [8, 7, 6, 5, 5], price: [630, 7e3, 91e3, 14e5] }, { name: "Walrus", color: "#7d4f33", class: "❄️", rarity: "Common", cash: [11, 46, 420, 3700, 51e3], time: [5, 5, 4, 4, 4], price: [550, 6200, 68e3, 1e6] }, { name: "Tiger", color: "#f18221", class: "\uD83C\uDF34", rarity: "Common", cash: [6, 20, 100, 975, 7500], time: [3, 3, 1, 1, 1], price: [390, 6e3, 7e4, 61e4] }, { name: "Jaguar", color: "#fbb040", class: "\uD83C\uDF34", rarity: "Common", cash: [8, 28, 230, 1600, 17e3], time: [3, 3, 2, 2, 2], price: [390, 6e3, 7e4, 61e4] }, { name: "Toucan", color: "#ffca34", class: "\uD83C\uDF34", rarity: "Common", cash: [9, 20, 175, 625, 3800], time: [2, 2, 2, 1, 1], price: [520, 4800, 42e3, 3e5] }, { name: "Cockatoo", color: "#7ca1d5", class: "\uD83C\uDF34", rarity: "Common", cash: [6, 35, 160, 1700, 18e3], time: [4, 4, 2, 2, 2], price: [500, 5e3, 63e3, 7e5] }, { name: "Macaw", color: "#00aeef", class: "\uD83C\uDF34", rarity: "Common", cash: [3, 8, 85, 850, 8500], time: [1, 1, 1, 1, 1], price: [480, 5400, 62e3, 63e4] }, { name: "Parrot", color: "#ed1c24", class: "\uD83C\uDF34", rarity: "Common", cash: [3, 9, 90, 900, 9e3], time: [1, 1, 1, 1, 1], price: [540, 5700, 65e3, 69e4] }, { name: "Panther", color: "#2f2c38", class: "\uD83C\uDF34", rarity: "Common", cash: [12, 28, 215, 2100, 21e3], time: [5, 3, 2, 2, 2], price: [530, 6500, 76e3, 87e4] }, { name: "Anaconda", color: "#8a9143", class: "\uD83C\uDF34", rarity: "Common", cash: [3, 15, 85, 1500, 7600], time: [1, 2, 1, 2, 1], price: [410, 5100, 58e3, 59e4] }, { name: "Orangutan", color: "#bc6234", class: "\uD83C\uDF34", rarity: "Common", cash: [13, 52, 570, 4300, 7e4], time: [5, 5, 5, 4, 4], price: [600, 7e3, 8e4, 14e5] }, { name: "Capuchin", color: "#e0b0a6", class: "\uD83C\uDF34", rarity: "Common", cash: [4, 14, 160, 780, 8200], time: [2, 2, 2, 1, 1], price: [390, 4700, 57e3, 68e4] }, { name: "Elf", color: "#a7d054", class: "⚔️", rarity: "Uncommon", cash: [5e3, 15e3, 15e4, 15e5, 1e7], time: [1, 1, 1, 1, 1], price: [8e5, 9e6, 11e7, 8e8] }, { name: "Witch", color: "#4ab96d", class: "⚔️", rarity: "Uncommon", cash: [18e3, 6e4, 4e4, 4e6, 35e6], time: [3, 3, 2, 2, 2], price: [11e5, 12e6, 15e7, 14e8] }, { name: "Wizard", color: "#5a459c", class: "⚔️", rarity: "Uncommon", cash: [19500, 65e3, 44e4, 46e5, 4e6], time: [3, 3, 2, 2, 2], price: [13e5, 135e5, 16e7, 16e8] }, { name: "Fairy", color: "#df6d9c", class: "⚔️", rarity: "Uncommon", cash: [18500, 6e4, 62e4, 44e5, 38e6], time: [3, 3, 3, 2, 2], price: [12e5, 125e5, 15e6, 15e8] }, { name: "Slime Monster", color: "#2fa04a", class: "⚔️", rarity: "Uncommon", cash: [35e3, 14e4, 1e6, 11e6, 11e7], time: [5, 5, 4, 4, 4], price: [16e5, 15e6, 2e8, 23e8] }, { name: "Jester", color: "#be1e2d", class: "⚔️", rarity: "Rare", cash: [25e3, 1e5, 68e4, 65e5, 32e6], time: [3, 3, 2, 2, 1], price: [2e6, 21e6, 23e7, 26e8] }, { name: "Dragon", color: "#2fa04a", class: "⚔️", rarity: "Rare", cash: [36e3, 15e4, 15e5, 15e6, 15e7], time: [4, 4, 4, 4, 4], price: [23e5, 24e6, 27e7, 3e9] }, { name: "Unicorn", color: "#f6afce", class: "⚔️", rarity: "Epic", cash: [24e3, 15e4, 14e5, 7e6, 75e6], time: [2, 2, 2, 1, 1], price: [45e5, 45e6, 55e7, 65e8] }, { name: "Queen", color: "#9e1f63", class: "⚔️", rarity: "Rare", cash: [24e3, 95e3, 95e4, 97e5, 95e6], time: [3, 3, 3, 3, 3], price: [19e5, 2e7, 23e7, 25e8] }, { name: "King", color: "#ee2640", class: "⚔️", rarity: "Legendary", cash: [75e3, 4e5, 6e6, 9e7, 125e7], time: [5, 5, 5, 5, 5], price: [6e6, 95e6, 16e8, 25e9] }, { name: "Two of Spades", color: "#414042", class: "\uD83C\uDFF0", rarity: "Uncommon", cash: [4500, 14e3, 14e4, 14e5, 9e6], time: [1, 1, 1, 1, 1], price: [77e4, 83e5, 98e6, 71e7] }, { name: "Eat Me", color: "#d58c55", class: "\uD83C\uDFF0", rarity: "Uncommon", cash: [13e3, 45e3, 45e4, 45e5, 5e7], time: [2, 2, 2, 2, 2], price: [13e5, 14e6, 16e7, 2e9] }, { name: "Drink Me", color: "#dd7399", class: "\uD83C\uDFF0", rarity: "Uncommon", cash: [12e3, 4e4, 4e5, 4e6, 45e6], time: [2, 2, 2, 2, 2], price: [12e5, 12e6, 14e7, 18e8] }, { name: "Alice", color: "#4cc9f5", class: "\uD83C\uDFF0", rarity: "Uncommon", cash: [13e3, 42e3, 21e4, 21e5, 23e6], time: [2, 2, 1, 1, 1], price: [12e5, 13e6, 15e7, 19e8] }, { name: "Queen of Hearts", color: "#d62027", class: "\uD83C\uDFF0", rarity: "Uncommon", cash: [23e3, 87e3, 62e4, 75e5, 9e7], time: [4, 4, 3, 3, 3], price: [13e5, 13e6, 18e7, 24e8] }, { name: "Dormouse", color: "#89d6f8", class: "\uD83C\uDFF0", rarity: "Rare", cash: [17e3, 68e3, 7e5, 35e5, 35e6], time: [2, 2, 1, 1, 1], price: [2e6, 22e6, 25e7, 28e8] }, { name: "White Rabbit", color: "#ffcd05", class: "\uD83C\uDFF0", rarity: "Rare", cash: [26e3, 105e3, 11e6, 77e5, 72e6], time: [3, 3, 3, 2, 2], price: [2e6, 23e6, 28e7, 29e8] }, { name: "Cheshire Cat", color: "#dd7399", class: "\uD83C\uDFF0", rarity: "Rare", cash: [32e3, 1e5, 9e5, 9e6, 6e7], time: [4, 3, 3, 3, 2], price: [18e5, 19e6, 22e7, 24e8] }, { name: "Caterpillar", color: "#00c0f3", class: "\uD83C\uDFF0", rarity: "Epic", cash: [1e4, 7e4, 65e4, 75e5, 85e6], time: [1, 1, 1, 1, 1], price: [42e5, 42e6, 54e7, 69e8] }, { name: "Mad Hatter", color: "#914f93", class: "\uD83C\uDFF0", rarity: "Epic", cash: [38e3, 25e4, 15e5, 14e6, 8e7], time: [3, 3, 2, 2, 1], price: [48e5, 48e6, 52e7, 66e8] }, { name: "King of Hearts", color: "#c62127", class: "\uD83C\uDFF0", rarity: "Legendary", cash: [8e4, 42e4, 68e5, 1e8, 15e8], time: [5, 5, 5, 5, 5], price: [7e6, 11e7, 18e8, 3e10] }, { name: "Earth", color: "#416eb5", class: "\uD83D\uDE80", rarity: "Uncommon", cash: [15e3, 45e3, 6e5, 65e5, 65e6], time: [3, 3, 3, 3, 3], price: [1e6, 11e6, 15e7, 17e8] }, { name: "Meteor", color: "#c68c3c", class: "\uD83D\uDE80", rarity: "Uncommon", cash: [23e3, 65e3, 7e5, 45e5, 2e7], time: [5, 4, 3, 2, 1], price: [95e4, 13e6, 16e7, 16e8] }, { name: "Stars", color: "#19184d", class: "\uD83D\uDE80", rarity: "Uncommon", cash: [1e4, 4e4, 2e5, 2e6, 18e6], time: [2, 2, 1, 1, 1], price: [14e5, 14e6, 15e7, 15e8] }, { name: "Alien", color: "#8dc63f", class: "\uD83D\uDE80", rarity: "Uncommon", cash: [3e4, 1e5, 1e6, 11e6, 85e6], time: [4, 4, 4, 4, 4], price: [15e5, 17e6, 19e7, 17e8] }, { name: "Planet", color: "#9dc6ea", class: "\uD83D\uDE80", rarity: "Rare", cash: [25e3, 1e5, 9e5, 9e6, 9e7], time: [3, 3, 3, 3, 3], price: [2e6, 21e6, 21e7, 24e8] }, { name: "UFO", color: "#a15095", class: "\uD83D\uDE80", rarity: "Rare", cash: [17e3, 7e4, 7e5, 7e6, 7e7], time: [2, 2, 2, 2, 2], price: [21e5, 23e6, 25e7, 28e8] }, { name: "Spaceship", color: "#ffcb29", class: "\uD83D\uDE80", rarity: "Epic", cash: [6e4, 32e4, 21e5, 15e6, 85e6], time: [5, 4, 3, 2, 1], price: [48e5, 46e6, 54e7, 68e8] }, { name: "Astronaut", color: "#9bd4ee", class: "\uD83D\uDE80", rarity: "Legendary", cash: [45e3, 26e4, 25e5, 38e6, 55e7], time: [3, 3, 2, 2, 2], price: [65e5, 1e8, 17e8, 27e9] }, { name: "Lil Bot", color: "#3e564a", class: "\uD83E\uDD16", rarity: "Uncommon", cash: [4e3, 12e3, 18e4, 19e5, 25e6], time: [1, 1, 1, 1, 1], price: [73e4, 12e6, 13e7, 19e8] }, { name: "Lovely Bot", color: "#f179af", class: "\uD83E\uDD16", rarity: "Uncommon", cash: [16e3, 65e3, 65e4, 48e5, 42e6], time: [3, 3, 3, 2, 2], price: [13e5, 14e6, 17e7, 16e8] }, { name: "Angry Bot", color: "#f1613a", class: "\uD83E\uDD16", rarity: "Uncommon", cash: [22e3, 85e3, 8e5, 62e5, 65e6], time: [4, 4, 4, 3, 3], price: [12e5, 13e6, 15e7, 17e8] }, { name: "Happy Bot", color: "#51ba6b", class: "\uD83E\uDD16", rarity: "Uncommon", cash: [11e3, 45e3, 5e5, 25e5, 3e7], time: [2, 2, 2, 1, 1], price: [14e5, 15e6, 18e7, 24e8] }, { name: "Watson", color: "#d69b5a", class: "\uD83E\uDD16", rarity: "Rare", cash: [24e3, 1e5, 1e6, 1e7, 1e8], time: [3, 3, 3, 3, 3], price: [2e6, 22e6, 24e7, 26e8] }, { name: "Buddy Bot", color: "#9dc6ea", class: "\uD83E\uDD16", rarity: "Rare", cash: [22e3, 95e3, 65e4, 65e5, 65e6], time: [3, 3, 2, 2, 2], price: [19e5, 21e6, 23e7, 25e8] }, { name: "Brainy Bot", color: "#9ecf7a", class: "\uD83E\uDD16", rarity: "Epic", cash: [5e4, 25e4, 21e5, 21e6, 17e7], time: [4, 3, 3, 3, 2], price: [5e6, 46e6, 5e8, 67e8] }, { name: "Mega Bot", color: "#d71f27", class: "\uD83E\uDD16", rarity: "Legendary", cash: [8e4, 43e4, 42e5, 62e6, 1e9], time: [5, 5, 3, 3, 3], price: [7e6, 12e7, 19e8, 35e9] }].map(x => ({ name: x.name, value: JSON.stringify(x) }))
  1459. }],
  1460. run: function (blook) {
  1461. const stateNode = getStateNode();
  1462. if (stateNode.state.blooks.length >= 10) alert("Choose a blook to replace");
  1463. stateNode.waiting = false;
  1464. stateNode.chooseBlook(JSON.parse(blook));
  1465. }
  1466. },
  1467. {
  1468. name: "Free Upgrades",
  1469. description: "Sets upgrade prices to 0 for all current blooks",
  1470. run: function () {
  1471. const prices = [0, 0, 0, 0];
  1472. let stateNode = getStateNode();
  1473. stateNode.setState({ blooks: stateNode.state.blooks.map(blook => (blook.price = prices, blook)) });
  1474. }
  1475. },
  1476. {
  1477. name: "Max Blooks",
  1478. description: "Maxes out all your blooks' levels",
  1479. run: function () {
  1480. getStateNode().state.blooks.forEach(blook => blook.level = 4);
  1481. }
  1482. },
  1483. {
  1484. name: "Remove Glitches",
  1485. description: "Removes all enemy glitches",
  1486. run: function () {
  1487. let stateNode = getStateNode();
  1488. stateNode.setState({
  1489. bits: 0,
  1490. ads: [],
  1491. hazards: [],
  1492. color: "",
  1493. lol: false,
  1494. joke: false,
  1495. slow: false,
  1496. dance: false,
  1497. glitch: "",
  1498. glitcherName: "",
  1499. glitcherBlook: ""
  1500. });
  1501. clearTimeout(stateNode.adTimeout);
  1502. clearInterval(stateNode.hazardInterval);
  1503. clearTimeout(stateNode.nightTimeout);
  1504. clearTimeout(stateNode.glitchTimeout);
  1505. clearTimeout(stateNode.lolTimeout);
  1506. clearTimeout(stateNode.jokeTimeout);
  1507. clearTimeout(stateNode.slowTimeout);
  1508. clearTimeout(stateNode.danceTimeout);
  1509. clearTimeout(stateNode.nameTimeout);
  1510. }
  1511. },
  1512. {
  1513. name: "Send Glitch",
  1514. description: "Sends a glitch to everyone else playing",
  1515. inputs: [{
  1516. name: "Glitch",
  1517. type: "options",
  1518. options: Object.entries({ lb: "Lunch Break", as: "Ad Spam", e37: "Error 37", nt: "Night Time", lo: "#LOL", j: "Jokester", sm: "Slow Mo", dp: "Dance Party", v: "Vortex", r: "Reverse", f: "Flip", m: "Micro" }).map(([value, name]) => ({ name, value }))
  1519. }],
  1520. run: function (val) {
  1521. let stateNode = getStateNode();
  1522. stateNode.safe = true;
  1523. stateNode.props.liveGameController.setVal({ path: `c/${stateNode.props.client.name}/tat`, val });
  1524. }
  1525. },
  1526. {
  1527. name: "Set All MegaBot",
  1528. description: "Sets all your blooks to maxed out Mega Bots",
  1529. run: function () {
  1530. getStateNode().setState({
  1531. blooks: Array.from({ length: 10 }, () => ({
  1532. name: "Mega Bot",
  1533. color: "#d71f27",
  1534. class: "🤖",
  1535. rarity: "Legendary",
  1536. cash: [8e4, 43e4, 42e5, 62e6, 1e9],
  1537. time: [5, 5, 3, 3, 3],
  1538. price: [7e6, 12e7, 19e8, 35e9],
  1539. active: false,
  1540. level: 4,
  1541. bonus: 5.5
  1542. }))
  1543. });
  1544. }
  1545. },
  1546. {
  1547. name: "Set Cash",
  1548. description: "Sets amount of cash you have",
  1549. inputs: [{
  1550. name: "Cash",
  1551. type: "number"
  1552. }],
  1553. run: function (cash) {
  1554. getStateNode().setState({ cash });
  1555. }
  1556. }
  1557. ],
  1558. },
  1559. fishing: {
  1560. name: "Fishing Frenzy",
  1561. img: "https://media.blooket.com/image/upload/v1661496295/Media/uiTest/Fish_Weight.svg",
  1562. cheats: [
  1563. {
  1564. name: "Remove Distractions",
  1565. description: "Removes distractions",
  1566. type: "toggle",
  1567. enabled: false,
  1568. data: null,
  1569. run: function () {
  1570. if (!this.enabled) {
  1571. this.enabled = true;
  1572. this.data = setInterval(() => {
  1573. getStateNode().setState({ party: "" });
  1574. }, 50);
  1575. } else {
  1576. this.enabled = false;
  1577. clearInterval(this.data);
  1578. this.data = null;
  1579. }
  1580. }
  1581. },
  1582. {
  1583. name: "Frenzy",
  1584. description: "Sets everyone to frenzy mode",
  1585. run: function () {
  1586. let stateNode = getStateNode();
  1587. stateNode.props.liveGameController.setVal({
  1588. path: `c/${stateNode.props.client.name}`,
  1589. val: {
  1590. b: stateNode.props.client.blook,
  1591. w: stateNode.state.weight,
  1592. f: "Frenzy",
  1593. s: true
  1594. }
  1595. });
  1596. }
  1597. },
  1598. {
  1599. name: "Send Distraction",
  1600. description: "Sends a distraction to everyone",
  1601. inputs: [{
  1602. name: "Distraction",
  1603. type: "options",
  1604. options: ["Crab", "Jellyfish", "Frog", "Pufferfish", "Octopus", "Narwhal", "Megalodon", "Blobfish", "Baby Shark"]
  1605. }],
  1606. run: function (f) {
  1607. let stateNode = getStateNode();
  1608. stateNode.safe = true;
  1609. stateNode.props.liveGameController.setVal({
  1610. path: `c/${stateNode.props.client.name}`,
  1611. val: {
  1612. b: stateNode.props.client.blook,
  1613. w: stateNode.state.weight, f, s: true
  1614. }
  1615. });
  1616. }
  1617. },
  1618. {
  1619. name: "Set Lure",
  1620. description: "Sets fishing lure (range 1 - 5)",
  1621. inputs: [{
  1622. name: "Lure (1 - 5)",
  1623. type: "number",
  1624. min: 1,
  1625. max: 5
  1626. }],
  1627. run: function (lure) {
  1628. getStateNode().setState({ lure: Math.max(Math.min(lure - 1, 4), 0) });
  1629. }
  1630. },
  1631. {
  1632. name: "Set Weight",
  1633. description: "Sets weight",
  1634. inputs: [{
  1635. name: "Weight",
  1636. type: "number"
  1637. }],
  1638. run: function (weight) {
  1639. let stateNode = getStateNode();
  1640. stateNode.setState({ weight, weight2: weight });
  1641. stateNode.props.liveGameController.setVal({
  1642. path: `c/${stateNode.props.client.name}`,
  1643. val: {
  1644. b: stateNode.props.client.blook,
  1645. w: weight,
  1646. f: ["Crab", "Jellyfish", "Frog", "Pufferfish", "Octopus", "Narwhal", "Megalodon", "Blobfish", "Baby Shark"][Math.floor(Math.random() * 9)]
  1647. }
  1648. });
  1649. }
  1650. }
  1651. ],
  1652. },
  1653. flappy: {
  1654. name: "Flappy Blook",
  1655. img: "https://media.blooket.com/image/upload/v1645222006/Blooks/yellowBird.svg",
  1656. cheats: [
  1657. {
  1658. name: "Toggle Ghost",
  1659. description: "Lets you go through the pipes",
  1660. type: "toggle",
  1661. enabled: false,
  1662. run: function () {
  1663. this.enabled = !this.enabled;
  1664. for (const body of Object.values(document.querySelector("#phaser-bouncy"))[0].return.updateQueue.lastEffect.deps[0].current.config.sceneConfig.physics.world.bodies.entries) {
  1665. if (!body.gameObject.frame.texture.key.startsWith("blook")) continue;
  1666. body.checkCollision.none = this.enabled;
  1667. body.gameObject.setAlpha(this.enabled ? 0.5 : 1);
  1668. break;
  1669. };
  1670. }
  1671. },
  1672. {
  1673. name: "Set Score",
  1674. description: "Sets flappy blook score",
  1675. inputs: [{
  1676. name: "Score",
  1677. type: "number"
  1678. }],
  1679. run: function (score) {
  1680. Object.values(document.querySelector("#phaser-bouncy"))[0].return.updateQueue.lastEffect.deps[1](score || 0);
  1681. }
  1682. }
  1683. ],
  1684. },
  1685. gold: {
  1686. name: "Gold Quest",
  1687. img: "https://media.blooket.com/image/upload/v1661496292/Media/uiTest/Gold.svg",
  1688. cheats: [
  1689. {
  1690. name: "Always Triple",
  1691. description: "Always get triple gold",
  1692. type: "toggle",
  1693. enabled: false,
  1694. data: { type: "multiply", val: 3, text: "Triple Gold!", blook: "Unicorn" },
  1695. run: function () {
  1696. let stateNode = getStateNode();
  1697. stateNode._choosePrize ||= stateNode.choosePrize;
  1698. if (!this.enabled) {
  1699. this.enabled = true;
  1700. stateNode.choosePrize = function (i) {
  1701. stateNode.state.choices[i] = this.data;
  1702. stateNode._choosePrize(i);
  1703. }
  1704. } else {
  1705. this.enabled = false;
  1706. if (stateNode._choosePrize) stateNode.choosePrize = stateNode._choosePrize;
  1707. }
  1708. }
  1709. },
  1710. {
  1711. name: "Auto Choose",
  1712. description: "Automatically picks the option that would give you the most gold",
  1713. type: "toggle",
  1714. enabled: false,
  1715. data: null,
  1716. run: function () {
  1717. if (!this.enabled) {
  1718. this.enabled = true;
  1719. this.data = setInterval(async () => {
  1720. let stateNode = getStateNode();
  1721. if (stateNode.state.stage == "prize") {
  1722. stateNode.props.liveGameController.getDatabaseVal("c", (players) => {
  1723. try {
  1724. if (players == null) return;
  1725. players = Object.entries(players);
  1726. let most = 0, max = 0, index = -1;
  1727. for (let i = 0; i < players.length; i++)
  1728. if (players[i][0] != stateNode.props.client.name && players[i][1] > most)
  1729. most = players[i][1];
  1730. for (let i = 0; i < stateNode.state.choices.length; i++) {
  1731. const choice = stateNode.state.choices[i];
  1732. let value = stateNode.state.gold;
  1733. if (choice.type == "gold")
  1734. value = stateNode.state.gold + choice.val || stateNode.state.gold;
  1735. else if (choice.type == "multiply" || choice.type == "divide")
  1736. value = Math.round(stateNode.state.gold * choice.val) || stateNode.state.gold;
  1737. else if (choice.type == "swap")
  1738. value = most || stateNode.state.gold;
  1739. else if (choice.type == "take")
  1740. value = stateNode.state.gold + most * choice.val || stateNode.state.gold;
  1741. if ((value || 0) <= max) continue;
  1742. max = value;
  1743. index = i + 1;
  1744. }
  1745. document.querySelector("div[class*='choice" + index + "']")?.click();
  1746. } catch { }
  1747. });
  1748. }
  1749. }, 50);
  1750. } else {
  1751. this.enabled = false;
  1752. clearInterval(this.data);
  1753. this.data = null;
  1754. }
  1755. }
  1756. },
  1757. {
  1758. name: "Chest ESP",
  1759. description: "Shows what each chest will give you",
  1760. type: "toggle",
  1761. enabled: false,
  1762. data: null,
  1763. run: function () {
  1764. if (!this.enabled) {
  1765. this.enabled = true;
  1766. this.data = setInterval(() => {
  1767. getStateNode().state.choices.forEach(({ text }, index) => {
  1768. let chest = document.querySelector(`div[class*='choice${index + 1}']`);
  1769. if (!chest || chest.querySelector('div')) return;
  1770. let choice = document.createElement('div')
  1771. choice.style.color = "white";
  1772. choice.style.fontFamily = "Eczar";
  1773. choice.style.fontSize = "2em";
  1774. choice.style.display = "flex";
  1775. choice.style.justifyContent = "center";
  1776. choice.style.transform = "translateY(200px)";
  1777. choice.innerText = text;
  1778. chest.append(choice)
  1779. });
  1780. }, 50);
  1781. } else {
  1782. this.enabled = false;
  1783. clearInterval(this.data);
  1784. this.data = null;
  1785. }
  1786. }
  1787. },
  1788. {
  1789. name: "Reset Players Gold",
  1790. description: "Sets a player's gold to 0",
  1791. inputs: [{
  1792. name: "Player",
  1793. type: "options",
  1794. options: () => {
  1795. let stateNode = getStateNode();
  1796. return stateNode.props.liveGameController._liveApp ? new Promise(res => stateNode.props.liveGameController.getDatabaseVal("c", (players) => players && res(Object.keys(players)))) : [];
  1797. }
  1798. }],
  1799. run: function (target) {
  1800. let stateNode = getStateNode();
  1801. stateNode.props.liveGameController.setVal({
  1802. path: "c/" + stateNode.props.client.name + "/tat",
  1803. val: target + ":swap:0"
  1804. });
  1805. }
  1806. },
  1807. {
  1808. name: "Set Gold",
  1809. description: "Sets amount of gold",
  1810. inputs: [{
  1811. name: "Gold",
  1812. type: "number"
  1813. }],
  1814. run: function (gold) {
  1815. let stateNode = getStateNode();
  1816. stateNode.setState({ gold, gold2: gold });
  1817. stateNode.props.liveGameController.setVal({
  1818. path: "c/" + stateNode.props.client.name + "/g",
  1819. val: gold
  1820. });
  1821. }
  1822. },
  1823. {
  1824. name: "Swap Gold",
  1825. description: "Swaps gold with someone",
  1826. inputs: [{
  1827. name: "Player",
  1828. type: "options",
  1829. options: () => {
  1830. let stateNode = getStateNode();
  1831. return stateNode.props.liveGameController._liveApp ? new Promise(res => stateNode.props.liveGameController.getDatabaseVal("c", (players) => players && res(Object.keys(players)))) : [];
  1832. }
  1833. }],
  1834. run: function (player) {
  1835. let stateNode = getStateNode();
  1836. stateNode.props.liveGameController.getDatabaseVal("c", (players) => {
  1837. if (!players || players[player] == null) return;
  1838. const gold = players[player].g || 0;
  1839. stateNode.props.liveGameController.setVal({
  1840. path: "c/" + stateNode.props.client.name,
  1841. val: {
  1842. b: stateNode.props.client.blook,
  1843. tat: player + ":swap:" + (stateNode.state.gold || 0),
  1844. g: gold
  1845. }
  1846. });
  1847. stateNode.setState({ gold, gold2: gold });
  1848. });
  1849. }
  1850. }
  1851. ],
  1852. },
  1853. kingdom: {
  1854. name: "Crazy Kingdom",
  1855. img: "https://media.blooket.com/image/upload/v1655161323/Media/survivor/Jester_lvl1.svg",
  1856. cheats: [
  1857. {
  1858. name: "Choice ESP",
  1859. description: "Shows you what will happen if you say Yes or No",
  1860. type: "toggle",
  1861. enabled: false,
  1862. data: null,
  1863. run: function () {
  1864. if (!this.enabled) {
  1865. this.enabled = true;
  1866. this.data = setInterval(stats => {
  1867. let stateNode = getStateNode();
  1868. let elements = Array.prototype.reduce.call(document.querySelectorAll('[class*=statContainer]'), (obj, container, i) => (obj[stats[i]] = container, obj), {});
  1869. if (stateNode.state.phase == "choice") {
  1870. Array.prototype.forEach.call(document.querySelectorAll('.choiceESP'), x => x.remove());
  1871. Object.keys(stateNode.state.guest.yes || {}).forEach(x => {
  1872. if (elements[x] == null) return;
  1873. let element = document.createElement('div');
  1874. element.className = 'choiceESP';
  1875. element.style = 'font-size: 24px; color: rgb(75, 194, 46); font-weight: bolder;';
  1876. element.innerText = String(stateNode.state.guest.yes[x]);
  1877. elements[x].appendChild(element);
  1878. });
  1879. Object.keys(stateNode.state.guest.no || {}).forEach(x => {
  1880. if (elements[x] == null) return;
  1881. let element = document.createElement('div');
  1882. element.className = 'choiceESP';
  1883. element.style = 'font-size: 24px; color: darkred; font-weight: bolder;';
  1884. element.innerText = String(stateNode.state.guest.no[x]);
  1885. elements[x].appendChild(element);
  1886. });
  1887. Array.prototype.forEach.call(document.querySelectorAll("[class*=guestButton][role=button]"), x => (x.onclick = () => Array.prototype.forEach.call(document.querySelectorAll(".choiceESP"), x => x.remove())));
  1888. }
  1889. }, 50, ['materials', 'people', 'happiness', 'gold']);
  1890. } else {
  1891. this.enabled = false;
  1892. clearInterval(this.data);
  1893. Array.prototype.forEach.call(document.querySelectorAll('.choiceESP'), x => x.remove());
  1894. this.data = null;
  1895. }
  1896. }
  1897. },
  1898. {
  1899. name: "Disable Tax Toucan",
  1900. description: "Tax evasion",
  1901. run: function () {
  1902. getStateNode().taxCounter = Number.MAX_VALUE;
  1903. }
  1904. },
  1905. {
  1906. name: "Max Stats",
  1907. description: "Sets all resources to the max",
  1908. run: function () {
  1909. getStateNode().setState({ materials: 100, people: 100, happiness: 100, gold: 100 });
  1910. }
  1911. },
  1912. {
  1913. name: "Set Guests",
  1914. description: "Sets the amount of guests you've seen",
  1915. inputs: [{
  1916. name: "Guests",
  1917. type: "number"
  1918. }],
  1919. run: function (guestScore) {
  1920. getStateNode().setState({ guestScore });
  1921. }
  1922. },
  1923. {
  1924. name: "Skip Guest",
  1925. description: "Skips the current guest",
  1926. run: function () {
  1927. getStateNode().nextGuest();
  1928. }
  1929. }
  1930. ],
  1931. },
  1932. racing: {
  1933. name: "Racing",
  1934. img: "https://media.blooket.com/image/upload/v1661496295/Media/uiTest/Racing_Progress.svg",
  1935. cheats: [
  1936. {
  1937. name: "Instant Win",
  1938. description: "Instantly Wins the race",
  1939. run: function () {
  1940. const stateNode = getStateNode();
  1941. stateNode.setState({ progress: stateNode.state.goalAmount });
  1942. stateNode.props.liveGameController.setVal({
  1943. path: "c/" + stateNode.props.client.name + "/pr",
  1944. val: stateNode.state.goalAmount
  1945. });
  1946. }
  1947. },
  1948. {
  1949. name: "Set Questions",
  1950. description: "Sets the number of questions left",
  1951. inputs: [{
  1952. name: "Questions",
  1953. type: "number"
  1954. }],
  1955. run: function (progress) {
  1956. let stateNode = getStateNode();
  1957. progress = stateNode.props.client.amount - progress;
  1958. stateNode.setState({ progress });
  1959. stateNode.props.liveGameController.setVal({
  1960. path: "c/" + stateNode.props.client.name + "/pr",
  1961. val: progress
  1962. });
  1963. }
  1964. }
  1965. ],
  1966. },
  1967. royale: {
  1968. name: "Battle Royale",
  1969. img: "https://media.blooket.com/image/upload/v1655936179/Media/br/VS_Lightning_Bolt_Bottom.svg",
  1970. cheats: [
  1971. {
  1972. name: "Auto Answer (Toggle)",
  1973. description: "Toggles auto answer on",
  1974. type: "toggle",
  1975. enabled: false,
  1976. data: null,
  1977. run: function () {
  1978. if (!this.enabled) {
  1979. this.enabled = true;
  1980. this.data = setInterval(() => {
  1981. let stateNode = getStateNode();
  1982. stateNode?.onAnswer?.(true, stateNode.props.client.question.correctAnswers[0]);
  1983. }, 50);
  1984. } else {
  1985. this.enabled = false;
  1986. clearInterval(this.data);
  1987. this.data = null;
  1988. }
  1989. }
  1990. },
  1991. {
  1992. name: "Auto Answer",
  1993. description: "Chooses the correct answer for you",
  1994. run: function () {
  1995. let stateNode = getStateNode();
  1996. stateNode?.onAnswer?.(true, stateNode.props.client.question.correctAnswers[0]);
  1997. }
  1998. },
  1999. ],
  2000. },
  2001. rush: {
  2002. name: "Blook Rush",
  2003. img: "https://ac.blooket.com/games-l/assets/shield-DEeSqHMF.png",
  2004. cheats: [
  2005. {
  2006. name: "Set Blooks",
  2007. description: "Sets amount of blooks you or your team has",
  2008. inputs: [{
  2009. name: "Blooks",
  2010. type: "number"
  2011. }],
  2012. run: function (numBlooks) {
  2013. let stateNode = getStateNode();
  2014. stateNode.setState({ numBlooks });
  2015. stateNode.props.liveGameController.setVal({
  2016. path: (stateNode.isTeam ? "a/" : "c/") + stateNode.props.client.name + "/bs",
  2017. val: numBlooks
  2018. });
  2019. }
  2020. },
  2021. {
  2022. name: "Set Defense",
  2023. description: "Sets amount of defense you or your team has (Max 4)",
  2024. inputs: [{
  2025. name: "Defense (max 4)",
  2026. type: "number",
  2027. max: 4
  2028. }],
  2029. run: function (defense) {
  2030. let numDefense = Math.min(defense, 4);
  2031. let stateNode = getStateNode();
  2032. stateNode.setState({ numDefense });
  2033. stateNode.props.liveGameController.setVal({
  2034. path: (stateNode.isTeam ? "a/" : "c/") + stateNode.props.client.name + "/d",
  2035. val: numDefense
  2036. });
  2037. }
  2038. }
  2039. ],
  2040. },
  2041. workshop: {
  2042. name: "Santa's Workshop",
  2043. img: "https://ac.blooket.com/games-l/assets/toy-CO4-YS66.svg",
  2044. cheats: [
  2045. {
  2046. name: "Remove Distractions",
  2047. description: "Removes all enemy distractions",
  2048. run: function () {
  2049. getStateNode().setState({ fog: !1, dusk: !1, wind: !1, plow: !1, blizzard: !1, force: !1, canada: !1, trees: [!1, !1, !1, !1, !1, !1, !1, !1, !1, !1] });
  2050. }
  2051. },
  2052. {
  2053. name: "Send Distraction",
  2054. description: "Sends a distraction to everyone else playing",
  2055. inputs: [{
  2056. name: "Distraction",
  2057. type: "options",
  2058. options: Object.entries({ c: "Oh Canada", b: "Blizzard", f: "Fog Spell", d: "Dark & Dusk", w: "Howling Wind", g: "Gift Time!", t: "TREES", s: "Snow Plow", fr: "Use The Force" }).map(([value, name]) => ({ name, value }))
  2059. }],
  2060. run: function (val) {
  2061. let stateNode = getStateNode();
  2062. stateNode.safe = true;
  2063. stateNode.props.liveGameController.setVal({ path: `c/${stateNode.props.client.name}/tat`, val });
  2064. }
  2065. },
  2066. {
  2067. name: "Set Toys",
  2068. description: "Sets amount of toys",
  2069. inputs: [{
  2070. name: "Toys",
  2071. type: "number"
  2072. }],
  2073. run: function (toys) {
  2074. let stateNode = getStateNode();
  2075. stateNode.setState({ toys });
  2076. stateNode.props.liveGameController.setVal({
  2077. path: "c/" + stateNode.props.client.name + "/t",
  2078. val: toys
  2079. });
  2080. }
  2081. },
  2082. {
  2083. name: "Set Toys Per Question",
  2084. description: "Sets amount of toys per question",
  2085. inputs: [{
  2086. name: "Toys Per Question",
  2087. type: "number"
  2088. }],
  2089. run: function (toysPerQ) {
  2090. getStateNode().setState({ toysPerQ });
  2091. }
  2092. },
  2093. {
  2094. name: "Swap Toys",
  2095. description: "Swaps toys with someone",
  2096. inputs: [{
  2097. name: "Player",
  2098. type: "options",
  2099. options: () => {
  2100. let stateNode = getStateNode();
  2101. return stateNode.props.liveGameController._liveApp ? new Promise(res => stateNode.props.liveGameController.getDatabaseVal("c", (players) => players && res(Object.keys(players)))) : [];
  2102. }
  2103. }],
  2104. run: function (target) {
  2105. let stateNode = getStateNode();
  2106. stateNode.props.liveGameController.getDatabaseVal("c", (players) => {
  2107. if (!players || players[target] == null) return;
  2108. stateNode.props.liveGameController.setVal({
  2109. path: "c/" + stateNode.props.client.name + "/tat",
  2110. val: `${target}:swap:${stateNode.state.toys}`
  2111. });
  2112. stateNode.setState({ toys: players[target].t });
  2113. });
  2114. }
  2115. }
  2116. ],
  2117. },
  2118. settings: {
  2119. name: "Settings",
  2120. img: null,
  2121. cheats: [
  2122. {
  2123. name: "Import Settings",
  2124. description: "Import a custom theme",
  2125. inputs: [
  2126. {
  2127. name: "JSON Data",
  2128. type: "string"
  2129. }
  2130. ],
  2131. run: function (theme) {
  2132. try {
  2133. JSON.parse(theme);
  2134. } catch (e) {
  2135. return alert("Invalid JSON provided");
  2136. }
  2137. theme = { backgroundColor: "rgb(11, 194, 207)", infoColor: "#9a49aa", cheatList: "#9a49aa", defaultButton: "#9a49aa", disabledButton: "#A02626", enabledButton: "#47A547", textColor: "white", inputColor: "#7a039d", contentBackground: "rgb(64, 17, 95)", ...JSON.parse(theme) }
  2138. settings.setItem("theme", theme);
  2139. }
  2140. },
  2141. {
  2142. name: "Export Settings",
  2143. description: "Export the current theme to JSON",
  2144. run: async function () {
  2145. await navigator.clipboard.writeText(JSON.stringify(settings.data.theme, null, 4));
  2146. prompt("Text copied to clipboard. (Paste below to test)");
  2147. }
  2148. },
  2149. {
  2150. name: "Defaults",
  2151. description: "Changes all the settings to a preset",
  2152. inputs: [
  2153. {
  2154. name: "Theme",
  2155. type: "options",
  2156. options: [
  2157. {
  2158. name: "Default",
  2159. value: {
  2160. backgroundColor: "rgb(11, 194, 207)",
  2161. infoColor: "#9a49aa",
  2162. cheatList: "#9a49aa",
  2163. defaultButton: "#9a49aa",
  2164. disabledButton: "#A02626",
  2165. enabledButton: "#47A547",
  2166. textColor: "white",
  2167. inputColor: "#7a039d",
  2168. contentBackground: "rgb(64, 17, 95)"
  2169. }
  2170. },
  2171. {
  2172. name: "Blacket",
  2173. value: {
  2174. backgroundColor: "#4f4f4f",
  2175. infoColor: "#2f2f2f",
  2176. cheatList: "#2f2f2f",
  2177. defaultButton: "#4f4f4f",
  2178. disabledButton: "#eb6234",
  2179. enabledButton: "#00c20c",
  2180. textColor: "white",
  2181. inputColor: "#3f3f3f",
  2182. contentBackground: "#2f2f2f"
  2183. }
  2184. },
  2185. {
  2186. name: "Skool.lol",
  2187. value: {
  2188. backgroundColor: "linear-gradient(90deg, rgba(104,45,140,1) 220px, rgba(237,30,121,1) 100%)",
  2189. cheatList: "#1e2124",
  2190. infoColor: "#1e2124",
  2191. defaultButton: "#36393e",
  2192. inputColor: "#1e2124",
  2193. enabledButton: "#9c9a9a",
  2194. textColor: "white",
  2195. disabledButton: "#171717",
  2196. contentBackground: "#292929"
  2197. }
  2198. },
  2199. {
  2200. name: "Blue - Purple Background",
  2201. value: {
  2202. backgroundColor: "linear-gradient(162.5deg, rgba(0,183,255,1) 220px, rgba(128,0,255,1) 100%)"
  2203. }
  2204. },
  2205. {
  2206. name: "Saint Patricks Background",
  2207. value: {
  2208. backgroundColor: "rgb(9, 148, 65)"
  2209. }
  2210. },
  2211. {
  2212. name: "Halloween Background",
  2213. value: {
  2214. backgroundColor: "rgb(41, 41, 41)"
  2215. }
  2216. },
  2217. {
  2218. name: "Fall Background",
  2219. value: {
  2220. backgroundColor: "rgb(224, 159, 62)"
  2221. }
  2222. },
  2223. {
  2224. name: "Winter Background",
  2225. value: {
  2226. backgroundColor: "linear-gradient(rgb(49, 170, 224), rgb(187, 221, 255))"
  2227. }
  2228. },
  2229. {
  2230. name: "Crypto Hack",
  2231. value: {
  2232. backgroundColor: "radial-gradient(#11581e,#041607)",
  2233. infoColor: "#1a1a1a",
  2234. cheatList: "#1a1a1a",
  2235. defaultButton: "rgb(88 175 88)",
  2236. disabledButton: "#A02626",
  2237. enabledButton: "#0b601b",
  2238. textColor: "white",
  2239. inputColor: "rgb(0 0 0 / 25%)",
  2240. contentBackground: "#11581e"
  2241. }
  2242. },
  2243. {
  2244. name: "Fishing Frenzy",
  2245. value: {
  2246. backgroundColor: "linear-gradient(180deg,#9be2fe 0,#67d1fb)",
  2247. infoColor: "#c8591e",
  2248. cheatList: "#c8591e",
  2249. defaultButton: "#ff751a",
  2250. disabledButton: "#bf0e0e",
  2251. enabledButton: "#2fb62f",
  2252. textColor: "white",
  2253. inputColor: "rgb(0 0 0 / 25%)",
  2254. contentBackground: "radial-gradient(#02b0ea 40%, #1d86ea)"
  2255. }
  2256. },
  2257. {
  2258. name: "Deceptive Dinos",
  2259. value: {
  2260. backgroundColor: "radial-gradient(rgba(220, 184, 86, 0), rgba(220, 184, 86, 0.4)), url(\"https://ac.blooket.com/play/111cb7e0ee6607ac3d1a13d534c0e0f1.png\"), #ead49a",
  2261. infoColor: "#af8942",
  2262. cheatList: "#af8942",
  2263. defaultButton: "#af8942",
  2264. disabledButton: "#A02626",
  2265. enabledButton: "#47A547",
  2266. textColor: "white",
  2267. inputColor: "rgb(0 0 0 / 10%)",
  2268. contentBackground: "radial-gradient(rgba(1,104,162,.6),rgba(24,55,110,.5)),radial-gradient(#2783b4 1.5px,#18376e 0) center / 24px 24px"
  2269. }
  2270. },
  2271. {
  2272. name: "Blook Rush",
  2273. value: {
  2274. backgroundColor: "repeating-linear-gradient(45deg,white,white 8%,#e6e6e6 0,#e6e6e6 16%)",
  2275. defaultButton: "#36c",
  2276. inputColor: "rgb(0 0 0 / 25%)",
  2277. infoColor: "#36c",
  2278. cheatList: "#36c",
  2279. contentBackground: "#888",
  2280. textColor: "white",
  2281. disabledButton: "#A02626",
  2282. enabledButton: "#47A547"
  2283. }
  2284. },
  2285. {
  2286. name: "Factory",
  2287. value: {
  2288. defaultButton: "#1563bf",
  2289. infoColor: "#a5aabe",
  2290. cheatList: "#a5aabe",
  2291. contentBackground: "#2d313d",
  2292. backgroundColor: "#3a3a3a",
  2293. enabledButton: "rgb(75, 194, 46)",
  2294. disabledButton: "#9a49aa",
  2295. inputColor: "rgb(0 0 0 / 25%)",
  2296. textColor: "white"
  2297. }
  2298. },
  2299. {
  2300. name: "Cafe",
  2301. value: {
  2302. backgroundColor: "linear-gradient(90deg,rgba(200,0,0,.5) 50%,transparent 0) center / 50px 50px,linear-gradient(rgba(200,0,0,0.5) 50%,transparent 0) white center / 50px 50px",
  2303. defaultButton: "#0bc2cf",
  2304. inputColor: "rgb(0 0 0 / 25%)",
  2305. infoColor: "#ac7339",
  2306. cheatList: "#ac7339",
  2307. contentBackground: "rgb(64, 64, 64)",
  2308. textColor: "white",
  2309. disabledButton: "#A02626",
  2310. enabledButton: "#47A547"
  2311. }
  2312. },
  2313. {
  2314. name: "Tower of Doom",
  2315. value: {
  2316. backgroundColor: "rgb(41 41 41)",
  2317. disabledButton: "rgb(151, 15, 5)",
  2318. defaultButton: "#333",
  2319. inputColor: "rgb(0 0 0 / 25%)",
  2320. contentBackground: "#404040",
  2321. enabledButton: "#4bc22e",
  2322. textColor: "white",
  2323. infoColor: "#9a49aa",
  2324. cheatList: "#9a49aa"
  2325. }
  2326. },
  2327. {
  2328. name: "Monster Brawl",
  2329. value: {
  2330. defaultButton: "rgb(45, 51, 67)",
  2331. backgroundColor: "rgb(78, 95, 124)",
  2332. inputColor: "rgb(0 0 0 / 25%)",
  2333. contentBackground: "linear-gradient(0deg,#374154,#4f5b74)",
  2334. infoColor: "#374154",
  2335. cheatList: "#374154",
  2336. textColor: "white",
  2337. enabledButton: "#47A547",
  2338. disabledButton: "#A02626"
  2339. }
  2340. },
  2341. {
  2342. name: "Tower Defense 2",
  2343. value: {
  2344. backgroundColor: "url(https://media.blooket.com/image/upload/v1676164454/Media/defense/backgroundTd1-02.svg) center / cover",
  2345. cheatList: "#a33c22",
  2346. infoColor: "#a33c22",
  2347. defaultButton: "#40b1d8",
  2348. inputColor: "#3e8cbe",
  2349. contentBackground: "#293c82",
  2350. enabledButton: "#47A547",
  2351. disabledButton: "#A02626",
  2352. textColor: "white"
  2353. }
  2354. },
  2355. ]
  2356. }
  2357. ],
  2358. run: function (theme) {
  2359. settings.setItem("theme", { ...settings.data.theme, ...theme });
  2360. }
  2361. },
  2362. {
  2363. name: "Scale",
  2364. description: "Forces the GUI to scale from 25%-100%",
  2365. inputs: [
  2366. {
  2367. type: "number",
  2368. name: "Percent scale",
  2369. min: 25,
  2370. max: 100,
  2371. value: (settings.data?.scale || 1) * 100
  2372. }
  2373. ],
  2374. run: function (scale) {
  2375. scale = Math.min(Math.max(scale, 25), 100);
  2376. settings.setItem("scale", scale / 100);
  2377. guiWrapper.style.transform = `scale(${(scale / 100)})`;
  2378. }
  2379. },
  2380. {
  2381. name: "Hide Keybind",
  2382. description: "Change the hide keybind (Click button after input to change)",
  2383. inputs: [
  2384. {
  2385. type: "function",
  2386. name: "Input",
  2387. function: onchange => createKeybindListener(({ shift, ctrl, alt, key }) => onchange(`${[ctrl && "Ctrl", shift && "Shift", alt && "Alt", key && key.toUpperCase()].filter(Boolean).join(' + ')}`))
  2388. }
  2389. ],
  2390. run: function (hide) {
  2391. settings.setItem("hide", hide);
  2392. }
  2393. },
  2394. {
  2395. name: "Close Keybind",
  2396. description: "Change the quick close keybind (Click button after input to change)",
  2397. inputs: [
  2398. {
  2399. type: "function",
  2400. name: "Input",
  2401. function: onchange => createKeybindListener(({ shift, ctrl, alt, key }) => onchange(`${[ctrl && "Ctrl", shift && "Shift", alt && "Alt", key && key.toUpperCase()].filter(Boolean).join(' + ')}`))
  2402. }
  2403. ],
  2404. run: function (close) {
  2405. settings.setItem("close", close);
  2406. }
  2407. },
  2408. {
  2409. name: "Background Color",
  2410. description: "Changes the background color of the GUI",
  2411. inputs: [{
  2412. type: "string",
  2413. name: "Color"
  2414. }],
  2415. run: function (color) {
  2416. settings.setItem("theme.backgroundColor", color);
  2417. }
  2418. },
  2419. {
  2420. name: "Category List Color",
  2421. description: "Changes the categories list background color",
  2422. inputs: [{
  2423. type: "string",
  2424. name: "Color"
  2425. }],
  2426. run: function (color) {
  2427. settings.setItem("theme.cheatList", color);
  2428. }
  2429. },
  2430. {
  2431. name: "Info Color",
  2432. description: "Changes the color of the information at the top of the GUI",
  2433. inputs: [{
  2434. type: "string",
  2435. name: "Color"
  2436. }],
  2437. run: function (color) {
  2438. settings.setItem("theme.infoColor", color);
  2439. }
  2440. },
  2441. {
  2442. name: "Button Color",
  2443. description: "Changes the color of the cheats",
  2444. inputs: [{
  2445. type: "string",
  2446. name: "Color"
  2447. }],
  2448. run: function (color) {
  2449. settings.setItem("theme.defaultButton", color);
  2450. }
  2451. },
  2452. {
  2453. name: "Enabled Toggle Color",
  2454. description: "Changes the color of enabled toggle cheats",
  2455. inputs: [{
  2456. type: "string",
  2457. name: "Color"
  2458. }],
  2459. run: function (color) {
  2460. settings.setItem("theme.enabledButton", color);
  2461. }
  2462. },
  2463. {
  2464. name: "Disabled Toggle Color",
  2465. description: "Changes the color of disabled toggle cheats",
  2466. inputs: [{
  2467. type: "string",
  2468. name: "Color"
  2469. }],
  2470. run: function (color) {
  2471. settings.setItem("theme.disabledButton", color);
  2472. }
  2473. },
  2474. {
  2475. name: "Text Color",
  2476. description: "Changes the text color",
  2477. inputs: [{
  2478. type: "string",
  2479. name: "Color"
  2480. }],
  2481. run: function (color) {
  2482. settings.setItem("theme.textColor", color);
  2483. }
  2484. },
  2485. {
  2486. name: "Input Color",
  2487. description: "Changes the color of inputs, like the set gold number input",
  2488. inputs: [{
  2489. type: "string",
  2490. name: "Color"
  2491. }],
  2492. run: function (color) {
  2493. settings.setItem("theme.inputColor", color);
  2494. }
  2495. },
  2496. {
  2497. name: "Content Color",
  2498. description: "Changes the background color of the cheats",
  2499. inputs: [{
  2500. type: "string",
  2501. name: "Color"
  2502. }],
  2503. run: function (color) {
  2504. settings.setItem("theme.contentBackground", color);
  2505. }
  2506. }
  2507. ]
  2508. },
  2509. }
  2510. const GUIContainer = document.createElement("div");
  2511. function createKeybindListener(onpress, element = window) {
  2512. return new Promise(resolve => {
  2513. const pressed = {};
  2514. let shift, ctrl, alt, key;
  2515. const keydown = e => {
  2516. e.preventDefault();
  2517. pressed[e.code] = true;
  2518. shift ||= e.shiftKey;
  2519. ctrl ||= e.ctrlKey;
  2520. alt ||= e.altKey;
  2521. if (!["shift", "control", "alt", "meta"].includes(e.key.toLowerCase())) key = e.key.toLowerCase();
  2522. onpress?.({ shift, ctrl, alt, key });
  2523. };
  2524. const keyup = e => {
  2525. delete pressed[e.code];
  2526. if (Object.keys(pressed).length > 0) return;
  2527. element.removeEventListener("keydown", keydown);
  2528. element.removeEventListener("keyup", keyup);
  2529. resolve({ shift, ctrl, alt, key });
  2530. };
  2531. element.addEventListener("keydown", keydown);
  2532. element.addEventListener("keyup", keyup);
  2533. });
  2534. }
  2535. function AntiBen({ type = "div", children, ...props }) {
  2536. let childs = [];
  2537. let char = (space) => JSX.jsx("span", {
  2538. style: {
  2539. display: "inline-block",
  2540. opacity: "0",
  2541. width: "0",
  2542. height: "0",
  2543. lineHeight: "0",
  2544. userSelect: "none",
  2545. marginLeft: space ? "5px" : null
  2546. },
  2547. children: String.fromCharCode(Math.floor(Math.random() * 25) + 97)
  2548. })
  2549. const addChar = (child) => {
  2550. if (typeof child == "string") {
  2551. let text = [];
  2552. for (let i = 0; i < child.length; i += 3) text.push(child.slice(i, i + 3), char());
  2553. childs.push(...text);
  2554. }
  2555. else childs.push(child, char());
  2556. }
  2557. if (Array.isArray(children)) for (let i = 0; i < children.length; i++) addChar(children[i]);
  2558. else addChar(children);
  2559. return JSX.jsx(type, Object.assign({ children: JSX.jsx("span", { children: childs }) }, props));
  2560. }
  2561. function ScriptInput({ input, onValue, run, toggle }) {
  2562. const { name, type, options: opts, min, max, value } = input;
  2563. let optState;
  2564. try {
  2565. optState = typeof opts == "function" ? opts() : opts;
  2566. } catch (e) {
  2567. console.warn(e);
  2568. optState = [];
  2569. }
  2570. const [options, setOptions] = useState(optState)
  2571. const [locked, setLocked] = useState("");
  2572. const loading = useRef(true);
  2573. useEffect(() => {
  2574. if (options instanceof Promise) options.then((o) => {
  2575. setOptions(o);
  2576. onValue(o[0]?.value || o[0]);
  2577. input.selected = o[0]?.name || o[0];
  2578. loading.current = false;
  2579. }).catch(() => setOptions([]));
  2580. else if (options?.length) {
  2581. onValue(options[0]?.value || options[0]);
  2582. input.selected = options[0]?.name || options[0];
  2583. }
  2584. if (type == "number") onValue(value || (min == null ? 0 : min));
  2585. else if (type == "function") onValue(null);
  2586. else if (!(options instanceof Promise) && !options?.length) onValue("");
  2587. }, []);
  2588. let el;
  2589. if (type == "options" && options?.length) el = JSX.jsx("select", {
  2590. onChange: e => (input.selected = e.target.children[e.target.selectedIndex].innerText, onValue(JSON.parse(e.target.value))),
  2591. children: options.map(opt => JSX.jsx("option", {
  2592. value: JSON.stringify(opt?.value != null ? opt.value : opt),
  2593. children: opt?.name || opt
  2594. }))
  2595. });
  2596. else if (type == "function") el = JSX.jsx("input", {
  2597. className: styles.keys.cheatInput,
  2598. placeholder: name,
  2599. style: {
  2600. textAlign: "center"
  2601. },
  2602. readOnly: true,
  2603. value: locked || input.data,
  2604. onClick: async () => {
  2605. if (locked) return;
  2606. setLocked("Waiting for input...");
  2607. let value;
  2608. const data = await input.function(e => setLocked((value = e) + "..."));
  2609. input.data = value;
  2610. setLocked(false);
  2611. onValue(data);
  2612. }
  2613. });
  2614. else {
  2615. let isNumber = type == "number";
  2616. el = JSX.jsx("input", {
  2617. onChange: e => onValue(isNumber ? parseInt(e.target.value) : e.target.value),
  2618. className: styles.keys.cheatInput,
  2619. type: isNumber ? "number" : null,
  2620. min: isNumber ? min : null,
  2621. max: isNumber ? max : null,
  2622. defaultValue: isNumber ? value || (min == null ? 0 : min) : null,
  2623. placeholder: name,
  2624. style: {
  2625. textAlign: "center",
  2626. backgroundColor: toggle && "#0003"
  2627. },
  2628. onKeyUp: e => e.key == "Enter" && run()
  2629. });
  2630. }
  2631. return el;
  2632. }
  2633. function ScriptButton({ script }) {
  2634. const args = useRef([]);
  2635. const [enabled, setEnabled] = useState(script.enabled);
  2636. const run = useCallback(() => {
  2637. script.run.apply(script, args.current);
  2638. setEnabled(script.enabled);
  2639. }, []);
  2640. return makeElement("div", {
  2641. style: {
  2642. background: script.type == "toggle" ? enabled ? "var(--enabledButton)" : "var(--disabledButton)" : "var(--defaultButton)"
  2643. },
  2644. key: script.name,
  2645. "data-tip": script.description,
  2646. className: styles.keys.scriptButton,
  2647. onClick: e => (e.target.matches(`.${styles.keys.scriptButton}`) || e.target.matches(`.${styles.keys.cheatName}`) || e.target.matches(`.${styles.keys.cheatName} *`)) && run()
  2648. }, makeElement(AntiBen, {
  2649. className: styles.keys.cheatName
  2650. }, script.name), script.inputs?.length && script.inputs.map((input, i) => input.element || makeElement(ScriptInput, {
  2651. onValue: val => args.current[i] = val,
  2652. key: i,
  2653. input: input,
  2654. run: run,
  2655. toggle: script.type == "toggle"
  2656. })));
  2657. }
  2658. function useSettings(settingsKey) {
  2659. const [data, updateData] = useState(JSON.parse(localStorage.getItem(settingsKey) || "{}"));
  2660. const setItem = useCallback((k, v) => {
  2661. k.split('.').reduce((obj, k, i, a) => (++i == a.length && (obj[k] = v), obj[k]), data);
  2662. localStorage.setItem(settingsKey, JSON.stringify(data));
  2663. updateData({ ...data });
  2664. return data;
  2665. }, [data]);
  2666. const deleteItem = useCallback((k, v) => {
  2667. k.split('.').reduce((obj, k, i, a) => (++i == a.length && (delete obj[k]), obj[k]), data);
  2668. localStorage.setItem(settingsKey, JSON.stringify(data));
  2669. updateData({ ...data });
  2670. return data;
  2671. }, [data]);
  2672. const setData = useCallback((v) => {
  2673. updateData(v);
  2674. localStorage.setItem(settingsKey, JSON.stringify(v));
  2675. }, []);
  2676. useEffect(() => {
  2677. try {
  2678. updateData(JSON.parse(localStorage.getItem(settingsKey) || "{}"));
  2679. for (const setting of ["backgroundColor", "cheatList", "contentBackground", "defaultButton", "disabledButton", "enabledButton", "infoColor", "inputColor", "textColor"]) if (settings.data[setting]) {
  2680. setItem(`theme.${setting}`, settings.data[setting]);
  2681. deleteItem(setting);
  2682. }
  2683. } catch {
  2684. setData({});
  2685. }
  2686. }, [])
  2687. return { data, setItem, deleteItem, setData };
  2688. }
  2689. function Draggable({ parent, children, setPos, ...props }) {
  2690. const mouseDown = useRef(false);
  2691. const pos = useRef({ x: 0, y: 0 });
  2692. useEffect(() => {
  2693. const pointerup = () => mouseDown.current = false;
  2694. const pointermove = (e) => {
  2695. if (!mouseDown.current) return;
  2696. let dx = pos.current.x - e.clientX;
  2697. let dy = pos.current.y - e.clientY;
  2698. pos.current = { x: e.clientX, y: e.clientY };
  2699. var ratio = 1 || parseFloat((0.75 / window.devicePixelRatio).toFixed(2));
  2700. setPos({ x: parent.offsetLeft - dx / ratio, y: parent.offsetTop - dy / ratio });
  2701. }
  2702. document.addEventListener("pointerup", pointerup);
  2703. document.addEventListener("pointermove", pointermove);
  2704. return () => {
  2705. document.removeEventListener("pointerup", pointerup);
  2706. document.removeEventListener("pointermove", pointermove);
  2707. }
  2708. }, [parent]);
  2709. return makeElement("div", {
  2710. ...props, onPointerDown: e => {
  2711. mouseDown.current = true;
  2712. pos.current = {
  2713. x: e.clientX,
  2714. y: e.clientY
  2715. };
  2716. }
  2717. }, children);
  2718. }
  2719. function GUI() {
  2720. const { current: pos } = useRef({
  2721. x: Math.max(10, window.innerWidth - 1000) / 2,
  2722. y: Math.max(10, window.innerHeight - 600) / 2,
  2723. });
  2724. const setPos = useCallback(({ x, y }) => {
  2725. pos.x = x;
  2726. pos.y = y;
  2727. guiRef.current.style.left = `${x}px`;
  2728. guiRef.current.style.top = `${y}px`;
  2729. }, []);
  2730. const [minified, setMinified] = useState(null);
  2731. const [hidden, setHidden] = useState(false);
  2732. const [currentMode, setCurrentMode] = useState("global");
  2733. const guiRef = useRef();
  2734. const alertInterval = useRef();
  2735. settings = useSettings("JODGUISETTINGS");
  2736. const variables = makeElement("style", null, `:root {--backgroundColor: ${settings.data?.theme?.backgroundColor || "rgb(11, 194, 207)"};--infoColor: ${settings.data?.theme?.infoColor || "#9a49aa"};--cheatList: ${settings.data?.theme?.cheatList || "#9a49aa"};--defaultButton: ${settings.data?.theme?.defaultButton || "#9a49aa"};--disabledButton: ${settings.data?.theme?.disabledButton || "#A02626"};--enabledButton: ${settings.data?.theme?.enabledButton || "#47A547"};--textColor: ${settings.data?.theme?.textColor || "white"};--inputColor: ${settings.data?.theme?.inputColor || "#7a039d"};--contentBackground: ${settings.data?.theme?.contentBackground || "rgb(64, 17, 95)"};}`);
  2737. const { current: gamemodes } = useRef(["global", "voyage", "gold", "cafe", "crypto", "dinos", "defense", "defense2", "factory", "fishing", "flappy", "doom", "kingdom", "racing", "royale", "rush", "brawl", "workshop", "settings"]);
  2738. const close = useCallback(() => {
  2739. ReactDOM.unmountComponentAtNode(GUIContainer);
  2740. GUIContainer.remove();
  2741. }, []);
  2742. useEffect(() => {
  2743. window.dispatchEvent(new Event("resize"));
  2744. let keydown = e => {
  2745. let hideKey = settings.data.hide || { ctrl: true, key: "e" };
  2746. let closeKey = settings.data.close || { ctrl: true, key: "x" };
  2747. if ((hideKey.ctrl && e.ctrlKey || !hideKey.ctrl && !e.ctrlKey) && (hideKey.shift && e.shiftKey || !hideKey.shift && !e.shiftKey) && (hideKey.alt && e.altKey || !hideKey.alt && !e.altKey) && e.key.toLowerCase() == hideKey.key) {
  2748. e.preventDefault();
  2749. setHidden(h => !h);
  2750. } else if ((closeKey.ctrl && e.ctrlKey || !closeKey.ctrl && !e.ctrlKey) && (closeKey.shift && e.shiftKey || !closeKey.shift && !e.shiftKey) && (closeKey.alt && e.altKey || !closeKey.alt && !e.altKey) && e.key.toLowerCase() == closeKey.key) {
  2751. e.preventDefault();
  2752. close();
  2753. }
  2754. };
  2755. window.addEventListener("keydown", keydown);
  2756. return () => {
  2757. window.removeEventListener("keydown", keydown);
  2758. for (const gamemode of gamemodes) for (const cheat of Cheats[gamemode].cheats) if (cheat.enabled) cheat.run();
  2759. }
  2760. }, []);
  2761. useEffect(() => {
  2762. if (minified == null) return () => { };
  2763. let gui = guiRef.current.querySelector("div");
  2764. gui.style.height = !minified ? "100%" : "55px";
  2765. gui.style.width = !minified ? "100%" : "165px";
  2766. guiRef.current.style.top = `${parseInt(guiRef.current.style.top) + (guiRef.current.offsetHeight - 55) * (!minified ? -1 : 1)}px`;
  2767. guiRef.current.style.left = `${parseInt(guiRef.current.style.left) + (guiRef.current.offsetWidth - 165) * (!minified ? -1 : 1)}px`;
  2768. guiRef.current.style.pointerEvents = !minified ? "unset" : "none";
  2769. }, [minified])
  2770. return makeElement("div", {
  2771. ref: guiRef,
  2772. id: styles.keys.guiWrapper,
  2773. style: {
  2774. top: `${pos.y}px`,
  2775. left: `${pos.x}px`,
  2776. transform: `scale(${settings.data.scale || 1})`,
  2777. display: hidden ? "none" : null
  2778. }
  2779. }, makeElement("style", null, styles.css), variables, makeElement("div", {
  2780. id: styles.keys.gui
  2781. }, makeElement("div", {
  2782. id: styles.keys.controlButtons
  2783. }, makeElement(Draggable, {
  2784. parent: guiRef.current,
  2785. setPos: setPos,
  2786. style: {
  2787. backgroundColor: "rgb(0, 160, 255)"
  2788. },
  2789. className: styles.keys.dragButton
  2790. }, makeElement("i", {
  2791. className: "fas fa-arrows-alt"
  2792. })), makeElement("div", {
  2793. style: {
  2794. fontWeight: "bolder",
  2795. backgroundColor: "grey",
  2796. cursor: "pointer"
  2797. },
  2798. onClick: () => setMinified(m => !m)
  2799. }, makeElement("i", {
  2800. className: "fas fa-minus"
  2801. })), makeElement("div", {
  2802. style: {
  2803. fontWeight: "bolder",
  2804. backgroundColor: "red",
  2805. cursor: "pointer"
  2806. },
  2807. onClick: close
  2808. }, makeElement("i", {
  2809. className: "fas fa-times"
  2810. }))), !minified && makeElement(React.Fragment, null, makeElement("div", {
  2811. id: styles.keys.background
  2812. }, makeElement("div", {
  2813. id: styles.keys.backgroundImage
  2814. })), makeElement(Draggable, {
  2815. parent: guiRef.current,
  2816. setPos: setPos,
  2817. id: styles.keys.controls
  2818. }, (({ ctrl: ctrlHide, shift: shiftHide, alt: altHide, key: keyHide } = { ctrl: true, key: "q" }, { ctrl: ctrlClose, shift: shiftClose, alt: altClose, key: keyClose } = { ctrl: true, key: "x" }) => {
  2819. return makeElement(React.Fragment, null, `${[ctrlHide && "Ctrl", shiftHide && "Shift", altHide && "Alt", keyHide && keyHide.toUpperCase()].filter(Boolean).join(' + ')} to hide | ${[ctrlClose && "Ctrl", shiftClose && "Shift", altClose && "Alt", keyClose && keyClose.toUpperCase()].filter(Boolean).join(' + ')} for quick disable`, makeElement("br", null), makeElement(AntiBen, null, "Click and drag here"));
  2820. })(settings.data.hide || {
  2821. ctrl: true,
  2822. key: "e"
  2823. }, settings.data.close || {
  2824. ctrl: true,
  2825. key: "x"
  2826. })), makeElement("div", {
  2827. id: styles.keys.credits
  2828. }, makeElement(AntiBen, {
  2829. onClick: () => window.open("https://github.com/Gradyruan/Blooket-cheats", "_blank").focus(),
  2830. style: {
  2831. cursor: "pointer"
  2832. },
  2833. href: "https://github.com/Gradyruan/Blooket-cheats"
  2834. }, "GitHub - Gradyruan")), makeElement("div", {
  2835. id: styles.keys.cheatList
  2836. }, makeElement(AntiBen, {
  2837. type: "span",
  2838. style: {
  2839. textShadow: "1px 1px rgb(0 0 0 / 40%)"
  2840. }
  2841. }, "Cheats"), makeElement("a", {
  2842. href: "https://discord.gg/jHjGrrdXP6",
  2843. target: "_blank",
  2844. id: styles.keys.bigButton
  2845. }, makeElement("svg", {
  2846. style: {
  2847. filter: "drop-shadow(2px 2px 0 rgb(0 0 0 / 20%))"
  2848. },
  2849. xmlns: "http://www.w3.org/2000/svg",
  2850. width: "35",
  2851. height: "35",
  2852. fill: "currentColor",
  2853. viewBox: "0 -1 21 16"
  2854. }, makeElement("path", {
  2855. d: "M13.545 2.907a13.227 13.227 0 0 0-3.257-1.011.05.05 0 0 0-.052.025c-.141.25-.297.577-.406.833a12.19 12.19 0 0 0-3.658 0 8.258 8.258 0 0 0-.412-.833.051.051 0 0 0-.052-.025c-1.125.194-2.22.534-3.257 1.011a.041.041 0 0 0-.021.018C.356 6.024-.213 9.047.066 12.032c.001.014.01.028.021.037a13.276 13.276 0 0 0 3.995 2.02.05.05 0 0 0 .056-.019c.308-.42.582-.863.818-1.329a.05.05 0 0 0-.01-.059.051.051 0 0 0-.018-.011 8.875 8.875 0 0 1-1.248-.595.05.05 0 0 1-.02-.066.051.051 0 0 1 .015-.019c.084-.063.168-.129.248-.195a.05.05 0 0 1 .051-.007c2.619 1.196 5.454 1.196 8.041 0a.052.052 0 0 1 .053.007c.08.066.164.132.248.195a.051.051 0 0 1-.004.085 8.254 8.254 0 0 1-1.249.594.05.05 0 0 0-.03.03.052.052 0 0 0 .003.041c.24.465.515.909.817 1.329a.05.05 0 0 0 .056.019 13.235 13.235 0 0 0 4.001-2.02.049.049 0 0 0 .021-.037c.334-3.451-.559-6.449-2.366-9.106a.034.034 0 0 0-.02-.019Zm-8.198 7.307c-.789 0-1.438-.724-1.438-1.612 0-.889.637-1.613 1.438-1.613.807 0 1.45.73 1.438 1.613 0 .888-.637 1.612-1.438 1.612Zm5.316 0c-.788 0-1.438-.724-1.438-1.612 0-.889.637-1.613 1.438-1.613.807 0 1.451.73 1.438 1.613 0 .888-.631 1.612-1.438 1.612Z"
  2856. })), makeElement(AntiBen, {
  2857. type: React.Fragment
  2858. }, "Discord")), gamemodes.map(gamemode => {
  2859. return makeElement("div", {
  2860. key: gamemode,
  2861. onClick: () => setCurrentMode(gamemode),
  2862. className: styles.keys.cheatButton
  2863. }, Cheats[gamemode].img ? makeElement("img", {
  2864. src: Cheats[gamemode].img,
  2865. style: {
  2866. maxWidth: "30px",
  2867. maxHeight: "30px",
  2868. aspectRatio: "1 / 1",
  2869. marginRight: "10px",
  2870. ...(Cheats[gamemode].style || {})
  2871. },
  2872. alt: gamemode
  2873. }) : makeElement("div", {
  2874. style: {
  2875. marginInline: "5px",
  2876. width: "5px"
  2877. }
  2878. }), makeElement(Textfit, {
  2879. mode: "single",
  2880. forceSingleWidthMode: false,
  2881. min: 1,
  2882. max: 20
  2883. }, Cheats[gamemode].name));
  2884. })), makeElement("div", {
  2885. id: styles.keys.contentWrapper
  2886. }, makeElement("div", {
  2887. id: styles.keys.content
  2888. }, makeElement(Tooltip, {
  2889. place: "bottom",
  2890. effect: "solid"
  2891. }), makeElement("div", {
  2892. id: styles.keys.cheats
  2893. }, Cheats[currentMode].element || (Cheats[currentMode].element = makeElement(React.Fragment, null, makeElement("div", {
  2894. className: styles.keys.headerText
  2895. }, makeElement(AntiBen, null, Cheats[currentMode].name, " Cheats")), Cheats[currentMode].cheats.map(cheat => cheat.element || makeElement(ScriptButton, {
  2896. key: cheat.name + cheat.type,
  2897. script: cheat
  2898. }))))))))));
  2899. }
  2900. console.log(JSX.jsx(GUI, {}))
  2901. ReactDOM.render(JSX.jsx(GUI, {}), GUIContainer);
  2902. document.body.append(GUIContainer);
  2903. });
  2904. let img = new Image;
  2905. img.src = "https://raw.githubusercontent.com/Gradyruan/Blooket-cheats/main/autoupdate/timestamps/reactGui.png?" + Date.now();
  2906. img.crossOrigin = "Anonymous";
  2907. img.onload = function() {
  2908. const c = document.createElement("canvas");
  2909. const ctx = c.getContext("2d");
  2910. ctx.drawImage(img, 0, 0, this.width, this.height);
  2911. let { data } = ctx.getImageData(0, 0, this.width, this.height), decode = "", last;
  2912. let i = 0;
  2913. while (i < data.length) {
  2914. let char = String.fromCharCode(data[i % 4 == 3 ? (i++, i++) : i++] + data[i % 4 == 3 ? (i++, i++) : i++] * 256);
  2915. decode += char;
  2916. if (char == "/" && last == "*") break;
  2917. last = char;
  2918. }
  2919. let _, time = 1716839383820, error = "There was an error checking for script updates. Run cheat anyway?";
  2920. try {
  2921. [_, time, error] = decode.match(/LastUpdated: (.+?); ErrorMessage: "((.|\n)+?)"/);
  2922. } catch (e) {}
  2923. if (parseInt(time) <= 1716839383820 || iframe.contentWindow.confirm(error)) cheat();
  2924. }
  2925. img.onerror = img.onabort = () => {
  2926. img.onerror = img.onabort = null;
  2927. cheat();
  2928. let iframe = document.querySelector("iframe");
  2929. iframe.contentWindow.alert("It seems the GitHub is either blocked or down.\n\nIf it's NOT blocked, join the Discord server for updates\nhttps://discord.gg/jHjGrrdXP6\n(The cheat will still run after this alert)")
  2930. }
  2931. })();
  2932. })();