Masterix BumpyBall Client

Cheat client for Pucks.io and Bumpyball.io by Masterix

  1. // ==UserScript==
  2. // @name Masterix BumpyBall Client
  3. // @namespace http://tampermonkey.net/
  4. // @version 1.0
  5. // @description Cheat client for Pucks.io and Bumpyball.io by Masterix
  6. // @author Masterix
  7. // @match https://www.pucks.io/*
  8. // @match https://www.bumpyball.io/*
  9. // @icon https://www.google.com/s2/favicons?sz=64&domain=pucks.io
  10. // @grant none
  11. // ==/UserScript==
  12.  
  13. /*=============================================================================================================
  14. SCRIPT BY MASTERIX! #MCC
  15. If you want to change/edit my console, please contact me via Discord. Thank you!
  16. Discord ==> masterix9759
  17. Thanks for using my cheat. <3
  18. =============================================================================================================*/
  19.  
  20. // TIP: Click on the "e" key to open the cheat.
  21.  
  22. let selectedCar;
  23. let usernamearray=[];
  24. let playername;
  25. let controlinterval, controlintervalOwn;
  26. let loaded = false;
  27.  
  28. //------------------------------------------------SERVER BROWSER------------------------------------------------//
  29.  
  30. //Amsterdam
  31. const amsterdam_01_8080 = new WebSocket('wss://amsterdam-01.usemapsettings.com:8080/server');
  32. const amsterdam_01_8081 = new WebSocket('wss://amsterdam-01.usemapsettings.com:8081/server');
  33. const amsterdam_01_8082 = new WebSocket('wss://amsterdam-01.usemapsettings.com:8082/server');
  34. const amsterdam_01_8083 = new WebSocket('wss://amsterdam-01.usemapsettings.com:8083/server');
  35. const amsterdam_01_8084 = new WebSocket('wss://amsterdam-01.usemapsettings.com:8084/server');
  36. const amsterdam_01_8085 = new WebSocket('wss://amsterdam-01.usemapsettings.com:8085/server');
  37. const practice_amsterdam_01_8086 = new WebSocket('wss://amsterdam-01.usemapsettings.com:8086/server');
  38. const practice_amsterdam_01_8087 = new WebSocket('wss://amsterdam-01.usemapsettings.com:8087/server');
  39.  
  40. //Frankfurt
  41. const frankfurt_01_8080 = new WebSocket('wss://frankfurt-01.usemapsettings.com:8080/server');
  42. const frankfurt_01_8081 = new WebSocket('wss://frankfurt-01.usemapsettings.com:8081/server');
  43. const frankfurt_01_8082 = new WebSocket('wss://frankfurt-01.usemapsettings.com:8082/server');
  44. const frankfurt_01_8083 = new WebSocket('wss://frankfurt-01.usemapsettings.com:8083/server');
  45. const frankfurt_01_8084 = new WebSocket('wss://frankfurt-01.usemapsettings.com:8084/server');
  46. const frankfurt_01_8085 = new WebSocket('wss://frankfurt-01.usemapsettings.com:8085/server');
  47. const practice_frankfurt_01_8086 = new WebSocket('wss://frankfurt-01.usemapsettings.com:8086/server');
  48. const practice_frankfurt_01_8087 = new WebSocket('wss://frankfurt-01.usemapsettings.com:8087/server');
  49.  
  50. //New York City
  51. const newyorkcity_02_8080 = new WebSocket('wss://newyorkcity_02.usemapsettings.com:8080/server');
  52. const newyorkcity_02_8081 = new WebSocket('wss://newyorkcity_02.usemapsettings.com:8081/server');
  53. const newyorkcity_02_8082 = new WebSocket('wss://newyorkcity_02.usemapsettings.com:8082/server');
  54. const newyorkcity_02_8083 = new WebSocket('wss://newyorkcity_02.usemapsettings.com:8083/server');
  55. const newyorkcity_02_8084 = new WebSocket('wss://newyorkcity_02.usemapsettings.com:8084/server');
  56. const newyorkcity_02_8085 = new WebSocket('wss://newyorkcity_02.usemapsettings.com:8085/server');
  57. const practice_newyorkcity_02_8086 = new WebSocket('wss://newyorkcity_02.usemapsettings.com:8086/server');
  58. const practice_newyorkcity_02_8087 = new WebSocket('wss://newyorkcity_02.usemapsettings.com:8087/server');
  59. const practice_newyorkcity_02_8088 = new WebSocket('wss://newyorkcity_02.usemapsettings.com:8088/server');
  60. const practice_newyorkcity_02_8089 = new WebSocket('wss://newyorkcity_02.usemapsettings.com:8089/server');
  61.  
  62. //San Francisco
  63. const sanfrancisco_01_8080 = new WebSocket('wss://sanfrancisco-01.usemapsettings.com:8080/server');
  64. const sanfrancisco_01_8081 = new WebSocket('wss://sanfrancisco-01.usemapsettings.com:8081/server');
  65. const sanfrancisco_01_8082 = new WebSocket('wss://sanfrancisco-01.usemapsettings.com:8082/server');
  66. const sanfrancisco_01_8083 = new WebSocket('wss://sanfrancisco-01.usemapsettings.com:8083/server');
  67. const sanfrancisco_01_8084 = new WebSocket('wss://sanfrancisco-01.usemapsettings.com:8084/server');
  68. const sanfrancisco_01_8085 = new WebSocket('wss://sanfrancisco-01.usemapsettings.com:8085/server');
  69. const practice_sanfrancisco_01_8086 = new WebSocket('wss://sanfrancisco-01.usemapsettings.com:8086/server');
  70. const practice_sanfrancisco_01_8087 = new WebSocket('wss://sanfrancisco-01.usemapsettings.com:8087/server');
  71.  
  72. //Singapore
  73. const singapore_01_8080 = new WebSocket('wss://singapore-01.usemapsettings.com:8080/server');
  74. const singapore_01_8081 = new WebSocket('wss://singapore-01.usemapsettings.com:8081/server');
  75. const singapore_01_8082 = new WebSocket('wss://singapore-01.usemapsettings.com:8082/server');
  76. const singapore_01_8083 = new WebSocket('wss://singapore-01.usemapsettings.com:8083/server');
  77. const singapore_01_8084 = new WebSocket('wss://singapore-01.usemapsettings.com:8084/server');
  78. const singapore_01_8085 = new WebSocket('wss://singapore-01.usemapsettings.com:8085/server');
  79. const practice_singapore_01_8086 = new WebSocket('wss://singapore-01.usemapsettings.com:8086/server');
  80. const practice_singapore_01_8087 = new WebSocket('wss://singapore-01.usemapsettings.com:8087/server');
  81.  
  82. //--------------------------------------------------------------------------------------------------------------//
  83.  
  84. const client = {};
  85.  
  86. (function() {
  87. let alert = '%cCONSOLE LAUNCHED';
  88. let color = 'color:red;';
  89. let size = 'font-size:20px;';
  90. console.warn(alert,color+size);
  91. console.warn(alert,color+size);
  92. console.warn(alert,color+size);
  93.  
  94. const originalWebSocket = window.WebSocket;
  95. window.WebSocket = function(...args) {
  96. const ws = new originalWebSocket(...args);
  97. const originalSend = ws.send;
  98. const originalOnMessage = ws.onmessage;
  99. client.ws = ws;
  100.  
  101. ws.send = function(data) {
  102. if (data instanceof ArrayBuffer) {
  103. const uint8Array = new Uint8Array(data);
  104. //console.log("Data:",data);
  105. const decoder = new TextDecoder();
  106. if(loaded == false){
  107. loaded = true;
  108. const usernameStartIndex = 6;
  109. let usernameEndIndex = usernameStartIndex;
  110. while (usernameEndIndex < uint8Array.length && uint8Array[usernameEndIndex] >= 32 && uint8Array[usernameEndIndex] <= 126) {
  111. usernameEndIndex++;
  112. }
  113. console.log('===============================================');
  114. console.log(ws);
  115. const usernameArray = uint8Array.slice(usernameStartIndex, usernameEndIndex);
  116. usernamearray=Array.from(usernameArray);
  117. const getUser = decoder.decode(usernameArray).trim().replace(/[^\x20-\x7E]/g, '');
  118. console.log('Logged User:', getUser);
  119. playername = getUser;
  120. ConsoleLoaded(getUser);
  121. }
  122. //console.log('Message Data:', uint8Array);
  123. //select car
  124. if(selectedCar==0){
  125. var car0 = [8, 1, 18, 47, 10, usernamearray.length, ...usernamearray, 18, 28, 109, 53, 120, 117, 114, 120, 100, 65, 49, 71, 90, 85, 71, 104, 50, 82, 112, 50, 78, 70, 79, 84, 73, 82, 90, 110, 106, 49, 24, 230, 6, 32, 0, 56, 1];
  126. originalSend.call(this, new Uint8Array(car0));
  127. gameInstance.SendMessage('NetworkLayer','SetSkin', selectedCar);
  128. }
  129. if (selectedCar == 1) {
  130. var car1 = [8, 1, 18, 47, 10, usernamearray.length, ...usernamearray, 18, 28, 109, 53, 120, 117, 114, 120, 100, 65, 49, 71, 90, 85, 71, 104, 50, 82, 112, 50, 78, 70, 79, 84, 73, 82, 90, 110, 106, 49, 24, 230, 6, 32, 1, 56, 1];
  131. originalSend.call(this, new Uint8Array(car1));
  132. gameInstance.SendMessage('NetworkLayer','SetSkin', selectedCar);
  133. }
  134. if (selectedCar == 2) {
  135. var car2 = [8, 1, 18, 47, 10, usernamearray.length,...usernamearray, 18, 28, 109, 53, 120, 117, 114, 120, 100, 65, 49, 71, 90, 85, 71, 104, 50, 82, 112, 50, 78, 70, 79, 84, 73, 82, 90, 110, 106, 49, 24, 230, 6, 32, 2, 56, 1];
  136. originalSend.call(this, new Uint8Array(car2));
  137. gameInstance.SendMessage('NetworkLayer','SetSkin', selectedCar);
  138. }
  139. if (selectedCar == 3) {
  140. var car3 = [8, 1, 18, 47, 10, usernamearray.length, ...usernamearray, 18, 28, 109, 53, 120, 117, 114, 120, 100, 65, 49, 71, 90, 85, 71, 104, 50, 82, 112, 50, 78, 70, 79, 84, 73, 82, 90, 110, 106, 49, 24, 230, 6, 32, 3, 56, 1];
  141. originalSend.call(this, new Uint8Array(car3));
  142. gameInstance.SendMessage('NetworkLayer','SetSkin', selectedCar);
  143. }
  144. if (selectedCar == 4) {
  145. var car4 = [8, 1, 18, 47, 10, usernamearray.length, ...usernamearray, 18, 28, 109, 53, 120, 117, 114, 120, 100, 65, 49, 71, 90, 85, 71, 104, 50, 82, 112, 50, 78, 70, 79, 84, 73, 82, 90, 110, 106, 49, 24, 230, 6, 32, 4, 56, 1];
  146. originalSend.call(this, new Uint8Array(car4));
  147. gameInstance.SendMessage('NetworkLayer','SetSkin', selectedCar);
  148. }
  149. if (selectedCar == 5) {
  150. var car5 = [8, 1, 18, 47, 10, usernamearray.length, ...usernamearray, 18, 28, 109, 53, 120, 117, 114, 120, 100, 65, 49, 71, 90, 85, 71, 104, 50, 82, 112, 50, 78, 70, 79, 84, 73, 82, 90, 110, 106, 49, 24, 230, 6, 32, 5, 56, 1];
  151. originalSend.call(this, new Uint8Array(car5));
  152. gameInstance.SendMessage('NetworkLayer','SetSkin', selectedCar);
  153. }
  154. if (selectedCar == 6) {
  155. var car6 = [8, 1, 18, 47, 10, usernamearray.length, ...usernamearray, 18, 28, 109, 53, 120, 117, 114, 120, 100, 65, 49, 71, 90, 85, 71, 104, 50, 82, 112, 50, 78, 70, 79, 84, 73, 82, 90, 110, 106, 49, 24, 230, 6, 32, 6, 56, 1];
  156. originalSend.call(this, new Uint8Array(car6));
  157. gameInstance.SendMessage('NetworkLayer','SetSkin', selectedCar);
  158. }
  159. if (selectedCar == 7) {
  160. var car7 = [8, 1, 18, 47, 10, usernamearray.length,...usernamearray, 18, 28, 109, 53, 120, 117, 114, 120, 100, 65, 49, 71, 90, 85, 71, 104, 50, 82, 112, 50, 78, 70, 79, 84, 73, 82, 90, 110, 106, 49, 24, 230, 6, 32, 7, 56, 1];
  161. originalSend.call(this, new Uint8Array(car7));
  162. gameInstance.SendMessage('NetworkLayer','SetSkin', selectedCar);
  163. }
  164. if (selectedCar == 8) {
  165. var car8 = [8, 1, 18, 47, 10, usernamearray.length, ...usernamearray, 18, 28, 109, 53, 120, 117, 114, 120, 100, 65, 49, 71, 90, 85, 71, 104, 50, 82, 112, 50, 78, 70, 79, 84, 73, 82, 90, 110, 106, 49, 24, 230, 6, 32, 8, 56, 1];
  166. originalSend.call(this, new Uint8Array(car8));
  167. gameInstance.SendMessage('NetworkLayer','SetSkin', selectedCar);
  168. }
  169. if (selectedCar == 9) {
  170. var car9 = [8, 1, 18, 47, 10, usernamearray.length, ...usernamearray, 18, 28, 109, 53, 120, 117, 114, 120, 100, 65, 49, 71, 90, 85, 71, 104, 50, 82, 112, 50, 78, 70, 79, 84, 73, 82, 90, 110, 106, 49, 24, 230, 6, 32, 9, 56, 1];
  171. originalSend.call(this, new Uint8Array(car9));
  172. gameInstance.SendMessage('NetworkLayer','SetSkin', selectedCar);
  173. }
  174. if (selectedCar == 10) {
  175. var car10 = [8, 1, 18, 47, 10, usernamearray.length, ...usernamearray, 18, 28, 109, 53, 120, 117, 114, 120, 100, 65, 49, 71, 90, 85, 71, 104, 50, 82, 112, 50, 78, 70, 79, 84, 73, 82, 90, 110, 106, 49, 24, 230, 6, 32, 10, 56, 1];
  176. originalSend.call(this, new Uint8Array(car10));
  177. gameInstance.SendMessage('NetworkLayer','SetSkin', selectedCar);
  178. }
  179. if (selectedCar == 11) {
  180. var car11 = [8, 1, 18, 47, 10, usernamearray.length, ...usernamearray, 18, 28, 109, 53, 120, 117, 114, 120, 100, 65, 49, 71, 90, 85, 71, 104, 50, 82, 112, 50, 78, 70, 79, 84, 73, 82, 90, 110, 106, 49, 24, 230, 6, 32, 11, 56, 1];
  181. originalSend.call(this, new Uint8Array(car11));
  182. gameInstance.SendMessage('NetworkLayer','SetSkin', selectedCar);
  183. }
  184. if (selectedCar == 12) {
  185. var car12 = [8, 1, 18, 47, 10, usernamearray.length, ...usernamearray, 18, 28, 109, 53, 120, 117, 114, 120, 100, 65, 49, 71, 90, 85, 71, 104, 50, 82, 112, 50, 78, 70, 79, 84, 73, 82, 90, 110, 106, 49, 24, 230, 6, 32, 12, 56, 1];
  186. originalSend.call(this, new Uint8Array(car12));
  187. gameInstance.SendMessage('NetworkLayer','SetSkin', selectedCar);
  188. }
  189. if (selectedCar == 13) {
  190. var car13 = [8, 1, 18, 47, 10, usernamearray.length, ...usernamearray, 18, 28, 109, 53, 120, 117, 114, 120, 100, 65, 49, 71, 90, 85, 71, 104, 50, 82, 112, 50, 78, 70, 79, 84, 73, 82, 90, 110, 106, 49, 24, 230, 6, 32, 13, 56, 1];
  191. originalSend.call(this, new Uint8Array(car13));
  192. console.log("Pusher selected");
  193. gameInstance.SendMessage('NetworkLayer','SetSkin', selectedCar);
  194. }
  195. // NOT AVAILABLE
  196. // if (selectedCar == 14) {
  197. // var car14 = [8, 1, 18, 45, 10, 6, 77, 84, 88, 54, 54, 54, 18, 28, 109, 53, 120, 117, 114, 120, 100, 65, 49, 71, 90, 85, 71, 104, 50, 82, 112, 50, 78, 70, 79, 84, 73, 82, 90, 110, 106, 49, 24, 230, 6, 32, 14, 56, 1];
  198. // originalSend.call(this, new Uint8Array(car14));
  199. // }
  200.  
  201. originalSend.call(this, data);
  202. } else {
  203. console.log('Client Request:', data);
  204. originalSend.call(this, data);
  205. }
  206. };
  207.  
  208. return ws;
  209. };
  210.  
  211. document.addEventListener('keydown',e=>{
  212. switch(e.key){
  213. case'e':
  214. id('cheatwindow').style.display='block';
  215. break;
  216. }});
  217.  
  218. const cheat = top.cheat = {
  219.  
  220. unknownmessage: (name) => {
  221. var message = id('cheatinput').value;
  222. var encoder = new TextEncoder();
  223. var encodedMessage = encoder.encode(name+message);
  224. var messageLength = encodedMessage.length;
  225. var header = [8, 5, 18, messageLength + 5, 8, 223, 18, 18, messageLength];
  226. var chatArray = new Uint8Array(header.length + messageLength);
  227. chatArray.set(header);
  228. chatArray.set(encodedMessage, header.length);
  229. client.ws.send(new Uint8Array(chatArray));
  230. //}
  231. },
  232.  
  233. spambymcc: () => {
  234. //console.log('Spam by MCC');
  235. var chatarray = [8, 5, 18, 75, 8, 144, 2, 18, 70, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61,
  236. 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 83, 80, 65, 77, 32, 66, 89, 32, 35, 77, 67, 67, 61, 61, 61, 61,
  237. 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61];
  238. client.ws.send(new Uint8Array(chatarray));
  239. client.ws.send(new Uint8Array(chatarray));
  240. client.ws.send(new Uint8Array(chatarray));
  241. client.ws.send(new Uint8Array(chatarray));
  242. client.ws.send(new Uint8Array(chatarray));
  243. client.ws.send(new Uint8Array(chatarray));
  244. client.ws.send(new Uint8Array(chatarray));
  245. client.ws.send(new Uint8Array(chatarray));
  246. client.ws.send(new Uint8Array(chatarray));
  247. client.ws.send(new Uint8Array(chatarray));
  248. },
  249. clearchat: () => {
  250. var chatarray = [8, 5, 18, 9, 8, 223, 18, 18, 4, 32, 227, 133, 164];
  251. client.ws.send(new Uint8Array(chatarray));
  252. client.ws.send(new Uint8Array(chatarray));
  253. client.ws.send(new Uint8Array(chatarray));
  254. client.ws.send(new Uint8Array(chatarray));
  255. client.ws.send(new Uint8Array(chatarray));
  256. client.ws.send(new Uint8Array(chatarray));
  257. client.ws.send(new Uint8Array(chatarray));
  258. client.ws.send(new Uint8Array(chatarray));
  259. client.ws.send(new Uint8Array(chatarray));
  260. client.ws.send(new Uint8Array(chatarray));
  261. client.ws.send(new Uint8Array(chatarray));
  262. client.ws.send(new Uint8Array(chatarray));
  263. client.ws.send(new Uint8Array(chatarray));
  264. },
  265. };
  266.  
  267. //******************************************Cheat Console UI******************************************//
  268.  
  269. window.id = top.id = id => top.document.getElementById(id);
  270. window.crt = top.crt = crt => top.document.createElement(crt);
  271.  
  272. window.infobutton = top.infobutton = (name) => {
  273. let element = crt('input');
  274. element.id = 'infobutton';
  275. element.value = name;
  276. element.type = 'button';
  277. element.style = button1_CSS;
  278. element.style.color = 'lightgreen';
  279. element.style.cursor='default';
  280. id('cpage1').appendChild(element);
  281. const page = id('cpage1');
  282. page.insertBefore(element, page.firstChild); //Puts the button at the beginning
  283. };
  284.  
  285. window.noteLabel = top.noteLabel = (name, affi, al = 0) => {
  286. let element = crt('label');
  287. element.id = 'noteLabel';
  288. if(alert !=1){
  289. element.innerText = name;
  290. }
  291. element.style.color = '#FE2E2E';
  292. element.style.cursor='default';
  293. element.style.position='absolute';
  294. element.style.marginTop='35%';
  295. element.style.marginLeft='10px';
  296. element.style.fontSize='18px';
  297. id(affi).appendChild(element);
  298.  
  299. if (al == 1)
  300. window.alert(name);
  301. };
  302.  
  303. window.noteLabelWithAlert = top.noteLabelWithAlert = (name, altext, affi, m_top='3%', m_left='92%') => {
  304. let element = crt('label');
  305. element.id = 'noteLabel';
  306. element.innerText = name;
  307. element.style.color = 'white';
  308. element.style.cursor='default';
  309. element.style.position='absolute';
  310. element.style.marginTop=m_top;
  311. element.style.marginLeft=m_left;
  312. element.style.fontSize='18px';
  313. element.style.background='#333';
  314. element.style.borderRadius='100%';
  315. element.style.padding='1px 9px 1px 9px';
  316. element.style.cursor='pointer';
  317. id(affi).appendChild(element);
  318. element.addEventListener('click',()=>{
  319. window.alert(altext);
  320. });
  321. };
  322.  
  323. window.generalbutton = top.generalbutton = (name,func=()=>{}) => {
  324. let element = crt('input');
  325. element.id = 'generalbutton';
  326. element.value = name;
  327. element.type = 'button';
  328. element.style = button1_CSS;
  329. element.style.color = 'white';
  330. element.style.cursor='pointer';
  331. id('cpage1').appendChild(element);
  332. element.addEventListener('click', func);
  333. element.classList.add('generalbutton');
  334. };
  335.  
  336. window.player = top.player = (name, forecolor='white', func = () => {}) => {
  337. let element = crt('input');
  338. element.id = 'player';
  339. element.value = name;
  340. element.type = 'button';
  341. element.style = button1_CSS;
  342. element.style.color = forecolor;
  343. element.style.cursor = 'pointer';
  344. id('cpage4').appendChild(element);
  345.  
  346. buttonanimations(element);
  347. element.addEventListener('click', func);
  348. };
  349.  
  350. window.switchteams = top.switchteams = (name, func = () => {}) => {
  351. let element = crt('input');
  352. element.id = 'switchteams';
  353. element.value = name;
  354. element.type = 'button';
  355. element.style = button1_CSS;
  356. element.style.cursor = 'default';
  357. id('cpage5').appendChild(element);
  358.  
  359. buttonanimations(element);
  360. element.addEventListener('click', func);
  361. };
  362.  
  363. window.tabbutton = top.tabbutton = (name, Id, func=()=>{}) => {
  364. let element = crt('input');
  365. element.id = Id;
  366. element.value = name;
  367. element.type = 'button';
  368. element.style = tabs_CSS;
  369. id('leftsidebar').appendChild(element);
  370. element.addEventListener('click', func);
  371. };
  372.  
  373. window.cheatbutton1 = top.cheatbutton1 = (name, forecolor, func = () => {}) => {
  374. let element = crt('input');
  375. element.id = 'cheatbutton1';
  376. element.value = name;
  377. element.type = 'button';
  378. element.style = button1_CSS;
  379. element.style.color = forecolor;
  380. element.style.cursor = 'default';
  381. id('cpage2').appendChild(element);
  382.  
  383. buttonanimations(element);
  384. element.addEventListener('click', func);
  385. };
  386.  
  387. window.carcheat = top.carcheat = (name, func = () => {}) => {
  388. let element = crt('input');
  389. element.id = 'cheatbutton1';
  390. element.value = name;
  391. element.type = 'button';
  392. element.style = button1_CSS;
  393. element.style.color = 'white';
  394. element.style.cursor = 'default';
  395. id('cpage3').appendChild(element);
  396.  
  397. buttonanimations(element);
  398. element.addEventListener('click', func);
  399. };
  400.  
  401. window.cheatinput = top.cheatinput = () => {
  402. let element = crt('input');
  403. element.id = 'cheatinput';
  404. element.placeholder='Enter message...';
  405. element.value = name;
  406. element.style = input_CSS;
  407. id('cpage2').appendChild(element);
  408. };
  409.  
  410. function buttonanimations(elem){
  411. elem.addEventListener('mouseover', () => elem.style = button1_CSS_hover);
  412. elem.addEventListener('mouseout', () => elem.style = button1_CSS);
  413. elem.addEventListener('mousedown', () => elem.style = button1_CSS_down);
  414. elem.addEventListener('mouseup', () => elem.style = button1_CSS);
  415. }
  416.  
  417. document.addEventListener('keydown', function(event) {
  418. if (event.ctrlKey) {
  419. event.stopPropagation();
  420. event.stopImmediatePropagation();
  421. }
  422. }, true);
  423.  
  424. //---Styles---//
  425.  
  426. const cheatWindow_CSS = `
  427. display:block;
  428. background: #1a1b16;
  429. border-radius: 15px;
  430. border: 1px #646464 solid;
  431. width: 600px;
  432. height: 400px;
  433. z-index: 99999;
  434. position:absolute;
  435. top:50%;
  436. left:50%;
  437. transform: translate(-50%,-50%);
  438. box-shadow:0px 0px 5px 5px #333333;
  439. `;
  440.  
  441. const windowtitle_CSS = `
  442. height:6%;
  443. background:#161616;
  444. top:0;
  445. left:0;
  446. right:0;
  447. border-top-left-radius:15px;
  448. border-top-right-radius:15px;
  449. color:white;
  450. text-align:center;
  451. font-size:130%;
  452. padding:1%;
  453. `;
  454.  
  455. const closewindow_CSS = `
  456. height:6%;
  457. background:red;
  458. width:6%;
  459. top:0;
  460. right:0;
  461. border-top-right-radius:15px;
  462. color:white;
  463. text-align:center;
  464. font-size:20px;
  465. padding:1%;
  466. position:absolute;
  467. cursor:pointer;
  468. `;
  469.  
  470. const cpages_CSS = `
  471. display: grid;
  472. height:91%;
  473. width:435px;
  474. background:transparent;
  475. right:0;
  476. bottom:0;
  477. color:white;
  478. position:absolute;
  479. border-bottom-right-radius:15px;
  480. grid-template-columns:1fr 1fr;
  481. grid-template-rows:1fr 1fr 1fr 1fr 1fr;
  482. z-index:10;
  483. overflow-x:hidden;
  484. overflow-y:auto;
  485. `;
  486.  
  487. const aboutpage_CSS = `
  488. display: block;
  489. height:91%;
  490. width:435px;
  491. background:transparent;
  492. right:0;
  493. bottom:0;
  494. color:white;
  495. position:absolute;
  496. border-bottom-right-radius:15px;
  497. z-index:10;
  498. overflow-x:hidden;
  499. overflow-y:auto;
  500. `;
  501.  
  502. const cpages_CSS_block = `
  503. display: block;
  504. height:91%;
  505. width:435px;
  506. background:transparent;
  507. right:0;
  508. bottom:0;
  509. color:white;
  510. border-bottom-right-radius:15px;
  511. grid-template-columns:1fr 1fr;
  512. grid-template-rows:1fr 1fr 1fr 1fr 1fr;
  513. z-index:10;
  514. overflow-x:hidden;
  515. overflow-y:auto;
  516. `;
  517.  
  518. const button1_CSS = `
  519. border-radius:15px;
  520. background:#333333;
  521. border:none;
  522. height:auto;
  523. width:90%;
  524. padding:10px;
  525. margin:10px;
  526. font-size:16px;
  527. cursor:pointer;
  528. color:white;
  529. `;
  530.  
  531. const button1_CSS_hover = `
  532. border-radius:15px;
  533. background:#404040;
  534. border:none;
  535. height:auto;
  536. width:90%;
  537. padding:10px;
  538. margin:10px;
  539. font-size:16px;
  540. cursor:pointer;
  541. color:white;
  542. `;
  543.  
  544. const button1_CSS_down = `
  545. border-radius:15px;
  546. background:#282828;
  547. border:none;
  548. height:auto;
  549. width:90%;
  550. padding:10px;
  551. margin:10px;
  552. font-size:16px;
  553. cursor:pointer;
  554. color:white;
  555. `;
  556.  
  557. const input_CSS = `
  558. border-radius:15px;
  559. background:#252525;
  560. border:none;
  561. height:auto;
  562. width:180px;
  563. padding:10px;
  564. margin:10px;
  565. font-size:16px;
  566. color:white;
  567. `;
  568.  
  569. const left_sidebar = `
  570. display: grid;
  571. height:91%;
  572. width:25%;
  573. background:#111111;
  574. left:0;
  575. bottom:0;
  576. color:white;
  577. position:absolute;
  578. border-bottom-left-radius:15px;
  579. grid-template-columns:1fr;
  580. grid-template-rows:1fr 1fr 1fr 1fr 1fr 1fr;
  581. z-index:12;
  582. `;
  583. const tabs_CSS = `
  584. width:auto;
  585. background:transparent;
  586. left:0;
  587. right:0;
  588. color:white;
  589. border:none;
  590. border-bottom:1px #252525 solid;
  591. `;
  592.  
  593. const tabs_CSS_active = `
  594. width:auto;
  595. background:#222;
  596. left:0;
  597. right:0;
  598. color:white;
  599. border:none;
  600. border-bottom:1px #252525 solid;
  601. `;
  602.  
  603. const tabs_CSS_hover = `
  604. width:auto;
  605. background:#666;
  606. left:0;
  607. right:0;
  608. color:white;
  609. border:none;
  610. border-bottom:1px #252525 solid;
  611. `;
  612.  
  613. //---Content---//
  614.  
  615. const cwindow = document.createElement("div");
  616. cwindow.id = 'cheatwindow';
  617. cwindow.style = cheatWindow_CSS;
  618. cwindow.style.display='none';
  619. document.body.appendChild(cwindow);
  620.  
  621. const el = id('cheatwindow');
  622. let offsetX, offsetY;
  623.  
  624. const cwindow_title = document.createElement("div");
  625. cwindow_title.id = 'cheatwindowtitle';
  626. cwindow_title.style = windowtitle_CSS;
  627. cwindow_title.style.userSelect='none';
  628. cwindow_title.innerText = 'Masterix BumpyBall Client';
  629. id('cheatwindow').appendChild(cwindow_title);
  630. cwindow_title.addEventListener('mousedown', function(e){
  631. offsetX = e.clientX - el.offsetLeft;
  632. offsetY = e.clientY - el.offsetTop;
  633.  
  634. document.addEventListener('mouseup', stopMoving);
  635. document.addEventListener('mousemove', startMoving);
  636. });
  637.  
  638. function startMoving(e){
  639. el.style.left = e.clientX - offsetX + "px";
  640. el.style.top = e.clientY - offsetY + "px";
  641. }
  642.  
  643. function stopMoving(e){
  644. document.removeEventListener('mouseup', stopMoving);
  645. document.removeEventListener('mousemove', startMoving);
  646. }
  647.  
  648. const close_cwindow = document.createElement("div");
  649. close_cwindow.id = 'close_cwindow';
  650. close_cwindow.style = closewindow_CSS;
  651. close_cwindow.innerText = 'X';
  652. id('cheatwindowtitle').appendChild(close_cwindow);
  653. close_cwindow.addEventListener('click', () => {
  654. id('cheatwindow').style.display = 'none';
  655. });
  656.  
  657. const leftsidebar = document.createElement("div");
  658. leftsidebar.id = 'leftsidebar';
  659. leftsidebar.style = left_sidebar;
  660. id('cheatwindow').appendChild(leftsidebar);
  661.  
  662. const cpage1 = document.createElement("div");
  663. cpage1.id = 'cpage1';
  664. cpage1.style = cpages_CSS;
  665. id('cheatwindow').appendChild(cpage1);
  666.  
  667. const cpage2 = document.createElement("div");
  668. cpage2.id = 'cpage2';
  669. cpage2.style = cpages_CSS;
  670. cpage2.style.display='none';
  671. id('cheatwindow').appendChild(cpage2);
  672.  
  673. const cpage3 = document.createElement("div");
  674. cpage3.id = 'cpage3';
  675. cpage3.style = cpages_CSS;
  676. cpage3.style.display='none';
  677. id('cheatwindow').appendChild(cpage3);
  678.  
  679. const cpage4 = document.createElement("div");
  680. cpage4.id = 'cpage4';
  681. cpage4.style = cpages_CSS;
  682. cpage4.style.display='none';
  683. id('cheatwindow').appendChild(cpage4);
  684.  
  685. const cpage5 = document.createElement("div");
  686. cpage5.id = 'cpage5';
  687. cpage5.style = cpages_CSS;
  688. cpage5.style.display='none';
  689. id('cheatwindow').appendChild(cpage5);
  690.  
  691. const cpage6 = document.createElement("div");
  692. cpage6.id = 'cpage6';
  693. cpage6.style = aboutpage_CSS;
  694. cpage6.innerHTML=`
  695. <h3>About</h3>
  696.  
  697. <p> Creator: Masterix<br>
  698. Version: 1.0<br>
  699. Release date: 13th August 2024<br><br>
  700. Thanks for using my cheat client. <3
  701. </p>
  702.  
  703. <div class="aboutButtonsDIV">
  704. <button class="sm_button" onclick="javascript:window.open('https://youtube.com/@masterix9944');"><img class="sm_image" src="https://www.google.com/s2/favicons?sz=64&domain=youtube.com"></img>Masterix</button>
  705. <button class="sm_button" onclick="javascript:window.open('https://www.youtube.com/@whiztech200');"><img class="sm_image" src="https://www.google.com/s2/favicons?sz=64&domain=youtube.com"></img>WhizTech</button>
  706. <button class="sm_button" onclick="javascript:window.open('https://www.instagram.com/whiztechh/');"><img class="sm_image" src="https://www.google.com/s2/favicons?sz=64&domain=instagram.com"></img>WhizTech</button>
  707. </div>
  708.  
  709. <style>
  710. h3{
  711. text-align:center;
  712. padding-bottom:0px;
  713. }
  714. p{
  715. margin-top:-50px;
  716. }
  717. .sm_button{
  718. border-radius:15px;
  719. background:#333;
  720. border:none;
  721. color:white;
  722. height:40px;
  723. width:93%;
  724. align-items:center;
  725. justify-content: center;
  726. display:flex
  727. }
  728. .sm_image{
  729. height:20px;
  730. margin-right:10px;
  731. }
  732. .sm_button:hover{
  733. background:#444;
  734. cursor:pointer;
  735. }
  736. .aboutButtonsDIV{
  737. display:grid;
  738. margin-top:-30px;
  739. grid-template-columns:1fr 1fr;
  740. grid-template-rows:0.5fr;
  741. }
  742. </style>`;
  743. cpage6.style.display='none';
  744. id('cheatwindow').appendChild(cpage6);
  745.  
  746. //***********************************************************************************************************************//
  747.  
  748. function control(key, code, whichkeycode, delay){
  749. controlinterval = setInterval(() => {
  750. const event = new KeyboardEvent('keydown', {
  751. key: key,
  752. code: code,
  753. which: whichkeycode,
  754. keyCode: whichkeycode,
  755. bubbles: true,
  756. cancelable: true
  757. });
  758. document.dispatchEvent(event);
  759. }, delay);
  760. };
  761.  
  762. function controlOwn(key, code, whichkeycode, delay){
  763. controlintervalOwn = setInterval(() => {
  764. const event = new KeyboardEvent('keydown', {
  765. key: key,
  766. code: code,
  767. which: whichkeycode,
  768. keyCode: whichkeycode,
  769. bubbles: true,
  770. cancelable: true
  771. });
  772. document.dispatchEvent(event);
  773. }, delay);
  774. }
  775.  
  776. function KeyW_down() {
  777. const event = new KeyboardEvent('keydown', { key: 'w', code: 'KeyW', which: 87, keyCode: 87, bubbles: true, cancelable: true });
  778. document.dispatchEvent(event);
  779. }
  780.  
  781. function KeyW_up() {
  782. const event = new KeyboardEvent('keyup', { key: 'w', code: 'KeyW', which: 87, keyCode: 87, bubbles: true, cancelable: true });
  783. document.dispatchEvent(event);
  784. }
  785.  
  786. function KeyA_down() {
  787. const event = new KeyboardEvent('keydown', { key: 'a', code: 'KeyA', which: 65, keyCode: 65, bubbles: true, cancelable: true });
  788. document.dispatchEvent(event);
  789. }
  790.  
  791. function KeyA_up() {
  792. const event = new KeyboardEvent('keyup', { key: 'a', code: 'KeyA', which: 65, keyCode: 65, bubbles: true, cancelable: true });
  793. document.dispatchEvent(event);
  794. }
  795.  
  796. function KeyS_down() {
  797. const event = new KeyboardEvent('keydown', { key: 's', code: 'KeyS', which: 83, keyCode: 83, bubbles: true, cancelable: true });
  798. document.dispatchEvent(event);
  799. }
  800.  
  801. function KeyS_up() {
  802. const event = new KeyboardEvent('keyup', { key: 's', code: 'KeyS', which: 83, keyCode: 83, bubbles: true, cancelable: true });
  803. document.dispatchEvent(event);
  804. }
  805.  
  806. function KeyD_down() {
  807. const event = new KeyboardEvent('keydown', { key: 'd', code: 'KeyD', which: 68, keyCode: 68, bubbles: true, cancelable: true });
  808. document.dispatchEvent(event);
  809. }
  810.  
  811. function KeyD_up() {
  812. const event = new KeyboardEvent('keyup', { key: 'd', code: 'KeyD', which: 68, keyCode: 68, bubbles: true, cancelable: true });
  813. document.dispatchEvent(event);
  814. }
  815.  
  816. let autogascheat = crt('input');
  817. autogascheat.id = 'autogascheat';
  818. autogascheat.value = 'Auto Gas: OFF';
  819. autogascheat.type = 'button';
  820. autogascheat.style = button1_CSS;
  821. id('cpage4').appendChild(autogascheat);
  822.  
  823. buttonanimations(autogascheat);
  824. autogascheat.addEventListener('click', ()=>{
  825.  
  826. if (autogascheat.value == 'Auto Gas: OFF') {
  827. autogascheat.value = 'Auto Gas: ON';
  828. control('w', 'KeyW', 87, 0);
  829. }
  830.  
  831. else if (autogascheat.value == 'Auto Gas: ON') {
  832. clearInterval(controlinterval);
  833. KeyW_up();
  834. autogascheat.value = 'Auto Gas: OFF';
  835. }
  836. });
  837.  
  838. let startinstruction = crt('input');
  839. startinstruction.id = 'startinstruction';
  840. startinstruction.value = 'Start Set';
  841. startinstruction.type = 'button';
  842. startinstruction.style = button1_CSS;
  843. startinstruction.style.border = '1px #666 solid';
  844. id('cpage4').appendChild(startinstruction);
  845.  
  846. startinstruction.addEventListener('click', () => {
  847. let duration = id('instructiondurationinput').value;
  848. if (startinstruction.value == 'Start Set' && id('instructionlistbox').value != 0 && id('instructiondurationinput').value != 0) {
  849. startinstruction.value = 'Stop Set';
  850. var cmd = instructionlistbox.value.split('\n');
  851. for (let i = 0; i < cmd.length; i++) {
  852. setTimeout(() => {
  853. switch (cmd[i]) {
  854. case 'forward':
  855. KeyA_up();
  856. KeyD_up();
  857. KeyS_up();
  858.  
  859. KeyW_up();
  860. KeyW_down();
  861. break;
  862. case 'left':
  863. KeyW_up();
  864. KeyD_up();
  865. KeyS_up();
  866.  
  867. KeyA_up();
  868. KeyA_down();
  869. break;
  870. case 'right':
  871. KeyA_up();
  872. KeyW_up();
  873. KeyS_up();
  874.  
  875. KeyD_up();
  876. KeyD_down();
  877. break;
  878. case 'backward':
  879. KeyA_up();
  880. KeyW_up();
  881. KeyD_up();
  882.  
  883. KeyS_up();
  884. KeyS_down();
  885. break;
  886. case 'stop':
  887. KeyA_up();
  888. KeyW_up();
  889. KeyD_up();
  890. KeyS_up();
  891. break;
  892. }
  893. }, (i+1) * duration);
  894. }
  895. } else if (startinstruction.value == 'Stop Set') {
  896. KeyA_up();
  897. KeyW_up();
  898. KeyD_up();
  899. KeyS_up();
  900. startinstruction.value = 'Start Set';
  901. }
  902.  
  903. else {
  904. window.alert("Please provide a value in the input fields.");
  905. startinstruction.value = 'Start Set';
  906. }
  907. });
  908.  
  909. let instructionlabel = crt('label');
  910. instructionlabel.innerText='Instruction Set';
  911. instructionlabel.style.gridColumn='span 2';
  912. instructionlabel.style.marginTop='15px';
  913. instructionlabel.style.marginLeft='15px';
  914. id('cpage4').appendChild(instructionlabel);
  915.  
  916. let instructiondurationinput = crt('input');
  917. instructiondurationinput.id='instructiondurationinput';
  918. instructiondurationinput.innerText='Instruction Set';
  919. instructiondurationinput.style = input_CSS;
  920. instructiondurationinput.style.gridColumn='span 2';
  921. instructiondurationinput.style.marginTop='12.5%';
  922. instructiondurationinput.style.marginLeft='210px';
  923. instructiondurationinput.style.position='fixed';
  924. instructiondurationinput.style.height='15px';
  925. instructiondurationinput.placeholder='Set duration (in ms) ...';
  926. id('cpage4').appendChild(instructiondurationinput);
  927.  
  928. let instructionlistbox = crt('textarea');
  929. instructionlistbox.id='instructionlistbox';
  930. instructionlistbox.type='textarea';
  931. instructionlistbox.style=input_CSS;
  932. instructionlistbox.style.marginTop='-30px';
  933. instructionlistbox.placeholder=`Example:\nforward\nleft\nstop\nbackward\nright\n...`;
  934. instructionlistbox.style.resize='none';
  935. instructionlistbox.style.height='200px';
  936. instructionlistbox.style.width='380px';
  937. instructionlistbox.style.fontSize='16px';
  938. instructionlistbox.style.gridColumn='span 2';
  939. instructionlistbox.style.gridRow='span 3';
  940. id('cpage4').appendChild(instructionlistbox);
  941.  
  942. noteLabelWithAlert('i', 'Five commands can be specified in an instruction set.\nThey are as follows:\n'+
  943. 'forward\nbackward\nleft\nright\nstop\n\n'+
  944. 'In the text field for set duration, a number in milliseconds must be entered for how long a command should be executed.\nFor example, the car moves forward for 5 seconds (5000 ms).\n\n'+
  945. 'The syntax is kept simple, one command per line (example is displayed in the text field).', 'cpage4', '19%', '40%');
  946.  
  947. //*******************************************************************************************************************************************//
  948.  
  949. const teamblue = [8, 5, 18, 15, 8, 223, 18, 18, 10, 47, 116, 101, 97, 109, 32, 98, 108, 117, 101];
  950. const teamred = [8, 5, 18, 13, 8, 6, 18, 9, 47, 116, 101, 97, 109, 32, 114, 101, 100];
  951. const teamspect = [8, 5, 18, 20, 8, 223, 18, 18, 15, 47, 116, 101, 97, 109, 32, 115, 112, 101, 99, 116, 97, 116, 111, 114];
  952.  
  953. switchteams('Team Blue',()=>{
  954. client.ws.send(new Uint8Array(teamblue));
  955. });
  956.  
  957. switchteams('Team Red',()=>{
  958. client.ws.send(new Uint8Array(teamred));
  959. });
  960.  
  961. switchteams('Team Spectator',()=>{
  962. client.ws.send(new Uint8Array(teamspect));
  963. });
  964.  
  965. let autoteambutton = crt('input');
  966. autoteambutton.id = 'autoteambutton';
  967. autoteambutton.value = 'Team Switch: OFF';
  968. autoteambutton.type = 'button';
  969. autoteambutton.style = button1_CSS;
  970. autoteambutton.style.color = 'white';
  971. autoteambutton.style.cursor = 'default';
  972. id('cpage5').appendChild(autoteambutton);
  973. buttonanimations(autoteambutton);
  974. let autoteaminterval;
  975. autoteambutton.addEventListener('click', ()=>{
  976. if(autoteambutton.value =='Team Switch: OFF'){
  977. let switchFlag = true;
  978. autoteambutton.value ='Team Switch: ON';
  979. autoteaminterval = setInterval(() => {
  980. if (switchFlag) {
  981. client.ws.send(new Uint8Array(teamblue));
  982. } else {
  983. client.ws.send(new Uint8Array(teamred));
  984. }
  985. switchFlag = !switchFlag;
  986. }, 150);
  987. }else if(autoteambutton.value =='Team Switch: ON'){
  988. autoteambutton.value ='Team Switch: OFF'
  989. clearInterval(autoteaminterval);
  990. }
  991. });
  992. noteLabel('Only works in practice servers.','cpage5',0);
  993.  
  994. //***********************************************************************************************************************//
  995.  
  996. generalbutton('Quit Game',()=>{
  997. gameInstance.Quit();
  998. });
  999. generalbutton('Sign Out',()=>{
  1000. firebase.auth().signOut();
  1001. });
  1002. generalbutton('Change Player Name',()=>{
  1003. var playername = prompt('Change player name:');
  1004. gameInstance.SendMessage('GameCanvas', 'SetPlayerNameExternal', playername );
  1005. });
  1006. cheatinput();
  1007.  
  1008. let checkboxname = crt('input');
  1009. checkboxname.id='checkbox';
  1010. checkboxname.type='checkbox';
  1011. checkboxname.name='checkbox';
  1012. checkboxname.style.height='20px';
  1013. checkboxname.style.marginLeft = '-170px';
  1014. let chklabel = crt('label');
  1015. chklabel.htmlFor = 'checkbox';
  1016. chklabel.innerText = 'Send With Name';
  1017. chklabel.style.marginTop = '5px';
  1018. chklabel.style.marginLeft = '-180px';
  1019. cheatbutton1('Send Message', 'white', () => {
  1020. if (checkboxname.checked){cheat.unknownmessage(playername+": ");}
  1021. else{cheat.unknownmessage('');}
  1022. });
  1023. id('cpage2').appendChild(checkboxname);
  1024. id('cpage2').appendChild(chklabel);
  1025. cheatbutton1('SPAM BY #MCC', 'white', () => {cheat.spambymcc();});
  1026. cheatbutton1('Clear Chat', 'white', () => {cheat.clearchat();});
  1027.  
  1028. noteLabelWithAlert('i', 'Choose a car before you join a server!\n\nSometimes selected vehicles are not taken over and you only get the standard vehicle (default).\nRejoining a few times or reloading the game often helps.','cpage3');
  1029. const selectedcarLabel = document.createElement("label");
  1030. selectedcarLabel.id = 'selectedcarLabel';
  1031. selectedcarLabel.innerText='Selected Vehicle:';
  1032. selectedcarLabel.style.margin='13px';
  1033. selectedcarLabel.style.fontSize='18px';
  1034. selectedcarLabel.style.gridColumn = 'span 2';
  1035. id('cpage3').appendChild(selectedcarLabel);
  1036.  
  1037. carcheat('Standard',()=>{
  1038. selectedCar=0;
  1039. selectedcarLabel.innerText='Selected Vehicle: Standard';
  1040. });
  1041.  
  1042. carcheat('Cruiser',()=>{
  1043. selectedCar=1;
  1044. selectedcarLabel.innerText='Selected Vehicle: Cruiser';
  1045. });
  1046.  
  1047. carcheat('Tricked Out',()=>{
  1048. selectedCar=2;
  1049. selectedcarLabel.innerText='Selected Vehicle: Tricked Out';
  1050. });
  1051.  
  1052. carcheat('Bugged Out',()=>{
  1053. selectedCar=3;
  1054. selectedcarLabel.innerText='Selected Vehicle: Bugged Out';
  1055. });
  1056. carcheat('Taxi Cab',()=>{
  1057. selectedCar=4;
  1058. selectedcarLabel.innerText='Selected Vehicle: Taxi Cab';
  1059. });
  1060.  
  1061. carcheat('Hot Rod',()=>{
  1062. selectedCar=5;
  1063. selectedcarLabel.innerText='Selected Vehicle: Hot Rod';
  1064. });
  1065.  
  1066. carcheat('Drag Racer',()=>{
  1067. selectedCar=6;
  1068. selectedcarLabel.innerText='Selected Vehicle: Drag Racer';
  1069. });
  1070.  
  1071. carcheat('Classic',()=>{
  1072. selectedCar=7;
  1073. selectedcarLabel.innerText='Selected Vehicle: Classic';
  1074. });
  1075.  
  1076. carcheat('Soccer Van',()=>{
  1077. selectedCar=8;
  1078. selectedcarLabel.innerText='Selected Vehicle: Soccer Van';
  1079. });
  1080.  
  1081. carcheat('Cement Mixer',()=>{
  1082. selectedCar=9;
  1083. selectedcarLabel.innerText='Selected Vehicle: Cement Mixer';
  1084. });
  1085.  
  1086. carcheat('Apocalypse',()=>{
  1087. selectedCar=10;
  1088. selectedcarLabel.innerText='Selected Vehicle: Apocalypse';
  1089. });
  1090.  
  1091. carcheat('Dump Truck',()=>{
  1092. selectedCar=11;
  1093. selectedcarLabel.innerText='Selected Vehicle: Dump Truck';
  1094. });
  1095.  
  1096. carcheat('Steam Roller',()=>{
  1097. selectedCar=12;
  1098. selectedcarLabel.innerText='Selected Vehicle: Steam Roller';
  1099. });
  1100.  
  1101. carcheat('Pusher',()=>{
  1102. selectedCar=13;
  1103. selectedcarLabel.innerText='Selected Vehicle: Pusher';
  1104. });
  1105.  
  1106. tabbutton('General', 'genTab',()=>{
  1107. cpage1_open();
  1108. });
  1109. tabbutton('Player', 'playerTab',()=>{
  1110. cpage4_open();
  1111. });
  1112. tabbutton('Teams', 'teamsTab',()=>{
  1113. cpage5_open();
  1114. });
  1115. tabbutton('Game Chat', 'gchatTab',()=>{
  1116. cpage2_open();
  1117. });
  1118. tabbutton('Unlock Vehicles', 'uvehiclesTab',()=>{
  1119. cpage3_open();
  1120. });
  1121. tabbutton('About', 'aboutTab',()=>{
  1122. cpage6_open();
  1123. });
  1124.  
  1125. function ConsoleLoaded(user){
  1126. infobutton('User: '+user);
  1127. }
  1128.  
  1129. function cpage1_open(){
  1130. id('genTab').style=tabs_CSS_active;
  1131. cpage1.style.display='grid'; //open
  1132.  
  1133. var tabs =[id('playerTab'), id('teamsTab'), id('gchatTab'), id('uvehiclesTab'), id('aboutTab')];
  1134. var pages =[cpage2,cpage3,cpage4,cpage5,cpage6];
  1135.  
  1136. tabs.forEach(tab =>{tab.style=tabs_CSS;});
  1137. id('aboutTab').style.borderBottomLeftRadius='15px';
  1138. pages.forEach(page =>{page.style.display='none';});
  1139.  
  1140. }
  1141.  
  1142. function cpage2_open(){
  1143. id('gchatTab').style=tabs_CSS_active;
  1144. cpage2.style.display='grid'; //open
  1145.  
  1146. var tabs =[id('genTab'), id('playerTab'), id('teamsTab'), id('uvehiclesTab'), id('aboutTab')];
  1147. var pages =[cpage1,cpage3,cpage4,cpage5,cpage6];
  1148.  
  1149. tabs.forEach(tab =>{tab.style=tabs_CSS;});
  1150. id('aboutTab').style.borderBottomLeftRadius='15px';
  1151. pages.forEach(page =>{page.style.display='none';});
  1152. }
  1153.  
  1154. function cpage3_open(){
  1155. id('uvehiclesTab').style=tabs_CSS_active;
  1156. cpage3.style.display='grid'; //open
  1157.  
  1158. var tabs =[id('genTab'), id('playerTab'), id('teamsTab'), id('gchatTab'), id('aboutTab')];
  1159. var pages =[cpage1,cpage2,cpage4,cpage5,cpage6];
  1160.  
  1161. tabs.forEach(tab =>{tab.style=tabs_CSS;});
  1162. id('aboutTab').style.borderBottomLeftRadius='15px';
  1163. pages.forEach(page =>{page.style.display='none';});
  1164. }
  1165.  
  1166. function cpage4_open(){
  1167. id('playerTab').style=tabs_CSS_active;
  1168. cpage4.style.display='grid'; //open
  1169.  
  1170. var tabs =[id('genTab'), id('uvehiclesTab'), id('teamsTab'), id('gchatTab'), id('aboutTab')];
  1171. var pages =[cpage1,cpage2,cpage3,cpage5,cpage6];
  1172.  
  1173. tabs.forEach(tab =>{tab.style=tabs_CSS;});
  1174. id('aboutTab').style.borderBottomLeftRadius='15px';
  1175. pages.forEach(page =>{page.style.display='none';});
  1176. }
  1177.  
  1178. function cpage5_open(){
  1179. id('teamsTab').style=tabs_CSS_active;
  1180. cpage5.style.display='grid'; //open
  1181.  
  1182. var tabs =[id('genTab'), id('uvehiclesTab'), id('playerTab'), id('gchatTab'), id('aboutTab')];
  1183. var pages =[cpage1,cpage2,cpage3,cpage4,cpage6];
  1184.  
  1185. tabs.forEach(tab =>{tab.style=tabs_CSS;});
  1186. id('aboutTab').style.borderBottomLeftRadius='15px';
  1187. pages.forEach(page =>{page.style.display='none';});
  1188. }
  1189.  
  1190. function cpage6_open(){
  1191. id('aboutTab').style=tabs_CSS_active;
  1192. id('aboutTab').style.borderBottomLeftRadius='15px';
  1193. cpage6.style.display='grid'; //open
  1194.  
  1195. var tabs =[id('genTab'), id('uvehiclesTab'), id('playerTab'), id('gchatTab'), id('teamsTab')];
  1196. var pages =[cpage1,cpage2,cpage3,cpage4,cpage5];
  1197.  
  1198. tabs.forEach(tab =>{tab.style=tabs_CSS;});
  1199. pages.forEach(page =>{page.style.display='none';});
  1200. }
  1201.  
  1202. //**********************OTHER STYLE INITS**********************//
  1203.  
  1204. id('aboutTab').style.borderBottomLeftRadius='15px';
  1205. })();
  1206.  
  1207.  
  1208.  
  1209.  
  1210.  
  1211.  
  1212.  
  1213.  
  1214.  
  1215.  
  1216.  
  1217.  

QingJ © 2025

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