Auto Typer for Nitro Type

Auto Typer for Nitro Type by Sing Developments. Enjoy!

  1. // ==UserScript==
  2. // @name Auto Typer for Nitro Type
  3. // @match https://www.nitrotype.com/race
  4. // @match https://www.nitrotype.com/race/*
  5. // @author Sing Developments
  6. // @grant none
  7. // @description Auto Typer for Nitro Type by Sing Developments. Enjoy!
  8. // @license MIT
  9. // @version 7
  10. // @namespace singdev.free.nf
  11. // @icon https://static.wixstatic.com/media/3bccf5_ab8963d996264eb5921e535431b03830~mv2.png
  12. // ==/UserScript==
  13.  
  14. (function() {
  15. 'use strict';
  16.  
  17. setTimeout(function() {
  18. document.querySelectorAll('.structure--nitrotype .race-host-controls .btn')[2].click();
  19. }, 1500);
  20.  
  21. const findReact = (dom, traverseUp = 0) => {
  22. const key = Object.keys(dom).find((key) => key.startsWith("__reactFiber$"))
  23. const domFiber = dom[key]
  24. if (domFiber == null) return null
  25. const getCompFiber = (fiber) => {
  26. let parentFiber = fiber?.return
  27. while (typeof parentFiber?.type == "string") {
  28. parentFiber = parentFiber?.return
  29. }
  30. return parentFiber
  31. }
  32. let compFiber = getCompFiber(domFiber)
  33. for (let i = 0; i > traverseUp && compFiber; i++) {
  34. compFiber = getCompFiber(compFiber)
  35. }
  36. return compFiber?.stateNode
  37. }
  38.  
  39. var token = 0
  40. var t = 0
  41. // Modify typedStats to set the typed value to a large number
  42. setInterval(function() {
  43. const raceContainer = document.querySelector('.race-container');
  44. if (raceContainer) {
  45. const reactInstance = findReact(raceContainer);
  46. if (reactInstance && reactInstance.typedStats) {
  47. reactInstance.typedStats.typed = 10000000000000;
  48. }
  49. }
  50. }, 1000);
  51.  
  52. })();