AutoFarm A

Soh pros folgados kkk

  1. // ==UserScript==
  2. // @name AutoFarm A
  3. // @namespace http://brtwscripts.com
  4. // @version 0.1
  5. // @description Soh pros folgados kkk
  6. // @author Biaza
  7. // @include https://*screen=am_farm*
  8. // @grant none
  9. // ==/UserScript==
  10.  
  11.  
  12. var refresh = 0;
  13. var remove = 0;
  14. var tempo = 1000;
  15. var x = 0;
  16. var minhaVar = "";
  17. var menu = $('#am_widget_Farm a.farm_icon_a');
  18. var jaEnviados = $(menu).parent().parent().find('img.tooltip').length+"000";
  19.  
  20. if(refresh == 1) {
  21. setInterval(function() { window.location.reload(); }, 6000)
  22. }
  23.  
  24. if(remove == 1) {
  25. $('img').each(function() { var tempStr = $(this).attr('src'); if (tempStr.indexOf('attack') != -1) { $(this).addClass('tooltip') } });
  26. }
  27.  
  28. var altAldTempo = parseInt($('#am_widget_Farm a.farm_icon_c').length+"000") - parseInt(jaEnviados);
  29.  
  30. if(altAldTempo == "0") {
  31. var altAldTempo = aleatorio(30000, 50000);
  32. } else {
  33. var altAldTempo = parseInt(altAldTempo) + parseInt(aleatorio(30000, 50000));
  34. }
  35.  
  36. function aleatorio(inferior, superior) {
  37. numPosibilidades = superior - inferior
  38. aleat = Math.random() * numPosibilidades
  39. return Math.round(parseInt(inferior) + aleat)
  40. }
  41.  
  42. for(i = 0; i < 100; i++) {
  43. $(menu).eq(i).each(function() {
  44. if (!($(this).parent().parent().find('img.tooltip').length)) {
  45. var tempoAgora = (tempo * ++x) - aleatorio(1500,3000);
  46. setTimeout(function(minhaVar) { $(minhaVar).click(); }, tempoAgora, this);
  47. }
  48. })
  49. }
  50.  
  51. function altAldeia() {
  52. $('.arrowRight').click();
  53. $('.groupRight').click();
  54. }
  55.  
  56. setInterval(altAldeia, 5000);