reCAPTCHA E FARM NO A

Script facilitador de saques para Tribal Wars.

  1. // ==UserScript==
  2. // @name reCAPTCHA E FARM NO A
  3. // @author superluyz
  4. // @version 1.2 (SET/2019;)
  5. // @grant Publico
  6. // @description Script facilitador de saques para Tribal Wars.
  7. // @include http*://*.tribalwars.com.pt/*screen=am_farm*
  8. // @namespace https://greasyfork.org/users/163899
  9. // ==/UserScript==
  10.  
  11. var botProtect = $('body').data('bot-protect');
  12. if (document.URL.indexOf('screen=am_farm') == -1)
  13. console.log('Você deve executar o script no assistente de farm!');
  14. else if (botProtect !== undefined) {
  15. alert('Alerta Captcha!');
  16. }
  17. else {
  18. var x = 1, // NÃO ALTERAR!
  19. menu = $('#am_widget_Farm a.farm_icon_a'),
  20. tempo = "random",
  21. minhaVar = "", // NÃO ALTERAR!
  22. alteraraldeia = true,
  23. altAldTempo = true, // Tempo em milesegundos para alternar as aldeias (Use 'true' para aleatório)
  24. atualizarPagina = true, // Atualizar a página automaticamente? ('true' = SIM, 'false' = NÃO)
  25. atlPagTempo = "random",
  26. boxCaptcha = $("#bot_check"); // NÃO ALTERAR!
  27.  
  28. var aleatorio = function(superior, inferior) {
  29. var numPosibilidades = superior - inferior,
  30. aleat = Math.random() * numPosibilidades;
  31.  
  32. return Math.round(parseInt(inferior) + aleat);
  33. };
  34.  
  35. if (tempo === "random") {
  36. tempo = aleatorio(5000, 10000);
  37. }
  38. if (atlPagTempo === "random") {
  39. atlPagTempo = aleatorio(700000, 800000);
  40. }
  41.  
  42. $('img').each(function() {
  43. var tempStr = $(this).attr('src');
  44. if (tempStr.indexOf('attack') != -1)
  45. $(this).addClass('tooltip');
  46. });
  47.  
  48. if (atualizarPagina === true) {
  49. setInterval(function() {
  50. window.location.reload();
  51. }, atlPagTempo);
  52. }
  53.  
  54. if (altAldTempo !== false) {
  55. if (altAldTempo === true)
  56. if($('#light').text() >= 5 && $('#spy').text() >= 1)
  57. altAldTempo = aleatorio(100000, 150000);
  58. else
  59. altAldTempo = aleatorio(3000, 5000);
  60. else
  61. altAldTempo = parseInt(altAldTempo) + parseInt(aleatorio(500, 1000));
  62. }
  63. }
  64.  
  65. for (i = 0; i < 100; i++) {
  66. if(parseInt($('#plunder_list tr:not(:first, :last)').eq(i + 1).find('td').eq(6).text()) == 0 || isNaN($('#plunder_list tr:not(:first, :last)').eq(i + 1).find('td').eq(6).text()) == true){
  67. $(menu).eq(i).each(function() {
  68. var tempoAgora = tempo * x;
  69. setTimeout(function(minhaVar) {
  70. if($('#light').text() >= 5 && $('#spy').text() >= 1)
  71. $(minhaVar).click();
  72. }, tempoAgora, this);
  73. ++x;
  74. });
  75. }
  76. }
  77.  
  78.  
  79. if (alteraraldeia === true) {
  80. var altVillage = setInterval(function () {
  81. $('.arrowRight, .groupRight').click();
  82.  
  83. clearInterval(altVillage);
  84. }, altAldTempo);
  85. }
  86.  
  87.  
  88. var checkCaptcha = setInterval(function() {
  89. if (boxCaptcha.length) {
  90. alert('Captcha bloqueado');
  91. clearInterval(checkCaptcha);
  92. clearInterval(altVillage);
  93. }
  94. }, 100);