Advertisement
TiagoSamuel

Deteção dos ataques em massa x2

Jan 31st, 2022
34
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.32 KB | None | 0 0
  1. var ultimoUpdate = "00:00h de 1 de fevereiro"; // Data do ultimo update
  2. var aldeiasAtaqueUltimoCoordenado = ""; // aldeias ofensivas usadas em coordenados anteriores
  3. var aldeias = ""; // Aldeias com fulls detetados para o coordenado atual
  4.  
  5. for(var aldeiasArray=uniqueArray4(aldeias.split(" ")),aldeiasAtaqueUltimoCoordenadoArray=uniqueArray4(aldeiasAtaqueUltimoCoordenado.split(" ")),i=2;i<document.querySelector("#incomings_table > tbody").childElementCount;i++){var coord=$("#incomings_table > tbody > tr:nth-child("+i+") > td:nth-child(3) > a")[0].textContent.match(/\d+\|\d+\)/)[0].replace(")","");aldeiasArray.includes(coord)?($("#incomings_table > tbody > tr:nth-child("+i+") > td:nth-child(3) > a")[0].style.backgroundColor="#1bff00",$("#incomings_table > tbody > tr:nth-child("+i+") > td:nth-child(3)")[0].style.textDecoration="line-through"):aldeiasAtaqueUltimoCoordenadoArray.includes(coord)&&($("#incomings_table > tbody > tr:nth-child("+i+") > td:nth-child(3)")[0].style.backgroundColor="#ffa700")}function uniqueArray4(t){return[...new Set(t)]}const exp='<div style="width: 100%; text-align: center; "><img src="https://i.imgur.com/F7hHvT2.png"></div>';$(".overview_filters_manage").eq(0).before(exp),$(".overview_filters_manage").eq(0).before(`<h1>Ultimo update: ${ultimoUpdate} </h1> <small>xdam98 (Discord: Xico#7941) </small> <br>`);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement