Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // ==UserScript==
- // @name Recruite Soldiers and Go Back
- // @namespace http://tampermonkey.net/
- // @version 0.1
- // @description try to take over the world!
- // @author You
- // @match https://dec1.die-staemme.de/game.php?village=4818&screen=barracks
- // @grant none
- // ==/UserScript==
- (function() {
- 'use strict';
- setInterval( ()=>{
- if( ( ( document.getElementById('replace_barracks') || {}).innerText || '' ).indexOf('Nächste Einheit') > -1 ){
- // is already recruiting there is no need to recruite more
- location.href = "https://dec1.die-staemme.de/game.php?village=4818&screen=main";
- return;
- }
- let spearInput = document.querySelectorAll("[name='spear']")[0];
- let buttonRecurite = document.getElementsByClassName('btn btn-recruit')[0];
- spearInput.value=10;
- buttonRecurite.click();
- }, 60000);
- })();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement