Advertisement
rdsedmundo

[API] play.typeracer.com auto-type - @v1

Mar 30th, 2013
5,946
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. /*
  2. * play.typeracer.com - cheat
  3.  **** @@v1 - 30/03/13
  4. * by kyl3 (www.pastebin.com/u/kyl3)
  5.  
  6.          Hotkeys:
  7.          - Press E for auto-type the next word and auto-send.
  8.          - Press I for automatic call the Hotkey above by X seconds.
  9. */
  10.  
  11. ob_Start = (function () {
  12.         (window.Set = (function (w) {
  13.                 jQuery('.txtInput')
  14.                         .val(w)
  15.                         .focus()
  16.                         .trigger({
  17.                         type: 'keyup',
  18.                         which: 32
  19.                 });
  20.         }))
  21.  
  22.         (window.Hack = (function () {
  23.                 var wId = jQuery('html')
  24.                         .html()
  25.                         .match(/id="nhwMiddlegwt-uid-(.*?)"/gi)[0].split('-')[2].replace(/"/, ""),
  26.                         Word = jQuery('#nhwMiddlegwt-uid-' + wId)
  27.                                 .html();
  28.                 Set(Word);
  29.                 if (jQuery('.txtInput')
  30.                         .hasClass('txtInput-error')) Set(Word += ",");
  31.         }));
  32.  
  33.         jQuery(function () {
  34.                 jQuery.noConflict();
  35.  
  36.                 jQuery(document)
  37.                         .keydown(function (k) {
  38.  
  39.                         if (k.keyCode == 69) {
  40.                                 Hack();
  41.                                 return !1;
  42.                         }
  43.  
  44.                         if (k.keyCode == 73) {
  45.                                 window.D = window.setInterval(function () {
  46.                                         Hack();
  47.                                 }, prompt("Delay (in seconds)", "") * 1000);
  48.                                 return !1;
  49.                         }
  50.                 });
  51.         });
  52.  
  53. });
  54.  
  55. if (!("jQuery" in window)) {
  56.         console.info("jQuery ($) not defined");
  57.         var k = document,
  58.                 c = k.createElement('script'),
  59.                 ref = k.getElementsByTagName('script')[0];
  60.         c.type = "text/javascript";
  61.         c.src = "http://code.jquery.com/jquery-1.9.1.min.js";
  62.         c.onload = function () {
  63.                 console.warn("jQuery ($) defined");
  64.                 ob_Start();
  65.         }
  66.         ref.parentNode.insertBefore(c, ref);
  67. }
  68. else {
  69.         ob_Start();
  70. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement