Hacker Experience Utils

Remover MSG HE2; Auto BTC Compras; Auto Log Edit;

  1. // ==UserScript==
  2. // @name Hacker Experience Utils
  3. // @namespace https://greatest.deepsurf.us/en/users/52481-gusd-nide
  4. // @version 1.1
  5. // @description Remover MSG HE2; Auto BTC Compras; Auto Log Edit;
  6. // @match http://*.hackerexperience.com/*
  7. // @match http://hackerexperience.com/*
  8. // @match https://*.hackerexperience.com/*
  9. // @match https://hackerexperience.com/*
  10. // @grant GM_setValue
  11. // @grant GM_getValue
  12. // @grant GM_addStyle
  13. // @author gusdnide
  14. // ==/UserScript==
  15. var Usuario_Conta = ""//Escreva o id da sua conta aqui
  16. var Usuario_IP = GM_getValue("bot_userip", "");
  17. var Bot_btcPreco = GM_getValue("bot_btcpreco", "");
  18. var Usuario_Dinheiro = GM_getValue("bot_userdin", "");
  19. var SuaAssinatura = `
  20. ──────────────── ────██
  21. ────────────────────█─░█
  22. ────────────────────█───█
  23. ────────────────────█───█
  24. ────────────────────█───█
  25. ────────────────────█───█
  26. ────────────────────█───█▓
  27. ────────────────────█───▓█
  28. ────────────────────█───░█
  29. ────────────────────█───░█
  30. ────────────────────█░░░─█
  31. ─────────────▓███──██▓▓███
  32. ─────────────██──▓██▓────██
  33. ─────────────█▓────█▓─────▓█
  34. ─────────────█▓─────█──────░█
  35. ████████─────█▓─────█────────█
  36. ██████████▓███░──────█──█▓────█
  37. ██░░░░░░██───────────█░███────█▓
  38. ▓████████─────────────█▓██────██
  39. █████████░────────────────────▓█
  40. ▓████████░────────────────────░█
  41. ▓████████░────────────────────▓█
  42. ▓████████░────────────────────█▓
  43. ▓████████░────────────────────█
  44. ▓████████░───────────────────██
  45. ▓█████░██░──────────────────█
  46. ▓█████──████████████████████
  47. █████████
  48. by gusdzika
  49. `;
  50. if (window.self !== window.top) return;
  51.  
  52. Array.prototype.contains = function(s) {
  53. return this.indexOf(s) !== -1;
  54. };
  55. String.prototype.contains = function(it) {
  56. return this.indexOf(it) != -1;
  57. };
  58.  
  59. function InGame() {
  60. if (document.getElementById("login-form") === null) {
  61. return true;
  62. } else {
  63. return false;
  64. }
  65. }
  66.  
  67. var node = document.getElementById("he2");
  68. if (node !== undefined) {
  69. node.remove();
  70. }
  71.  
  72.  
  73.  
  74. function MandarRequest(Metodo, Pagina, Parametros, Retorno, XmlAdc) {
  75. var xmlhttp = new XMLHttpRequest();
  76. var Resultado = "";
  77. xmlhttp.onreadystatechange = function() {
  78. if (xmlhttp.readyState == 4 && xmlhttp.status == 200) {
  79. Resultado = xmlhttp.responseText;
  80. }
  81. };
  82. if (Metodo === "POST") {
  83. xmlhttp.open(Metodo, Pagina, Retorno);
  84. } else {
  85. xmlhttp.open(Metodo, Pagina + Parametros, Retorno);
  86. }
  87.  
  88. xmlhttp.setRequestHeader("Content-type", "application/x-www-form-urlencoded; charset=UTF-8");
  89. xmlhttp.setRequestHeader("Accept", "*/*");
  90. if (XmlAdc) {
  91. xmlhttp.setRequestHeader("X-Requested-With", "XMLHttpRequest");
  92. }
  93. if (Metodo === "POST") {
  94. xmlhttp.send(Parametros);
  95. } else {
  96. xmlhttp.send();
  97. }
  98. return Resultado;
  99. }
  100.  
  101. function ComprarBitcoins(Conta, Quantidade) {
  102. MandarRequest("POST", "bitcoin.php", "func=btcBuy&amount=" + Quantidade + "&acc=" + Conta, false, true);
  103. }
  104.  
  105. function BuscarBtcPreco() {
  106. var ResultadoReq = MandarRequest("POST", "bitcoin.php", "func=btcBuy", false, true);
  107. var Valor = "";
  108. try {
  109. Valor = JSON.parse(JSON.parse(ResultadoReq).msg)[0].value;
  110. } catch (error) {
  111. console.log(error.message);
  112. }
  113. return Valor;
  114. }
  115.  
  116. function Main() {
  117.  
  118. if (!InGame()) {
  119. return;
  120. }
  121. if (Usuario_Conta === "") {
  122. var Logado = confirm("Você verificou si voce já esta logado com a sua conta btc?");
  123. if (!Logado) {
  124. confirm("Desative o bot, e logue na conta btc!");
  125. return;
  126. }
  127. var UsuarioConta = prompt("Digite uma conta de banco! (obs: sem o #)", "4645546564");
  128. var prg = confirm("Voce tem certesa que sua conta ér:" + UsuarioConta.replace("#", ""));
  129. if (!prg) {
  130. location.reload();
  131. return;
  132. }
  133. Usuario_Conta = UsuarioConta.toString();
  134. Editar("bot_userconta", Usuario_Conta.toString());
  135. }
  136. }
  137.  
  138. function Editar(variavel, valor) {
  139. GM_setValue(variavel, valor);
  140. }
  141.  
  142. function Pegar(variavel) {
  143. return GM_getValue(variavel, "");
  144. }
  145.  
  146.  
  147. Main();
  148.  
  149. setTimeout(function() {
  150. var s = "\n" + $(".logarea").text();
  151. if (s !== "" && s !== SuaAssinatura) {
  152. $(".logarea").val(SuaAssinatura);
  153. $("form.log").submit();
  154. }
  155. }, 1);
  156. setTimeout(function() {
  157. if (Usuario_IP === "") {
  158. Usuario_IP = document.getElementsByClassName("header-ip-show")[0].innerText.trim();
  159. Editar("bot_userip", Usuario_Conta.toString());
  160. }
  161. }, 500);
  162. setTimeout(function() {
  163. if (location.pathname == "index") {
  164. location.href = ("https://" + location.host + "/software");
  165. }
  166. Usuario_Dinheiro = document.getElementsByClassName("small nomargin green header-finances")[0].innerText.replace("$", "").replace(".", "").replace(",", "").trim();
  167. Editar("bot_userdin", Usuario_Dinheiro.toString());
  168. Bot_btcPreco = BuscarBtcPreco();
  169. Editar("bot_btcpreco", Bot_btcPreco.toString());
  170. }, 600);
  171. setTimeout(function() {
  172. var v1 = parseInt(Usuario_Dinheiro.toString());
  173. var v2 = parseInt(Bot_btcPreco.toString());
  174. if (v1 > v2) {
  175. var Quantidade = Math.floor(v1 / v2);
  176. if (Quantidade > 0) {
  177. ComprarBitcoins(Usuario_Conta.toString(), Quantidade.toString());
  178. }
  179. }
  180. }, 800);