Coinbrawl

try to take over the world!

Versione datata 26/02/2016. Vedi la nuova versione l'ultima versione.

Dovrai installare un'estensione come Tampermonkey, Greasemonkey o Violentmonkey per installare questo script.

Dovrai installare un'estensione come Tampermonkey o Violentmonkey per installare questo script.

Dovrai installare un'estensione come Tampermonkey o Violentmonkey per installare questo script.

Dovrai installare un'estensione come Tampermonkey o Userscripts per installare questo script.

Dovrai installare un'estensione come ad esempio Tampermonkey per installare questo script.

Dovrai installare un gestore di script utente per installare questo script.

(Ho già un gestore di script utente, lasciamelo installare!)

Dovrai installare un'estensione come ad esempio Stylus per installare questo stile.

Dovrai installare un'estensione come ad esempio Stylus per installare questo stile.

Dovrai installare un'estensione come ad esempio Stylus per installare questo stile.

Dovrai installare un'estensione per la gestione degli stili utente per installare questo stile.

Dovrai installare un'estensione per la gestione degli stili utente per installare questo stile.

Dovrai installare un'estensione per la gestione degli stili utente per installare questo stile.

(Ho già un gestore di stile utente, lasciamelo installare!)

// ==UserScript==
// @name         Coinbrawl
// @version      0.12
// @description  try to take over the world!
// @author       You
// @match        https://www.coinbrawl.com/*
// @grant        none
// @namespace https://greasyfork.org/users/25633
// ==/UserScript==

//menu
$('li:has(a[href$="/referrals"])').remove();

//ads
$('div.panel-game-content:first').hide();
$('div.col-sm-9 > center').hide();
$('div.col-sm-3').hide();

if ( $("li.active a[href='/").length == 1 ){
    $('div.col-sm-6').hide();
    $('div.col-sm-4').hide();
    $('div.col-sm-8').hide();

    var searchArena = $('#battle-table > div > p > a')[0];
    searchArena.onclick=function(){
        var chkAttk = setTimeout(function(){
            attackUser();
        },2000);
    };


}

function attackUser(){
    $('tbody:first > tr').each(function(){

        if ( $(this).find('strong.text-success').html() > 2000 ){

            if ( $(this).find('div.text-warning').length > 0 ) {
                
                $(this).find('td > a')[0].click();
                console.log('[warning] Attacking user for ' + $(this).find('strong.text-success').html());
            }
            
        }

        if ( $(this).find('strong.text-success').html() > 5500 ){

            if ( $(this).find('div.text-danger').length > 0 ){

                $(this).find('td > a')[0].click()
                console.log('[danger] Attacking user for ' + $(this).find('strong.text-success').html());
            }
        }
    });
}