Dongeon Clicker AutoClic

AutoClic pour Dongeon Clicker

ही स्क्रिप्ट इंस्टॉल करण्यासाठी तुम्हाला Tampermonkey, Greasemonkey किंवा Violentmonkey यासारखे एक्स्टेंशन इंस्टॉल करावे लागेल.

You will need to install an extension such as Tampermonkey to install this script.

ही स्क्रिप्ट इंस्टॉल करण्यासाठी तुम्हाला Tampermonkey किंवा Violentmonkey यासारखे एक्स्टेंशन इंस्टॉल करावे लागेल..

You will need to install an extension such as Tampermonkey or Userscripts to install this script.

ही स्क्रिप्ट इंस्टॉल करण्यासाठी तुम्हाला Tampermonkey यासारखे एक्स्टेंशन इंस्टॉल करावे लागेल..

ही स्क्रिप्ट इंस्टॉल करण्यासाठी तुम्हाला एक युझर स्क्रिप्ट व्यवस्थापक एक्स्टेंशन इंस्टॉल करावे लागेल.

(माझ्याकडे आधीच युझर स्क्रिप्ट व्यवस्थापक आहे, मला इंस्टॉल करू द्या!)

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला Stylus सारखे एक्स्टेंशन इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला Stylus सारखे एक्स्टेंशन इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला Stylus सारखे एक्स्टेंशन इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला एक युझर स्टाईल व्यवस्थापक इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला एक युझर स्टाईल व्यवस्थापक इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला एक युझर स्टाईल व्यवस्थापक इंस्टॉल करावे लागेल.

(माझ्याकडे आधीच युझर स्टाईल व्यवस्थापक आहे, मला इंस्टॉल करू द्या!)

// ==UserScript==
// @name        Dongeon Clicker AutoClic
// @namespace   KEyes
// @description AutoClic pour Dongeon Clicker
// @include     https://leandrobarone.github.io/dungeonclicker/
// @version     1.7
// @grant       none
// ==/UserScript==

document.ready = new function(){
  opt();
  setInterval(adventure, 500);
  setInterval(buyBuild, 1000);
  setInterval(buyArtf, 1000)
}


//buy building, fill the max building in the max var
var max = 25;

function buyBuild(){
  var i;
  for(i=0;i<document.getElementById('building-list').children.length; i++)
    {
      if((document.getElementById('building-list').children[i].attributes.class.nodeValue == "element building opaque available") || (document.getElementById('building-list').children[i].attributes.class.nodeValue == "element building opaque unavailable")){
        if(parseInt(document.getElementById('building-list').children[i].children[4].innerHTML) < max ){
          document.getElementById('building-list').children[i].click();}}
      else{break;}
    }
}

//buy artefact
function buyArtf(){
  var j;
  for(j=0;j<document.getElementById('artifact-list').children.length; j++)
    {
      if((document.getElementById('artifact-list').children[j].attributes.class.nodeValue == "element artifact not-bought available opaque") || (document.getElementById('artifact-list').children[j].attributes.class.nodeValue == "element artifact opaque bought")){
        document.getElementById('artifact-list').children[j].click();}
      else{break;}
    }
}

//options
function opt(){
  dC.options.ShowAdventureLight = false;
  dC.options.RotateAdventureLight = false;
  dC.options.ShowTransitions = false;
  dC.options.Particles = false;
  dC.options.AdditionalParticles = false;
  dC.options.SFX = false;
  updateOptions(); 
}