[Script No legal] script de reclutamiento

  • Autor de hilo DeletedUser33623
  • Fecha de inicio

DeletedUser33623

Guest
bueno tengo 2 scripts para reclutar tropas off y deff pero el script es algo viejo es del 2011 y pues el script funciona y pues como ahora los scripts que eran validos ahora son ilegales quisiera saber si son validos los scripts nuevamente

Para reclutar tropas masivamente ... solo cambiar las cantidades de acuerdo a como les guste, y separar por grupos ofensivos y defensivos.

sierve:sirve para reclutar tropas tanto ofensivas como defensivas de forma rapida y eficaz y nos ahorra mucho tiempo que podemos usar en otras cosas
como usarlo: se usa en vision general, del grupo de pueblos en los que querais reclutar las tropas solo hacer 2 clips y el script hace el resto
nombre de la entrada reclutamiento
URL DE LA IMAGEN no tiene
URL DE DESTINO abajo esta

[SPOIL]javascript:var archers=false;var configuration=[5445,5445,0,0,100,0,0,1500,0,50];var units;var unitsNET;var costs;function arrayMin(array){var value=array[0];for(var t=1;t<array.length;t++){if(array[t]<value){value=array[t];}}return value;}function linearDivideArray(array1,array2){var value=[];if(array1.length==array2.length){for(var t=0;t<array1.length;t++){if(array2[t]!=0){value[t]=array1[t]*1.0/array2[t];}else{value[t]=0;}}}return value;}function linearAddArray(array1,array2){var value=[];if(array1.length==array2.length){for(var t=0;t<array1.length;t++){value[t]=array1[t]+array2[t];}}return value;}function getUnitId(unit){for(var t=0;t<units.length;t++){if(unit==unitsNET[t]){return t;}}return-1;}function getQueue(record){var value=[0,0,0,0,0,0,0,0,0,0];for(var u=3;u<record.cells.length;u++){try{value[u-3]=parseInt(record.cells.childNodes[1].childNodes[1].firstChild.title,10);}catch(e){}if(isNaN(value[u-3])){value[u-3]=0;}}return value;}function getResources(record){var value=[0,0,0,0];var res=record.cells[1].textContent.split("\n");var farm=record.cells[2].innerHTML.split('/');value[0]=parseInt(res[1].replace(".",""),10);value[1]=parseInt(res[2].replace(".",""),10);value[2]=parseInt(res[3].replace(".",""),10);value[3]=farm[1]-farm[0];return value;}function getProduced(record){var value=[0,0,0,0,0,0,0,0,0,0];for(var u=3;u<record.cells.length;u++){try{value[u-3]=parseInt(record.cells.childNodes[1].textContent.split("\n")[2],10);}catch(e){}if(isNaN(value[u-3])){value[u-3]=0;}}return value;}if(document.URL.match('screen=train')&&document.URL.match('mode=mass')){var records=document.getElementById('mass_train_table').rows;if(archers){units=['spear','sword','axe','archer','spy','light','marcher','heavy','ram','catapult'];unitsNET=['Spear Fighter','Swordsman','Axeman','Archer','Scout','Light Cavalry','Mounted Archer','Heavy Cavalry','Ram','Catapult'];costs=[[50,30,10,1],[30,30,70,1],[60,30,40,1],[100,30,60,1],[50,50,20,2],[125,100,250,4],[250,100,150,5],[200,150,600,6],[300,200,200,5],[320,400,100,8]];}else{units=['spear','sword','axe','spy','light','heavy','ram','catapult'];unitsNET=['Spear Fighter','Swordsman','Axeman','Scout','Light Cavalry','Heavy Cavalry','Ram','Catapult'];costs=[[50,30,10,1],[30,30,70,1],[60,30,40,1],[50,50,20,2],[125,100,250,4],[200,150,600,6],[300,200,200,5],[320,400,100,8]];}for(r=1;r<records.length;r++){var subconf=[];var total_costs=[0,0,0,0];var i;var resources=getResources(records[r]);var queue=getQueue(records[r]);var produced=getProduced(records[r]);for(i=0;i<units.length;i++){subconf=configuration-(queue+produced);if(subconf<0){subconf=0;}for(var j=0;j<4;j++){total_costs[j]+=costs[j]*subconf;}};var factor=arrayMin(linearDivideArray(resources,total_costs));if(factor>1.0){factor=1.0;}for(i=0;i<units.length;i++){var number=subconf*factor;if(number<0){number=0;}if(number!=0){if(records[r].cells[3+i].childNodes[3]&&records[r].cells[3+i].childNodes[3].disabled==false){var ibox=records[r].cells[3+i].childNodes[3];try{ibox.value=parseInt(number,10);}catch(e){alert(e);}}}}}stop();}else{alert('Script only works on the mass recruitment page');}[/SPOIL]



Mass Off


[SPOIL]javascript:var units=[0,0,7000,0,0,1950,360,0];var farm=0;var res=[0,0,0];if(game_data.mode!='mass')$(location).attr('href',game_data.link_base_pure+'train&mode=mass');function D(a,b){v=[];if(a.length==b.length){for(t=0;t<a.length;t++){if(b[t]!=0){v[t]=a[t]*1.0/b[t]}else{v[t]=0}}}return v}function Q(r){v=[0,0,0,0,0,0,0,0,0,0];for(u=3;u<r.cells.length;u++){try{v[u-3]=parseInt(r.cells.childNodes[1].childNodes[1].firstChild.title,10)}catch(e){}if(isNaN(v[u-3])){v[u-3]=0}}return v}function R(r){v=[0,0,0,0];var s=r.cells[1].textContent.split("\n");var f=r.cells[2].innerHTML.split("/");v[0]=parseInt(s[1].replace(".",""),10)-res[0];v[1]=parseInt(s[2].replace(".",""),10)-res[1];v[2]=parseInt(s[3].replace(".",""),10)-res[2];v[3]=f[1]-f[0]-farm;return v}function P(r){v=[0,0,0,0,0,0,0,0,0,0];for(u=3;u<r.cells.length;u++){try{v[u-3]=parseInt(r.cells.childNodes[1].textContent.split("\n")[2],10)}catch(e){}if(isNaN(v[u-3])){v[u-3]=0}}return v}c=$("table.vis");c=c[2].rows;if($("#mass_train_table [src*=unit_archer]").length==0){f=["spear","sword","axe","spy","light","heavy","ram","catapult"];s=[[50,30,10,1],[30,30,70,1],[60,30,40,1],[50,50,20,2],[125,100,250,4],[200,150,600,6],[300,200,200,5],[320,400,100,8]]}else{f=["spear","sword","axe","archer","spy","light","marcher","heavy","ram","catapult"];s=[[50,30,10,1],[30,30,70,1],[60,30,40,1],[100,30,60,1],[50,50,20,2],[125,100,250,4],[250,100,150,5],[200,150,600,6],[300,200,200,5],[320,400,100,8]]}for(r=1;r<c.length;r++){b=[];z=[0,0,0,0];for(i=0;i<f.length;i++){b=units-(Q(c[r])+P(c[r]));if(b<0){b=0}for(j=0;j<4;j++){z[j]+=s[j]*b}};a=D(R(c[r]),z),h=a[0];for(t=1;t<a.length;t++){if(a[t]<h){h=a[t]}}if(h>1.0){h=1.0}for(i=0;i<f.length;i++){n=b*h;if(n<0){n=0}if(n>1){if(c[r].cells[3+i].childNodes[3]){x=c[r].cells[3+i].childNodes[3];x.value=parseInt(n,10)}}}}end();[/SPOIL]
 

DeletedUser36186

Guest
pero si tienes el reclutamiento masivo que haces un grupo y te lo hace todo haciendo dos clicks :S no te compliques :p
 
Arriba