gomezvilleriasgmail.com / eRepublik Stuff ++

// ==UserScript==
// @name		eRepublik Stuff ++
// @version		2.3.2
// @namespace	http://userscripts.org/scripts/show/390674
// @require		http://code.jquery.com/jquery-2.1.0.min.js
// @include		http*://*www.erepublik.com/*
// @exclude		/^http(.*)://www\.erepublik\.com/(.*)/(get-gold|loyalty/program|gold-bonus)(.*)/
// @exclude		http://www.erepublik.com/en/map
// @grant		GM_info
// @grant		GM_deleteValue
// @grant		GM_setValue
// @grant		GM_getValue
// @grant		GM_addStyle
// @grant		GM_xmlhttpRequest
// @grant		unsafeWindow
// ==/UserScript==
function setDamageKills(){$j(document).ajaxSuccess(function(t,e,i){var a,n,o,r;(i.url.match(/military\/fight-shooot/)||i.url.match(/military\/deploy-bomb/))&&(a=JSON.parse(e.responseText),a.error||"ENEMY_KILLED"!=a.message&&"OK"!=a.message||(n=0,o=0,r=0,i.url.match(/military\/deploy-bomb/)?(weaponDamage=a.bomb.booster_id,n=a.bomb.damage):(n=a.user.givenDamage,o=a.user.earnedXp,1==a.oldEnemy.isNatural&&(r=1,n+=Math.floor(.1*n))),Kills+=1,Damage+=n,Hits+=o,setTimeout(function(){GM_setValue(eRS.citizenId+".killsToday"+date,Kills),GM_setValue(eRS.citizenId+".damageToday"+date,Damage),GM_setValue(eRS.citizenId+".hitsToday"+date,Hits)},0),options.noKillsDamage&&ShowKillDamage(),options.mercBT&&MercenaryBTUpdate(),eRS.country==$(".country.left_side div:first h3").text()&&1==options.TPmedal&&updateTP(n)))})}function comma(t){return t.toString().replace(/\B(?=(\d{3})+(?!\d))/g,",")}function ShowKillDamage(){var t,e
$(".NoKills").remove(),t="padding:3px;font-size:12px;color:#666",e="color:#3c8fa7;float:right;padding-right:3px;font-size:13px;font-weight:bold",$("#eRS_settings").before('<div class="NoKills" style="border-bottom:1px solid #DFDFDF;box-shadow:0px 1px 0px rgba(255, 255, 255, 0.9);float:left;width:100%"><strong style="'+t+'">Kills today: </strong><br><span style="'+e+'">'+comma(Kills)+'</span><br><strong style="'+t+'">Damage today: </strong><br><span style="'+e+'">'+comma(Damage)+'</span><br><strong style="'+t+'">Hits today: </strong><br><span style="'+e+'">'+comma(Hits)+"</span></div>")}function TP(){$(".left_side a img").attr("src").split("/L/")[1].split(".")[0]==eRS.country&&GM_xmlhttpRequest({method:"GET",url:"http://www.erepublik.com/"+LANG+"/citizen/profile/"+eRS.citizenId,onload:function(t){var e=t.responseText.replace(/src=/g,"tmpsrc=").replace(/\.css/g,"").replace(/\.js/g,"").replace(/url\(/g,""),i=parseFloat($(e).find(".citizen_military").eq(2).find(".mids").css("width").split("%")[0])
currentTP=parseFloat($(e).find(".citizen_military").eq(2).find("strong:last").text().split("/")[0].replace(/,/g,"").trim()),nextTP=parseFloat($(e).find(".citizen_military").eq(2).find("strong:last").text().split("/")[1].replace(/,/g,"").trim()),doneTP=(nextTP-currentTP)/(100-i)*i,startTP=currentTP-doneTP,$("#total_damage").attr("style","bottom:40px!important;"),$("#player_rank").attr("style","bottom:140px!important;"),$("#player_rank").after('<div id="player_rank" style="bottom:96px"><div id="rank_icon" class="rank_icon" original-title="TP Medal"><img alt="" src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAMAAABEpIrGAAAA6lBMVEUAAADk4dLu6c3Fv6bOybTV0cHQzLa7tqLZ18kXFgrv69e9t5zEv6mlnHi9tpqpn3TGvIft58rd17eDe2OMhWdnXjvZ0J67sH7s5cDdz479+OHIr0KAdD6Nfjvz67zHsEv48ciahzikl12RiF24qWPHuXrOu2jTx47BsGTey3fm039PRBdTSSWdj0qvn1THvIzaxFru35bQwXtya0uon3Pu5bF9bSPr6NLbzoy6pESrpY3FvZubkmlcThP57aPp0mn999ne161kWB+wmz/n4LtwZTbYz57Qyann145iWTGGfVb8+eg8Mwq4sIAJoGshAAAAHHRSTlMAC0g3FSpUBCABNWtDkINknFZsjjoljXV2yI6IGCSKSQAAAglJREFUOMutk+e6ojAQhhHBBOwe29kNvVdBBcHe+7n/21nWs4oL+3MnP5In35vMTGaC/W9ravRzCUgS5PTCD6X23IVlksoBpZmIOn/0bhXkPdSu6PIAKNhAFSxvlaP0AR6+GoL9AiB8AcXx3W4nM/Epy3b9uduatr8XdEMejCx7BEF3qM2sj9exwbxKAIxqmvKAXakMc6kiOZhbvTS56lgqg6KpDm6srwguuiMtYBg8jY04mqfap+mc1vzEDQ/yRYyCcEi/dNA0plNxOURH9jbjYsvdSoHGRJUUKOL1kazq4tBnZc6zGHvKu+Nh5a83VkLBMTcznYtXobiVeEdTi+8AUZYc5HqDgRp7Es84Z8l3v4EUqX05u9Vyw3GnpTCMxz4Ds4WSBM6LFXEcCdOzM1uhHPClGd4OXVEoQUPYc4csAPcTk3ORuLVJytB57kBmAHzCrnb3uR+OClhLW+vbetbFyfe4xYjd2WRy21pfVDNZKBrvCeX5xF/gGJzw+kLJ6Gp/bTBkY7+5kL8B1RIhleqFrlEp8boIyWhz6GDknje2qPSmt9QehQexSGPdKMkPbtgzs1BeBFWKegCjeZWhscYyacuCxp71WpNOy1kGSZ43Q2gDeT23AGixxzJBpTFQgEoAlkNkQVleRwAjSkT+18BgNyawvikknf9vw3/WOwDv19v5w6mvx3i3X7WuRBV1yWtgAAAAAElFTkSuQmCC" style="width:32px;height:32px"></div><div class="rank_holder"><b id="gained_rank2">&nbsp;</b><strong id="rank_max2" original-title="Next TP Medal at:&nbsp;'+comma(nextTP)+'"><span id="rank_min2">'+comma(currentTP)+' TP points</span> </strong><div style="width:'+doneTP/(nextTP-startTP)*100+'%" class="rank_bar" id="rank_status_gained2"></div><div style="width:0%" class="rank_bar gained" id="rank_status2"></div></div>'),$("#rank_max2").tipsy({gravity:"s"})}})}function updateTP(t){currentTP+=t,doneTP+=t
var e=doneTP/(nextTP-startTP)*100
$("#gained_rank2").text("+"+comma(t)),$("#gained_rank2").css("display","block"),$("#rank_status_gained2").css({width:e+"%"}),$("#rank_min2").text(""),$("#rank_min2").text(comma(currentTP)+" TP Points"),currentTP>=nextTP&&setTimeout(TP,2e3)}function NaturalEnemy(){var t,e="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAYFBMVEUAAAAAAAAAAAC4AAAAAAAAAAAAAAAEAAAAAAAAAAAiAACYAABSAACQAAC6AADJAADQFxf////79/jDAAD56+y+AAD78PHVMjPODQ3SJyjur7HQICDxwMLolZbwubnrpKa66gNgAAAAD3RSTlMVEBnvHgIGMQwmO5JQiPeWuYyFAAAAhklEQVQY02VPSQ6DMAycBAdjNhPCUqDL/39Zq2oOKD5YmpFmQwh14+CJPFxThwDDIGE7IRgDw8JDlVLVtWIMDPej6jSprr0YdMSjHueyvXddW3KADHoscZ7jtmsngOdKz/i5rld86soexOmxzObw+0x3IhmRJdNfUpjm2C3HFsWK6sW4Yv4XCT4LXK2gv4wAAAAASUVORK5CYII=";($('.side_flags[src*="/M/'+eRS.country+'.png"]').length>0||unsafeWindow.SERVER_DATA.invaderId==img_country[eRS.country].id||unsafeWindow.SERVER_DATA.defenderId==img_country[eRS.country].id)&&GM_xmlhttpRequest({method:"GET",url:"http://www.erepublik.com/"+LANG+"/country/military/"+eRS.country,onload:function(i){var a=i.responseText.replace(/src=/g,"tmpsrc=").replace(/\.css/g,"").replace(/\.js/g,"").replace(/url\(/g,"")
$(a).find(".indent:eq(0) .attacker img").length>0&&(t=a.split("flagholder")[1].split('tmpsrc="')[1].split('"')[0].split("/")[6].split(".")[0],$("#battle_listing li").each(function(){0==$(".resistance_sign",this).length&&$('.side_flags[src*="/M/'+eRS.country+'.png"]',this).length>0&&$('.side_flags[alt="'+t+'"]',this).after('<img alt="" title="Natural enemy" src="'+e+'" style="margin:8px -20px 0 -10px;z-index:5">')}),$('.country a img[src*="/L/'+t+'.png"]').after('<img alt="" title="Natural enemy" src="'+e+'" style="position:absolute;margin:-2px 0 0 -10px">'))}})}function MaxRecoverEnergy(){$("#maxRecover").remove(),$("#current_health").after('<strong id="maxRecover" style="text-align:right;margin-right:5px">'+unsafeWindow.food_remaining+"</strong>"),setTimeout(MaxRecoverEnergy,1e3)}function StorageInventory(){GM_xmlhttpRequest({method:"GET",url:"http://www.erepublik.com/"+LANG+"/economy/inventory",onload:function(t){var e,i,a,n,o,r,s,l,d,c,p,A,g,m,u,f,h,y,b,x,w,v,k,_,S,B,R,C,M,T,F=t.responseText.replace(/src=/g,"tmpsrc=").replace(/\.css/g,"").replace(/\.js/g,"").replace(/url\(/g,"")
if(options.showStorageInv){for(e=$.parseJSON(F.split("var itemAmounts = ")[1].split("var itemPartials")[0].trim().split(";")[0]),i=$.parseJSON(F.split("var itemPartials = ")[1].split("var countryList")[0].trim().split(";")[0]),a=[],n="",o="enabled",d=1;3>=d;d++)for(c=1;8>=c;c++)7>=c?(p="undefined"==typeof e[d][c]?0:e[d][c],o=0!=p?"enabled":"disabled",1==d&&(n=6==c?"Food quality Q6 <br> Energy restore 12/use":7==c?"Food quality Q7 <br> Energy restore 20/use":"Food quality Q"+c+" <br> Energy restore "+2*c+"/use"),2==d&&(n=6==c?"Weapon quality Q6 <br> Fire power: 120 - Durability: 6 uses":7==c?"Weapon quality Q7 <br> Fire power: 200 - Durability: 10 uses":"Weapon quality Q"+c+" <br> Fire power: "+20*c+" - Durability: "+c+" uses"),3==d&&(n="Moving ticket quality Q"+c+" <br> Energy: "+(5-c)+"/use - Moving distance: "+c+" zone(s)"),"undefined"!=typeof i[d][c]&&0!=i[d][c]&&(n+="<br>1 partially used. Durability: "+i[d][c]+" uses"),(2>=d||3==d&&5>=c)&&a.push('<li class="first '+o+'" original-title="'+n+'"><img src="'+itemicons[d][c]+'" alt=""><br><strong>'+comma(p)+"</strong></li>"),n=""):1==d&&8==c?(p="undefined"==typeof e[d][c+2]?0:e[d][c+2],o=0!=p?"enabled":"disabled",a.push('<li class="first '+o+'" '+r+' original-title="Energy Bar <br> Energy restore 100/energy bar"><img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADcAAAA3CAMAAACfBSJ0AAACIlBMVEUAAAAAAAAAA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mkCQBiCyV9HBkZLg7R8DzYli1cHf/jdTM2kwSAEAC8oc+CaJTCARcR6vreFExwamurSkHZeVlgABZBYcGva7oVNHFjbAowcFSJoQEqK5JX10VpyOPs6M3GEqPtn/31HN9LOUcrU5RAkh1ulgsnppCEwK1zjBQWJRXFxlmKcLn8e2qLKRxFsTi9Jm5ckDChi0Fpb2FW5GvLE3n8rlxU7qYDSuBMrNmZXluBgCCQF7vfkeYqwUr1stjTz50cgA9AggzlMq19QUAITkp2x3ezy29KzGK4mH5kFRz0AJXD00gWv+KfrBQlPzlvbvF0BJ5kryz4dF+zYnqFyA4MLrv3zIBIRSljo8FumIWieLyW4s95FqttF0NSLSNpWWCI0pNTvP0s/qiJfbxT8/OR4/7DYps4zbWVkhR8qS/L2adcJ6EW+xxPqJPKh1EUQiXMlInx9xx7Dbi+viDit0SfenA0WDVLOAok9MCfe7y7yPJz+/hluh0A72FBTspaWnPgrE7ESHrFHTxFEWFRfsdzcUoMTodXvBA59XmTffXn10SZLI2QU9zXvNWnXcshjEgOMMIjuN0HJ4m6aaI22JefYL63Lbc3LqPH2g0JpNJgdBM2BoxPgJaZh6FEgK9+fnpUKodlWpnZ29vg2BecPEMpJqJdJoNlRWQ09U2/dqZzXZyYLFYVCSb7EsViqijmebEZr8UvAlyc3NzhiLyrrteatAz68egwHZO7NCAIGc3Z6NmbGbmQIwTmu2TQWPa2MOxWA4OqNXfAlQQOLTMoDNsbWmU6yUYt3BdDqHDC0WARHMVZoQwVaJiU/KwFNVbgX4Fur/5NfbI/8Mf2SHRTYP80k4AAAAASUVORK5CYII=" alt=""><br><strong>'+comma(p)+"</strong></li>"),p="undefined"==typeof e[d][c+3]?0:e[d][c+3],o=0!=p?"enabled":"disabled",a.push('<li class="first '+o+'" '+r+' original-title="Double Energy Bar <br> Energy restore 200/energy bar"><img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADcAAAA3CAMAAACfBSJ0AAACW1BMVEUAAAABAQEAAgIAAAAACQcAAAAF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kZggA+Xd20eFHUqkUmn8TfLsQuN0XPAIICcEzWsh/Xoj/0Ij3h1p/8Hvwz8hS/08/AUfvIjtGeQ6zAAAAAElFTkSuQmCC" alt=""><br><strong>'+comma(p)+"</strong></li>")):3==d&&8==c&&(p="undefined"==typeof e[d-1][c+2]?0:e[d-1][c+2],o=0!=p?"enabled":"disabled",n="Bazooka<br>Defeat enemy with one hit<br>Damage: 10,000 - Durability: 3 uses","undefined"!=typeof i[d-1][c+2]&&0!=i[d-1][c+2]&&(n+="<br>1 partially used. Durability: "+i[d-1][c+2]+" uses"),a.push('<li class="center '+o+'" '+s+' original-title="'+n+'"><img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADcAAAA3CAMAAACfBSJ0AAAAllBMVEUAAAAXGRYCAwIDAwMAAAACAwIAAAABAQEICQgKCgoBAQEwMzBscWkyNTE4OzZXW1N0eHJna2QuMS1TV1GYm5hqbGd4fXI/RT1ZYFY/RDyMkYiYnZRiaF2kqKA1OTHDyMJtc2h0e3DQ0s6Rl4+GjIK0ubJITkSAhn0iJB5QVUtnbmItLyp7f3iusqu9wbsPEA6JgZWMkrgwHd3RAAAAGHRSTlMACyoxECIIGQEEOFkrQ4GQkWJr4WLJ9bMNwug3AAACgUlEQVRIx+3Ta2+iQBQG4KIiIgJe1naYGzPOcAfb/f9/bl8ITVOJLt1kv/l+JHnyHg6Hl2ee+U/ZnV8Pm39gnKhi/0PkH06EcG3p7gdF4W5XJZVuKTVibqETvCVIXudaGHHN5rndXgJVGLEueJZeBD38recXEihSNjKvlS40bS9dS87+wy2EMec151xWeZIXpO+zlEWL5eaBco8Vr7UVjNgCq9c1J1Rn6fFt+6grPKlW9arVxrS1yJiyVAssxF28bO71OYckr4geXoiZgtIsFTq95kV6jrh1p3AX7w+Hw4kTvJgirWHMWGpEl15Zm2ZRRZViryvfv3FhQmxLIAikLRIjGKUsg2IFTfcLpXTP1jdulzRJ8v5e2oKrwtCCaMEEvtdFBLGygffxYbJ4tXbWvv/NxVLKd0QKahi1hraDunbnF69JTuHHbxY7q5Vz0+dXcGUf1RmL+TIzKBN7jldKHkanYOV5cOtvfU5NSN7gpGTODOvSS0cvaSZU4K88t5R1BASGwhtHKdV5VeE6dNc3tTQVxdGDcreltJHnDg593+bcsOwqcE1wPL2knSWC9iO6SCCraAE2uNt97lGi8jyRTSWujFdFvOy7Fsg2CKGQiUJ2cF0iZVPmxh6PUQgFg6DRm5Z9DYo9qAYLJZGHhQONCgIZ1TRhJihPGnyroWmJjAoCGdU0AauTpmwS1wUaGZSDnj53fgQ8DnguZRK6y+V2uwVzXXSh5w4ZHe7OC6LjwoVCwNAFtXmkUOevHcdZeYuR9WVQUzR1UC7YV9mg5rrlJxv+0LkOEApsWPtsB4iMBzXTDXByh3MKAZFezWaAfg+Rz+3PL4RExrL5EHI8xGeeuZc/JwFHyim6QbMAAAAASUVORK5CYII=" alt=""><br><strong>'+comma(p)+"</strong></li>"),n="")
if(A=GetDivision(),1==A&&(g=75e3),2==A&&(g=375e3),3==A&&(g=75e4),4==A&&(g=15e5),m="undefined"==typeof e[2][parseInt("1"+A)]?0:e[2][parseInt("1"+A)],o=0!=m?"enabled":"disabled",a.push('<li class="last '+o+'" original-title="Bazooka booster<br>Damage: +'+comma(1e4*A)+' - Durability: 3 uses"><img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADcAAAA3CAMAAACfBSJ0AAAAtFBMVEUAAAANCQgDBANfLzMuBgY3DA0NDAoOAQEXMz4FBgUBAQEDAwIbEQ8NCwoaGxxnEhKeGhp8ERHiGRnbGhpVbnVXBQUoQkyFFBQNJS4jPEY2SlI5AwMHHSUWMzwrQ0xSBQVDBwc3DxF0hYyRn6NBWmJieX9VbHOdHByMDw5yBwcbBggyIygIBAUjGR1LZW5zGRlWExYgMDnhWE+3JSOrERGRKCf1d21aODt0YmXJPjleU1fDW1HAc1kOAAAAGHRSTlMAf0cxDSCRA380GSmocPFTNnVanXbZ3p+6Q7ndAAABfUlEQVRIx+3Vy3KCMBSAYUEg5VqvLRBDEgUBkTuKl/d/rwKLbrrhsHDamf77b5KTMGH234uaP5/5HM7e62sVRQsok6Pqeo+LSIYxtI2qKqSYboHDJW3bJn2wBTdB17Er2IDcR7D3HWITz3sDOWd/yBx7Z7twdxycO835v9zROKKn8/nEMMyx/FIMjk/d57T1OJ82H8avvXf3Rd8nmeqCg987b4IjU1wWeINzgM71nbIkJXS+z7qqw65LuAS5eVTdY8poHkrA5/oSUoxpuAC/87dHuUtl+G9lHzg7ewZ3QdY5BHe+69kEzN6bMC+KIocOuGyamHbNoetRzhjnHHgPaJV7bV2SpJZAbhUV2e3qkiReIwhrGB9ciuP1WIQQWlLM/cfdISnDsYTQKCZpsoA757Cyd1zXJDSK6aqCGbdSbFm9E1UNoRFOVlWDWYJgYUVRDIZFVZbGOdE0hI6kSg+NkQ51+xRF0xSGTFMUdQmNcf3B6Op3ujb2QH80+7t9ATNXODEhiu0fAAAAAElFTkSuQmCC" alt=""><br><strong>'+comma(m)+"</strong></li>"),u="undefined"==typeof e[7][1]?0:e[7][1],o=0!=u?"enabled":"disabled",a.push('<li class="last '+o+'" original-title="Food raw material"><img src="'+frmicon+'" alt=""><br><strong>'+comma(u)+"</strong></li>"),f="undefined"==typeof e[12][1]?0:e[12][1],o=0!=f?"enabled":"disabled",a.push('<li class="last '+o+'" '+l+' original-title="Weapon raw material"><img src="'+wrmicon+'" alt=""><br><strong>'+comma(f)+"</strong></li>"),h=0,y=0,b=0,x=0,w=0,-1!=F.indexOf("+50,000 Damage")&&(h="undefined"==typeof e[2][141]?0:e[2][141]),-1!=F.indexOf("+250,000 Damage")&&(y="undefined"==typeof e[2][141]?0:e[2][141]),-1!=F.indexOf("+500,000 Damage")&&(b="undefined"==typeof e[2][141]?0:e[2][141]),-1!=F.indexOf("+1,750,000 Damage")&&(x="undefined"==typeof e[2][141]?0:e[2][141]),-1!=F.indexOf("+2,500,000 Damage")&&(w="undefined"==typeof e[2][141]?0:e[2][141]),o=0!=h?"enabled":"disabled",a.push('<li class="last '+o+'" original-title="Rocket quality Q1<br>Damage: 50,000 - Durability: 1 use"><img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADcAAAA3CAMAAACfBSJ0AAABIFBMVEUAAAATFSETFiMTFSETFSEnEhYbFRkdExI5FRIvHRVdGgFPGAESFSBXGwAUFiMTFyFdGABTGwDtnB5iGQDqjxoUFyUUFiTfbRjvryhnGwFbOA+qSB2GHwacJxBNFQLdeBlwMxZ7HACAHgDthBv/thcSFSGvKQjtQDu7Lg3nOi6DIQBiGwH5TFDVNB5tHAB5HQBbFgDcMBzkeRcaHC/HLQzEMR+NJASTIgP0REb7U1wlJ0DLNRsxMlObJgQjJTHfNy3hihP5uR89O2XOLg2lJQPvpRUVIUv/zSD/2yn6qRX1lA/olQ6OTwetQw/Sj0DRUEkDCyfagBz7wh1WWEvHegZvPQT4WHGyaQb/zSujWQrIZRX2ulLSbFCdeBrIvES7qD1QXOCwAAAAJXRSTlMAYPBzRB4oBRcMmDOjVILieosbaIHRljgLy9RsUMTi1KuI6JNfca1qVgAAAi5JREFUSMft1sd22kAUBmABQkiiQ6iOHTuJBhXUABU6GIzpmB6XJO//FhkBIVnJM975HP8rbT7duaMpIj7yHhMgGExBB5M311/Fy89YZcKsJJqA5w3jAoMF89ut2O/JhULByKCzpCZN948z2S7aAqCRWUxSrelm8rSoFgvyJTKLKyLgwX7UnS9sHSBPCwtZpddezJ+fXwzZYtAUzSom6MlCdfcy705m1g0a87MSZO1CsbrbLTrjveRHqxbX4CAdVq3a7dlmGg+gzaSm9h1WhDMp6GCbR2NJSenzOmRFGzLeylFILqwpFi8L9kHJwMwFEZkkgnobri1BkCtNkaXctsk5QQk2B8sJgq5XgKkk3RYY8+/pSlOaoC7Leq8CLDUXZFxYxHcueKFpJjDq9ToPmqISC7i1FuLI01P2W2eqQmY4SpXChEsYyE5vTXzp3G1mfOWglJjrIqGiHBciD11kIButllBZqsK6dkaQ3CFRH0Vklp277v2P0ZOpSnCIrvFw5+Q7I8iGq0np8SpOI7OH1k9YbLgal0qfmNcWCO33/Ad/D4fdCWRZlC0TObFya7D+de9US6Bt0dCR1Rq3g/V8jMhgqJT3yG4Hg/XyewLj7I+UW5A1yg+t6yzWcZ6qNRq1svMd8e6OdK3WggzGj1WPprzcMSTm/UaenI+gsUoy0aNL05EQDmT+DjTl9bxpoGnMDhnPsT8/gRnaB5mHJrBDeb3OgYEfH/m2fxSG+Mh7yR974mLFsuWe2wAAAABJRU5ErkJggg==" alt=""><br><strong>'+h+"</strong></li>"),o=0!=y?"enabled":"disabled",a.push('<li class="last '+o+'" original-title="Rocket quality Q2<br>Damage: 250,000 - Durability: 1 use"><img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADcAAAA3CAMAAACfBSJ0AAABNVBMVEUAAAATFSESFSEbFhkUERsTFSETFSEiFRIkFRwxHw9VIQITFSJoGQJNGQJeFwBZGgFTHAMUGCTelSJlGQDtnR4TFiETFSETFiHphxnyoBxTJAFnPg11HQCcJhCrSB3IUxvdeBl7HAATFiF7HAD/kRRmSSgTFSBxHAC+MBMTFicbHS9cFgDKLw2uKAXrPTV8IQHbOiqRIgPwQUD6TFIhJT47OWG2KwyoKgjzR0v1phfliRftlwmJIQCcJQTbMhlmHALTMBr/zyKTUAT6ujAtLlDLNCXleRhsPATJbgjlMyUFDSbggxn2thn+2imqRw7DXRarcAnGZD3aeBn7wRzxjxaESQjJiBVSJAiOLhH/qQS3RjDCX1DpnEkOHVDCskBPWVGkWQrUS1TYhwDZiE01OjRmVkD/v10NVDaVAAAAJnRSTlMAQZspHG31BBMLin5RNB6Y2tQLcRtMWuKLcmHM8cRsMtSIs6xGqtDPt/8AAAJNSURBVEjH7dVXd6JAFAdwBCWoscfoaspmCyAd7KKA2DXW2NOT3f3+H2Fn1aNv7OBbzsn/iZcfd+7MXEA+8xFzgoRtCr8vcvP9onx5aqtMIqCLMp+jafrKBvMFWy0xz2mCIDSu4VlisTBHL3lDKRSEHAHNPKCY2Vbbr+m0YlzCs8VsNFgOi7X3V0XjobclQFHm29tw/f6nNm4YshtOEQFKzuXbq+L4/qGmDuQbyEML6GXekNal2sP9uKSOdCcc87Aiz0lKARQrrQdt03MC5SIsOLWOkk4XxuqqvWwl4ViCpfK0pqSBk4bqfBbEoNwpC/bEEArpgiJ0aNNM+iCZXgbNCYogdAyuonswqzHZx8eC5mhJEjqaxvFlKmK1le7DU5ClKrmGJGkcx8ti0Gd14F7vvuAVy8o5utHgaL4iUh63VWvfyOjuKRzvzUSe5migytSF5aV0o6Rj99azr6XifJDj6HylLFIRvxXDYiSJOjbTdQ3Y7V0P1JIpKmDZGeIgN4m5MORHD7BqtThcUjr7n7lxkfskSyvA+nfTyUvQ47dm5wfWZUa3VcDU5iQOdtE6TqfrAH899fu1abMZD8MMqHerUgzz+PxUVZvNL2cITJzolmWy2cfn+bQHGFywEJ7asGw983sCwQ6X08swdcCYLvMzbOtzHsrU6xkmleqGEDsh0EyGASxFkk5b9QgM/6dAHDb/bw5yGy9C2Crpjm0dSnhRO5DAdwVDuOuohaI2OyS2d9wFFmkTgiuOnxOI7WA4Hj1BjogreowCp4985qPkL2zxaOcdKlVjAAAAAElFTkSuQmCC" alt=""><br><strong>'+y+"</strong></li>"),o=0!=b?"enabled":"disabled",a.push('<li class="last '+o+'" original-title="Rocket quality Q3<br>Damage: 500,000 - Durability: 1 use"><img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADcAAAA3CAMAAACfBSJ0AAABRFBMVEUAAAATFSETFSEbFhogExVvQhcSFSEfFREUFiIUEhtfFQATFSFNHQITFSDwpB9YHwITFSETFiNaFwDqjxpZIgJaIQFrGQBNJQYSFSAWGSZZMAOcJhCGHwbHUxv/phXceBlrQxJMFgW6MiWAHwB7HABlSCmeWBjthBsTFSJrHwJhGAF7HQDdNiIfIjnjeRefJgOvKAW2KgxVFwLghRj6uB6QVAMaGy7HaAu8MA7LLwztPziRIgMyMVP1RUb9pBC+VDw9O2XCMhr/zi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abled",a.push('<li class="last '+o+'" original-title="Rocket quality Q4<br>Damage: 1,750,000 - Durability: 1 use"><img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADcAAAA3CAMAAACfBSJ0AAABQVBMVEUAAAATFSEaFRlSJQQUERsjFh8SFSAuFBE9KxgTFSETFiJNHgJUIQTvpB/rjRpYIQNgOAlaHgATFSETFiESFSAUFiMVGSZOGARLHwRTJAFyJACqSB2GHwXIUxv/pxSdJxDdeBlxMxeBHwASFCATFSIcHzNfFgC4LA6sKAfhhBf/pgTANBfjdxdoIgXsQDv8uSLUfAu1bQIkJ0IyMlR7HQD/zSLKNSX2rxvPMBHVMieHUATLcge0RDA9O2WHIACQIgRgOAJcJgduQAGtQRh5LgmWRQjEYg/ylwOcJgXwpRX+2ynmjB1OIAeiVAiPLBD3S1DwigqTVwCZNRDYhQDkkkG9WEfolQLEWjX7wh3vmRfDWBqfaQyAQAbIaEcFCy0tLioNHVBOWVHRjEHUS1PtrEr/wUy2VRNmVT+8qT3IvEMRFB/AZ7a1AAAAI3RSTlMAmyiYHBR0BQxE6jQdGYV2z1JaZ8OE3t+KYodsUDJSxNSr6Nzd+1wAAAJXSURBVEjH7ZXXctpAFIaFQEICY8CmGbc4rDoCid5M7810HMA9ccr7P0AkIM6dsps7z/jTjO6+/c/ZI+1iH7xHrNqDxoHdGbz6XLw8Q4o5MbOJEs9xknSKoNld1Wqdz2QikUjqHF476VfG6oDPRm5uIhwBrTnL1Xojv8i/aFr2ElozV3LqYNgUo88vkSx/Bq2V5cZ0uirMvn29S2VKFOTum6vjxqQppu/ms+iiVgrCav2NqrwWelrYfNRSZQucFizLdVUcLbWwXqGWzwWsUNN29nPrSW0Rnc2XLTE/rLuscHNjK2tFKSzTUaGwGuU3fhzKc7NysTEVhcJSFJuTxthlh9TYIs81W6JSay6UjWzGjX6TN+wsm+ClbCrfar0OB+Oq02grqb8r+Fm5zaWyWUmdqvWKy240cJJ8CzztsyVOSqUy3CSXKwcoo9Y8gP6TeyjktCozEse3i5WyGzOAMgF6v6rjk9BRalxGtxKs88BIw30AmOhtF+ealr4VJL5dSshmw84wGoBQKARsJI5dCL1OOplMr4YJlnVjhhwD3dNfwCWInWiye9sLD/yBA2PtCOhs3V8P63RS076Ew4faLhpjseiBu1LvH350u1Fdc2D/hvDuK2WYx6efSUhNjzTttFj8+vHpeSRoGhy4x7bTrmPMd+XCgXD2ewGjaXHmnrmikI5zXywejzEAAB+GAmFiYgyznaIFKY/AbWAHjXi/0ds0AEiMQIqk9oEmwmtCESmwxwOOEQvdByJ2SO2+cdKCIUKQmnZEYMjgNpt+YKBD0tj/YKWwD94LvwHHzmi2jtqstgAAAABJRU5ErkJggg==" alt=""><br><strong>'+x+"</strong></li>"),o=0!=w?"enabled":"disabled",a.push('<li class="last '+o+'" original-title="Rocket quality Q5<br>Damage: 2,500,000 - Durability: 1 use"><img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADcAAAA3CAMAAACfBSJ0AAABOFBMVEUAAABXJgUTFSFnIgUTFSJGHRETFSE3GA8YFBw4Gg8UFiMUFiLldSLulB1hIgHlgRh0MAETFSATFSEUFyRHGw5ZLwZUHAFKHANTKQRoPAIUFiK2Lx/ghBdaNgFVJAhRLwDbgxaWIQeoYBfqiB0SFSASFyocHjG4aQH5uBeKIQT1lQoeIztsGQDoPDTwpQ10RAGQQQm8egCzKg3kkA9WHgRcKwR6PAOqRBPohwoyM1bmgRf4S09MIQizOiDGZQ1uNwV6LQixVQv+sxv+ogCTMhAqLEg+PGb/0yKqJw3KMRubIwTrlyTQaxt/SgH6v0CIUgC7Sx7cgAP4rTa3RkB/aDj/yCH72DNIFAO+KwvgdCSgYAXVglLJcwPeiC/SfwHIZDa+UTMYLVLOPDfkNRiBgU5qUh7QVlu5W1lEBT8+AAAAJHRSTlMAOOtYQQZfDiQZplETKne7jnOI3KQnjmjc8DR9mUvB9t63st6myGXtAAACFElEQVRIx+3W13LaQBSAYVElQYLBYMCOS4pAvQKS6N30Xk23nfL+b5AdIpxLdq8ymfF/rW/Ozh5dLPbev8zlQjc46fD5HYjQ5fCz7XYz/wlN+VJCW3sVxRcUh9se5B67fBWz2ZYNgTlyqZVK5wETNRKBpYolZSRtf2bF1heEC8kN6HKtO+6vX8SmD9rd5VLKzuxO1v1KocnisMyW6im1AjNe/3qqJpQQrLvKFeldebLtj/f5girD3iYZTZZoTtpPthWuXNP9LkgWLg5qhlkZ7yej6qYYJSA3EFno6mZ46FS4YZ5eXdug7wScssodDmZ1pJSgGf4gDxTDZMy8saPle1iGhZI9dWMMTalQK8r+K1gWTgq6Wh0ZBq3quQgJvfCFwLbLCY4u6fK17dy+idMHH74mBa2llVW6l7w/OyxAkRa7SKzYZWvJ6gP5/L/sptxvTJIKmtZkhegdBPNY7DYhMbPOkBWEMAHBQB4neZzGNGadrrKIYBDMKvSZqzCNBpPp3kIsLUC99YOZzQF7uvh4nnmpv8Wm8zlg3yAYRhDuk4rzz9/7XKYDGExkwGL1x/TzNMMBBgkvLfaY5vkpYNDQ6w7G+TRggBMYSs54PV2Px2IU5URyhIfnj4y6xNAGeo8MhOEEjgDx0yYJt+cGQ+jGcsEg2lEJ+x9nd2NoOe1H5kR+MwBoMUToRWfWFi2GOpDA3vs/+g04OmAL4H/nJgAAAABJRU5ErkJggg==" alt=""><br><strong>'+w+"</strong></li>"),n="Small bomb<br>Damage: "+comma(g)+" - Durability: 1 use",-1!=F.indexOf("/999/21.png")?(v=parseInt(F.split("/999/21.png")[1].split("</strong>")[0].split('">')[1].trim()),n+="<br>"+F.split("/999/21.png")[2].split('class="extra"')[1].split("<span>")[1].split("</span>")[0]):v=0,o=0!=v?"enabled":"disabled",a.push('<li class="last '+o+'" original-title="'+n+'"><img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADcAAAA3CAMAAACfBSJ0AAABZVBMVEUAAAB3HRspFBhbKys1JSq4Ix0YDREtHR86Dw5VHR0WCQ4VCg57JiN5HRktHyU2LDE9MTV0Ih4tFxwvJSskExk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SwMui3L3Sn2Fy/WsEPImo9zpbLlVSwTo4uxCTb3LMRX7HkGeAbVvM+WCGYPBa10m1HJMZGitbK1NaxAhr85c65UUHk3a8pKFeFkBKW1O5fwxsb4yc6uDB1kacrsPia+5yyZAK8dxR6nXafb17HV5uSePpLwVpp5glSCJqccEDcpKeYepb45Pjvb5ZSpa6msAmjGVC6cU5ZnDdu5dfbn5fOEPZnSsMpHG2aFBIt33EgfeyfX43Ite5msAipFZwyp1UNaJA7aOx9th9DKLrtJiDOVCsRwYjju99Bwr8mXMtARQ0DMhXLY8yrn7/pb5ngIgtXk0M6oD6Kvu/q8D/jQBULFRLnDxFdj1gCvey/PBxwKttXns7kHxx9eYO7nA5uXZ2f73npnBy311dPvpsbvuwufjk9uTz8POAuZvHB1tY3DF2zu+/nJzdv5wmr+I/rpEaO/q9vr48iJI5oN/cHVzfLnpJ3OC2jobR1YDZG74nnoo8h//Cn4CaNOcOh5G0n4AAAAASUVORK5CYII=" alt=""><br><strong>'+comma(v)+"</strong></li>"),n="Big bomb<br>Damage: 5,000,000 - Durability: 1 use",-1!=F.indexOf("/999/22.png")?(k=parseInt(F.split("/999/22.png")[1].split("</strong>")[0].split('">')[1].trim()),n+="<br>"+F.split("/999/22.png")[2].split('class="extra"')[1].split("<span>")[1].split("</span>")[0]):k=0,o=0!=k?"enabled":"disabled",a.push('<li class="last '+o+'" original-title="'+n+'"><img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADcAAAA3CAMAAACfBSJ0AAABgFBMVEUAAABQPBdTOxOzmhNENBlIOiJFMxhINxtXQBQ9LBZFMRVDLxd9YBRELxVNNxZLNhg6JB9VPRiKahWigxRQPBVLNRhoURGFaRpsVBWRcxMkJx5xURUwLR1vWA3CmBRPOBVWPxZoTg43KwdeRhiBYhUWEQY/LBcxKAVdQhN2WhIcFQWTdBWaeBBKLxUmHQcrHwZFOAZYRxANCAQhFwstIwM8MgIvIg5wVBFTPRZQOg5iShRKOwtGMxJ3XhF3Vh0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ffBqQ1/zj0XIWz3IE+9GrAXmPP+E8fD0gL6/hDzPLcTy0s0H2i0t59vDlAPsN7fGQyH4/IGYPiOxqAF3J/jggp7TfDLDf0p6Mq8iBXYHsFwNyIftLPGZX8RSD7XPab9/Ec0K7nMRTyj79Gs//si9O43lM++RtPGYX8Zh9fhFPoj0gh7SfPD6Ph/aTkyHhunY40M6vPrwfzaNrWQ78Xjz64OhuPFrP8+xqPPiNKR+8FA8++B3a01aqwtsZIAAAAABJRU5ErkJggg==",GM_addStyle("#navig{width:122px;border:0px 1px 1px 0px solid #ddd;border-bottom-right-radius:3px;display:block;position:fixed;top:0px;left:0px;background:#fff;z-index:2001}#navig ul{height:50px;list-style:none}#navig li.enabled{width:40px;background-image:url("+_+");background-position:1px center;background-repeat:no-repeat;cursor:default;float:left;height:50px;overflow:hidden;position:relative;text-align:center}#navig li.disabled{width:40px;background-image:url("+_+");background-position: -82px 0;background-repeat:no-repeat;cursor:default;float:left;height:50px;overflow:hidden;position:relative;text-align:center}#navig li:hover{background-position:-40px 0}#navig li strong,#navig li .maxCap{margin-left:3px;vertical-align:bottom;font-family:Arial,Helvetica,sans-serif;color: #578B4D;font-size:11px;text-align:right;text-shadow: 0 1px 0 #C4E8B3}#navig li.disabled strong{color:#a6a4a4!important}#navig li img{width:29px;height:29px;vertical-align:middle;margin-top:3px;margin-bottom:-3px}#navig li.disabled img{opacity:0.3}"),S="",B=0,R="122px;",C=0,M=0,1==options.AllStock)for(C=0;C<a.length;C++)S+=a[C]
else{for(C=0;C<a.length;C++)0!=parseInt($(a[C]).find("strong").text())&&(B+=1)
if(12>=B){for(C=0;C<a.length;C++)0!=parseInt($(a[C]).find("strong").text())&&(S+=a[C])
R="42px"}else if(24>=B){for(C=0;C<a.length;C++)0!=parseInt($(a[C]).find("strong").text())&&(S+=a[C])
R="82px"}else for(C=0;C<a.length;C++)0!=parseInt($(a[C]).find("strong").text())&&(S+=a[C])}$("#navig").remove(),$("body").before('<div id="navig"><ul>'+S+"</ul></div>"),$("#navig").css({width:R}),$("#navig li.disabled").hover(function(){$(this).find("img").css({opacity:1})},function(){$(this).find("img").css({opacity:.3})}),$("#navig ul li").tipsy({gravity:"nw",html:!0})}options.storageCapacity&&($(".storageInfo").remove(),T=$(F).find(".area.storage strong").text().split("/")[1].split(")")[0].trim(),e=$(F).find(".area.storage strong").text().split("/")[0].split("(")[1].trim(),i=parseInt(T.replace(/,/g,""))-parseInt(e.replace(/,/g,"")),$(".currency_amount").after('<div style="clear:both;float:left;height:22px;margin:-1px 0 10px 6px;width:142px;color:#585858;font-size:12px" class="storageInfo"><p><img style="float:left;margin:0 6px 0 2px" alt="StorageItems" src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAyVBMVEUAAAAyMzfS1t4uLzQwMjYoKSktLS1lZ2ubqcYtLS0rKytAR1Y/RVJKUmfFzNgsLCwyMjJBQUEyMjLd4Obc3+QoKjC/x9U6OjuFipRjZmpLUmbCydizvdCNkZyir8gsLCwqKipSW3GZqccvLzH19fVDSVheZ352gpxYYHelscjm6OuvvNNocInu7++drMm4wtfg4eXy8vJPV2tnb4TFztxRU1ZCTmdLVGo1Q12XpsQzMzNcXmRkZ21ucXgmNVKhq77CysGYnqq/yNh4k25rAAAAH3RSTlMAWw90TQlTAYYYKMzfpD/oY9+RQ49CfIiCNeiU2Z3XxuSTsAAAALBJREFUGNNtz0cWgjAARdFYERDsvZAECKH3Ztf9L8qAh+OEP3t39kHLuP5s3hEG/x6qinpRJ1O+aaVZj+cYdCCsCyowTTcCB/a6+iN4Nb3n+wQkihixvpkY4/IMJJQTwuhu4hJjbwTG0SNDMYlN7L2SxK8AoaJwDM9OXE1joOeI0swxbEvTaujpESVxBWEYup8jAHxfRKQC17WCgwzYBiuRGn4QLBddrvmz265lVm37Aq4DGPv4ctamAAAAAElFTkSuQmCC" /><strong>'+e+"/"+T+"</strong><br><span>Free: "+comma(i)+"</span></p></div>"))}})}function addLock(){var t,e,i,a=!1,n=$('input[id^="delete_message_"]').attr("id").split("_")[2],o=GM_getValue("eRS.locked.messages")
if("undefined"!=typeof o){for(e=JSON.parse(o),i=0;i<e.length;i++)e[i]==n&&(a=!0,t=i)
a===!0?($(".report").before('<a href="#" title="Unlock message so it can be deleted when multiple messages are selected" class="fluid_blue_light_medium" id="eRS_Unlock"><span>Unlock Message</span></a>'),$(".msg_title_container #eRS_Unlock").click(function(){e.splice(t,1),GM_setValue("eRS.locked.messages",JSON.stringify(e)),window.location.href=window.location})):($(".report").before('<a href="#" title="Lock message so it can\'t be deleted when multiple messages are selected" class="fluid_blue_light_medium" id="eRS_Lock"><span>Lock Message</span></a>'),$(".msg_title_container #eRS_Lock").click(function(){e.push(n),GM_setValue("eRS.locked.messages",JSON.stringify(e)),window.location.href=window.location}))}else e=[],$(".report").before('<a href="#" title="Lock message so it can\'t be deleted when multiple messages are selected" class="fluid_blue_light_medium" id="eRS_Lock"><span>Lock Message</span></a>'),$(".msg_title_container #eRS_Lock").click(function(){e.push(n),GM_setValue("eRS.locked.messages",JSON.stringify(e)),window.location.href=window.location})
$("#eRS_Lock,#eRS_Unlock").tipsy({gravity:"s"})}function deleteMessages(t){var e,i,a=$(t).parents("form"),n=GM_getValue("eRS.locked.messages")
if("undefined"!=typeof n)for(e=JSON.parse(n),i=0;i<e.length;i++)$('input[id^="delete_message_"]').each(function(){$(this).val()==e[i]&&(this.checked=!1)})
"message_form"==a[0].id&&($(a[0]).hide(),$("#sending_message_indicator").show()),$.post(a.attr("action"),a.serialize(),function(){window.location.href.indexOf("/messages-paginated")>0?window.location=window.location.href:document.referrer.indexOf("/messages-paginated")>0?window.location=document.referrer:window.location.href="http://www.erepublik.com/en/main/messages-inbox"},"html")}function unb(){unsafeWindow.display_popup=void 0,unsafeWindow.ajaxify_messages=function(){return!0},$j(".message_get").each(function(t,e){$j(e).unbind("click")}),$(".fluid_blue_dark_medium,.fluid_blue_light_medium,.message_get").each(function(){"#"!=$(this).attr("href")||"message_delete_trigger"==$(this).attr("name")?$(this).hasClass("message_get")&&!$(this).hasClass("subject")&&"message_delete_trigger"==!$(this).attr("name")&&window.location.href.indexOf("/messages-read/")>0?$(this).bind("click",function(){window.location=document.referrer}):"message_delete_trigger"==$(this).attr("name")?$(this).bind("click",function(){var t=!1;("undefined"==typeof $(".message_ajax_container #select_all")[0]||1==$(".message_ajax_container #select_all")[0].checked)&&(t=!0),$('input[id^="delete_message_"]').each(function(){1==this.checked&&(t=!0)}),1==t&&deleteMessages(this)}):$(this).bind("click",function(){window.location="http://www.erepublik.com"+$(this).attr("href")}):$j("body").ajaxComplete(function(t,e,i){-1!=i.url.indexOf("messages-delete")?window.location.href=document.referrer:-1!=i.url.indexOf("messages-compose")&&unb()})})}function donateEverywhere(t){function e(){$(".member_listing thead tr th").attr("style","padding:0px 0px 8px 10px!important"),$(".member_listing tbody tr").each(function(){var t=$(this).find(".avatar .current_location a").attr("href").split("/")[4]
t!=eRS.citizenId&&($(this).find(".avatar").attr("style","padding:2px 0px 3px 0px; width:208px!important;"),$(this).find(".avatar .current_location").after('<br><div class="citizen_actions_com" style="width:208px;padding-left:50px;text-align:left;margin-top:5px"><table><tr><td style="height:25px"><a class="action_message_com" style="display:inline" href="http://www.erepublik.com/en/main/messages-compose/'+t+'" original-title="Send message">Send message</a></td><td style="height:25px"><a class="action_donate_comI" style="display:inline" href="/en/economy/donate-items/'+t+'" original-title="Donate Items">Donate</a></td><td style="height:25px"><a class="action_donate_comM" style="display:inline" href="/en/economy/donate-money/'+t+'" original-title="Donate Money">Donate</a></td></tr></table></div>'))}),$(".citizen_actions_com a").tipsy({gravity:"s"})}function i(){var t,a,n
0==$("#regiments_lists_msdd").length?(clearTimeout(t),t=setTimeout(i,500)):(e(),a=$("#regiments_lists :selected").val(),n=$("#regiments_lists_child ._msddli_").length>0?"._msddli_":"a",$("#regiments_lists_child "+n).click(function(){a!=$("#regiments_lists").val()&&(window.location.href="http://www.erepublik.com"+$("#regiments_lists option[value='"+$("#regiments_lists").val()+"']").attr("url"))}))}var a,n,o,r="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAABLCAMAAAABOfS3AAABVlBMVEUAAAD////C6fj////C6fhXrduo4fhXrduo4fj////x+/5Xrduo4fh/f3/NzczC6fjNkzERERHs7OwxMTHaojn+///lv3scHBz95avzyGPooS7ftWnvvEHsuUkmJibCys3W2Nl4fX5zdHXqqDf53pv6+/zVmS3moTvYpErvwnPR0dHN1NnJ5/Xo9/1UVVZcXWHd5e3QmDfd3d329fP2x1bHtpnHoV3dq1f/8szjrTzRmEL66Ve4bxvlmir21IHwtDHm7fX/6Ev/7kTi9fyJiYlmZ2oDAwO0ucB6v+O86PrwypHHxsLz27NCQ0Pv8/3NsHrksUjKwrDwwVPjvHLVoETBqIDsvl3MkSrBr43Pkyfw1ZzBfSrz2KL/3DHszFL4xjTTqGLSn13tqC3zrDr65YH41kTutj346mz3vyH955brrlz91VWJuMvk5ORHjbOjpabfu5C3098lo0PyAAAACnRSTlMA8fH/gPHxgICAMeqNSQAAAvtJREFUSMeVlOlT2kAchrcGDwJJAYGAgIEoHgU8wNZbUSpetbe97/u2/f+/dH8R8+ruhpl9nckwz85DPuA+jLFoxhCWibI+/BoAdi3gmRt8l3nUMFIWX4seZ8FJlHN/o+Ojo90yOOPvtU4sa+7EsSwvibdnLgTbMMbL4MzggsU/eE3+KhIwSaD1BJqeUOV/WsLt43lNoetoCl6YsGdZSVFIOk7S6zr8OTsxPXHnirBv8RngjB70Y/KHffy3+HV9fcIQVm0dgTPwo1Kp9OXHzusxIIELwtjn3Z3dzdkPm0ACF4Tp/Pef36Y/vcUbBA7Bq9Fz7eX75e2PW9sQBA5hL5NdzmYLj2fWpt69eb6RIabigTB/N5ebnMytvCgsbszMPC0QU3EI7aV8Pp9Iz+YKieyrlUfEVDwQ5ham0vcfLpXSU4uTW0/S94iFcValg/0HN28l0qvFYnF18dT+TT9WGGcd/rSbrVTT5meJxDM7ZdA6YZxFTKO3VtO2CdPMSBh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SQcOI51DpOYDIyZDpNogHHNcR2rSYwznt64Pb/aPLdYctp/mMQEMAD74YRFesB5LGH0732Ks5uYZA/tP62BnNa5zmqZ5/XqH3njCEqQa3lJAAAAAElFTkSuQmCC"
GM_addStyle(".citizen_actions_com a{background-image:url("+s+");display:inline;float:left;height:25px;margin-right:4px;text-indent:-9999px;width:24px}.citizen_actions_com .action_message_com{background-position:-24px 0}.citizen_actions_com .action_donate_comM,.citizen_actions .action_donate_comM{background-image:url("+r+")!important;background-position:0 0}.citizen_actions_com .action_donate_comI,.citizen_actions .action_donate_comI{background-image:url("+r+")!important;background-position:-24px 0}.citizen_actions_com .action_donate_comM:hover,.citizen_actions .action_donate_comM:hover{background-position:0 -25px}.citizen_actions_com .action_donate_comI:hover,.citizen_actions .action_donate_comI:hover{background-position:-24px -25px}.citizen_actions_com .action_donate_comM:active,.citizen_actions .action_donate_comM:active{background-position:0 -50px}.citizen_actions_com .action_donate_comI:active,.citizen_actions .action_donate_comI:active{background-position:-24px -50px}.citizen_actions_com .action_message_com:hover{background-position:-24px -25px}.citizen_actions_com .action_message_com:active{background-position:-24px -50px}"),1==t?($("#comments_div .comment-holder").each(function(){$(this).find(".citizen_actions_com").remove()
var t=$(this).find(".nameholder").attr("href").split("/")[4].trim()
t!=eRS.citizenId&&($(this).hasClass("indent-level-0")?(a="article_comment_posted_at",n="margin-top:20px;"):(a="nameholder",n="float:right;"),$(this).find("."+a).first().after('<div class="citizen_actions_com" style="width:150px; '+n+'"><a class="action_message_com" href="http://www.erepublik.com/en/main/messages-compose/'+t+'" original-title="Send message">Send message</a><a class="action_donate_comI" href="/en/economy/donate-items/'+t+'" original-title="Donate Items">Donate</a><a class="action_donate_comM" href="/en/economy/donate-money/'+t+'" original-title="Donate Money">Donate</a></div>'))}),$(".citizen_actions_com a").tipsy({gravity:"s"})):2==t?(o=window.location.href.split("/")[6].trim(),"0"!=o&&($(".msg_title_container").append('<div class="citizen_actions_com" style="padding-top:0px;float:right"><a class="action_donate_comI" href="/en/economy/donate-items/'+o+'" original-title="Donate Items">Donate</a><a class="action_donate_comM" href="/en/economy/donate-money/'+o+'" original-title="Donate Money">Donate</a></div>'),$(".citizen_actions_com a").tipsy({gravity:"s"}))):3==t?(unb(),$(".fluid_blue_dark_medium,.fluid_blue_light_medium,.message_get").each(function(){"#"==$(this).attr("href")&&$(this).bind("click",function(){setTimeout(function(){donateEverywhere(3)},1e3)})}),$(".citizen_actions_com").remove(),$(".message_item_container").each(function(){var t=$(this).find(".message_container .coloured .nameholder a:first").attr("href").split("/")[4]
t!=eRS.citizenId&&$(this).find(".avatarholder").append('<div class="citizen_actions_com" style="width:60px;margin-left:-8px;margin-top:0px;padding-top:2px"><a class="action_donate_comI" href="/en/economy/donate-items/'+t+'" original-title="Donate Items">Donate</a><a class="action_donate_comM" href="/en/economy/donate-money/'+t+'" original-title="Donate Money">Donate</a></div>'),$(".citizen_actions_com a").tipsy({gravity:"s"})})):5==t&&(unsafeWindow.changeRegiment=void 0,i())}function ShowRememberDonate(t){var e,i,a,n,o
if(1==t)$(".special.padded").append('<div style="float: right; padding-top: 3px;">"Remember donation quantity" enabled</div>'),e=GM_getValue(eRS.citizenId+".eRS_donateItem"),i="undefined"!=typeof e?JSON.parse(e):{1:{1:0,2:0,3:0,4:0,5:0,6:0,7:0},2:{1:0,2:0,3:0,4:0,5:0,6:0,7:0}},$(".offers.largepadded tr:not(:first-child)").each(function(){var t=$(this).find("img").attr("src").split("/")[6].trim(),e=$(this).find("img").attr("src").split("/")[7].split(".png")[0].split("q")[1].trim()
$(this).find(".input").val(i[t][e])})
else if(2==t)$(".special.padded").append('<div style="float: right; padding-top: 3px;">"Remember donation quantity" enabled</div>'),e=GM_getValue(eRS.citizenId+".eRS_donateMoney"),i="undefined"!=typeof e?JSON.parse(e):{1:0,2:0},$(".offers.largepadded.donate_form tr:not(:first-child)").each(function(){var t=$(this).find("img").attr("alt")
$(this).find(".input").val("GOLD"==t?i[2]:i[1])})
else if(3==t){if(a=[],n="",e=GM_getValue("eRS_donation_logger"),"undefined"==typeof e)n="<strong>No donation history.</strong>"
else for(a=JSON.parse(e),o=0;o<a.length;o++)1==a[o].type&&(n+="<strong style='display:inline!important;'>["+a[o].day+"/"+a[o].month+"/"+a[o].year+" at "+a[o].hour+":"+a[o].min+":"+a[o].sec+"]</strong> You donated "+a[o].amount+" Q"+a[o].quality+" "+a[o].txt+" to <a href='http://www.erepublik.com/"+LANG+"/citizen/profile/"+a[o].id+"'>"+a[o].name+"</a><br>"),2==a[o].type&&(n+="<strong style='display:inline!important;'>["+a[o].day+"/"+a[o].month+"/"+a[o].year+" at "+a[o].hour+":"+a[o].min+":"+a[o].sec+"]</strong> You donated "+a[o].amount+" "+a[o].txt+" to <a href='http://www.erepublik.com/"+LANG+"/citizen/profile/"+a[o].id+"'>"+a[o].name+"</a><br>")
$(".citizen_mass_destruction").after('<div style="clear:both;"></div><h3>Donation history</h3><div class="citizen_mass_destruction"><em>'+n+"</em></div>")}}function RememberDonate(t,e){var i,a,n,o,r,s,l,d,c,p,A=[],g=GM_getValue("eRS_donation_logger")
"undefined"!=typeof g&&(A=JSON.parse(g)),i=e.parent().parent(),a=$(".citizen_profile_header h2:not(span)").text().trim(),n=window.location.href.split("/")[6],o=new Date,1==t?(g=GM_getValue(eRS.citizenId+".eRS_donateItem"),r="undefined"!=typeof g?JSON.parse(g):{1:{1:0,2:0,3:0,4:0,5:0,6:0,7:0},2:{1:0,2:0,3:0,4:0,5:0,6:0,7:0}},$(".offers.largepadded tr:not(:first-child)").each(function(){var t=$(this).find("img").attr("src").split("/")[6].trim(),e=$(this).find("img").attr("src").split("/")[7].split(".png")[0].split("q")[1].trim()
r[t][e]=$(this).find(".input").val()}),s=i.find("input#[id^=donate_item_]").val(),l=i.find("td:last input:first").attr("quality"),d=i.find("td:last input:first").attr("industry"),c=1==d?"food":"weapons",parseFloat(s)>0&&(30==A.length&&A.shift(),A.push({type:1,day:o.getDate()<10?"0"+o.getDate():o.getDate(),month:parseInt(o.getMonth())+1<10?"0"+(parseInt(o.getMonth())+1):parseInt(o.getMonth())+1,year:o.getFullYear(),hour:o.getHours()<10?"0"+o.getHours():o.getHours(),min:o.getMinutes()<10?"0"+o.getMinutes():o.getMinutes(),sec:o.getSeconds()<10?"0"+o.getSeconds():o.getSeconds(),amount:s,txt:c,quality:l,name:a,id:n}),GM_setValue("eRS_donation_logger",JSON.stringify(A))),GM_setValue(eRS.citizenId+".eRS_donateItem",JSON.stringify(r))):2==t&&(g=GM_getValue(eRS.citizenId+".eRS_donateMoney"),r="undefined"!=typeof g?JSON.parse(g):{1:0,2:0},$(".offers.largepadded.donate_form tr:not(:first-child)").each(function(){var t=$(this).find("img").attr("alt")
"GOLD"==t?r[2]=$(this).find(".input").val():r[1]=$(this).find(".input").val()}),s=i.find("input#[id^=donate_money_]").val(),p=i.find("td:first").text().trim(),parseFloat(s)>0&&(30==A.length&&A.shift(),A.push({type:2,day:o.getDate()<10?"0"+o.getDate():o.getDate(),month:parseInt(o.getMonth())+1<10?"0"+(parseInt(o.getMonth())+1):parseInt(o.getMonth())+1,year:o.getFullYear(),hour:o.getHours()<10?"0"+o.getHours():o.getHours(),min:o.getMinutes()<10?"0"+o.getMinutes():o.getMinutes(),sec:o.getSeconds()<10?"0"+o.getSeconds():o.getSeconds(),amount:s,txt:p,name:a,id:n}),GM_setValue("eRS_donation_logger",JSON.stringify(A))),GM_setValue(eRS.citizenId+".eRS_donateMoney",JSON.stringify(r)))}function NewsCategories(){$(".mini_news_categories span").eq(0).remove(),$(".mini_news_categories ul li").eq(0).before('<li><a href="javascript:;" id="eRSNews" rel="international" class="switchers" original-title="International"><img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAulBMVEUAAAD3+/yTy+DX7PO13ey73+yn1+fy+fve8Pb3+/2k1+ys4/gqk7Kn2Oyf1eqPyt6k3fV7yeaT0ekdiqlgrsWj1Omc0ONuw+Oa2PBttcoymbe53uyg2e6S1e8jjqx1v9mLzuh3yeiZ0+qFz+12uMw6oceExNlnssh8xeBYrsxqvNk4nLxTqcRZrMVIo8B0u9Gx2umj0+VWs9WKxdhfss5IrNF7vtJCp8uByOKJyOFFpsZlt9ODyuVgvd/N+Sw+AAAACnRSTlMAH8lGzNDLDUYZxuiSFgAAANpJREFUGNMtz0digzAURVElAQxCIFSopvcO7jX731YU22f2/+hdIGjqduc4u62qgZeNbNuGYNvy5nV/728QQsOA0JbER1Oq6tIcHAhN03TkL/DTBdUJHfPQxBgfsAqc4DKc9r8kxHVZlucVLDFCd9d1r2ff9xsfg5Gxu5tlWfeoF875AnjQkaIoCIpHPjWTD26P3iVRRBhDM0+TGqzkOaA+8tpjHCReugI1TWcWt5ZOUXD1qAo0ifZssnQ9HOYnlTQxXUnGUBeSNlLeMVLuWYKX/6d88k1KzXf+H3rGF2DeE35iAAAAAElFTkSuQmCC" alt="International" title="International"></a></li><li><a href="javascript:;" id="eRSNews" rel="latest" class="switchers" original-title="Latest"><img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAA9lBMVEX/AACUlpv///+qr7e9xMmZmqDbXTQAAACqrLCUlZmssbegoqXq7/D//oqbnaL0ExKmp6unqaz/94e9hm/x8/Ows7alo6+LjJDg5+j4eDT6ez3M0NP51lX5czrm7OvN1db7ayr31XnxGgD4USKveFf8OBbKcFT/fUejpam/xczDxtX4+/vkMTLHx9yfm7H74Gj/Egr/j1X55XqvpKL/IBPjj2rlVDf8cDS4emb/ey6lY0buKgjeKg7Pe1fW1dj15N6glZS/VRyRiIfMqW/p2tT/nWPc0c7AfV//dkq9kWqnelWdf2yUdmS0nWnLQyvR0c7NTU7eQkNHZ8bZAAAAx0lEQVQY013M124CMRCF4bGJE++a3WyHhBZqSOi9997h/V+GMQgh8V/MxafRgWzm/VZGCFf1+VQQ9jqdSCQXNh2KmAR9lQaAXqdrUBYNSVj2EZKTqU4VJxpTgY2aCJXZ3KEhzrkL40YE4bs6qHFumpRBO/6DEAnHbc4NI8cgZUn4ClspkfU86sJWa0koaRs/hh977VduWNqO44jDQDlIKNc/sYvp14GcjvAobwSLQILnJ3gS3rC///stFBgEiILdLyEsAB8vXQHcPhQNEMH+lwAAAABJRU5ErkJggg==" alt="Latest" title="Latest"></a></li>'),$(".mini_news_categories ul li #eRSNews").click(function(){var t,e,i,a,n,o,r,s,l,d="",c="",p=""
$(".media_widget li").find(".active").removeClass("active"),$(".media_widget").addClass("preload"),$(this).addClass("active"),l=$(this).attr("rel"),c="latest"==l?"latest/all/"+eRS.country+"/1":l,GM_xmlhttpRequest({method:"GET",url:"http://www.erepublik.com/"+LANG+"/main/news/"+c,onload:function(A){var g=A.responseText.replace(/src=/g,"tmpsrc=").replace(/\.css/g,"").replace(/\.js/g,"").replace(/url\(/g,""),m=$(g).find("#content").html()
$(m).filter('[class="holder bordersep"]:lt(5)').each(function(){t=$(this).find(".rankholder .value").text().trim(),e=$(this).find(".holder .dotted").attr("href"),i=$(this).find(".holder .dotted").text(),a=$(this).find(".article_details small").eq(0).text().trim(),n=$(this).find(".article_details small").eq(1).find("a").text().trim(),o=$(this).find(".article_details small").eq(1).find("a").attr("href"),r=$(this).find(".article_details small").eq(2).text().trim(),s=$(this).find(".article_details small").eq(2).find("img").attr("tmpsrc"),news=$(this).find(".newspaperinf .nameholder .dotted").text().trim(),d+="<li>",d+='<div class="no_votes"><strong>'+t+"</strong><small>votes</small></div>",d+='<div class="article_entry"><div>',d+='<span><img class="countryImg" style="vertical-align:middle;float:left" src="'+s+'" original-title="'+r+'"><span>&bull;</span><em>'+n+'</em></span><a href="'+e+'">'+i+"</a>",d+='<span><em class="author">'+news+'</em><span>&bull;</span><em class="time_posted">'+a+"</em></span>",d+="</div></div>",d+="</li>"}),$("#citizenship_news").html(""),$("#citizenship_news").html(d),$("#citizenship_news li span .countryImg").tipsy({gravity:"s"}),$("#residence_news").length>0?"latest"==l?(d="",p="latest/all/"+$("#perma_second").attr("value")+"/1",GM_xmlhttpRequest({method:"GET",url:"http://www.erepublik.com/"+LANG+"/main/news/"+p,onload:function(A){var g=A.responseText.replace(/src=/g,"tmpsrc=").replace(/\.css/g,"").replace(/\.js/g,"").replace(/url\(/g,""),m=$(g).find("#content").html()
$(m).filter('[class="holder bordersep"]:lt(5)').each(function(){t=$(this).find(".rankholder .value").text().trim(),e=$(this).find(".holder .dotted").attr("href"),i=$(this).find(".holder .dotted").text(),a=$(this).find(".article_details small").eq(0).text().trim(),n=$(this).find(".article_details small").eq(1).find("a").text().trim(),o=$(this).find(".article_details small").eq(1).find("a").attr("href"),r=$(this).find(".article_details small").eq(2).text().trim(),s=$(this).find(".article_details small").eq(2).find("img").attr("tmpsrc"),news=$(this).find(".newspaperinf .nameholder .dotted").text().trim(),d+="<li>",d+='<div class="no_votes"><strong>'+t+"</strong><small>votes</small></div>",d+='<div class="article_entry"><div>',d+='<span><img class="countryImg" style="vertical-align:middle;float:left" src="'+s+'" original-title="'+r+'"><span>&bull;</span><em>'+n+'</em></span><a href="'+e+'">'+i+"</a>",d+='<span><em class="author">'+news+'</em><span>&bull;</span><em class="time_posted">'+a+"</em></span>",d+="</div></div>",d+="</li>"}),$("#residence_news").html(""),$("#residence_news").html(d),$(".media_widget").removeClass("preload"),$(".more_news").attr("href","http://www.erepublik.com/en/main/news/"+p),$("#go1").bind("click",function(){$(".media_widget li").find(".active").attr("rel")==l&&$(".more_news").attr("href","http://www.erepublik.com/en/main/news/"+c)}),$("#go2").bind("click",function(){$(".media_widget li").find(".active").attr("rel")==l&&$(".more_news").attr("href","http://www.erepublik.com/en/main/news/"+p)}),$("#residence_news li span .countryImg").tipsy({gravity:"s"})}})):($("#residence_news").html(""),$("#residence_news").html(d),$(".media_widget").removeClass("preload"),$(".more_news").attr("href","http://www.erepublik.com/en/main/news/"+l),$("#go1").bind("click",function(){$(".media_widget li").find(".active").attr("rel")==l&&$(".more_news").attr("href","http://www.erepublik.com/en/main/news/"+c)}),$("#go2").bind("click",function(){$(".media_widget li").find(".active").attr("rel")==l&&$(".more_news").attr("href","http://www.erepublik.com/en/main/news/"+c)}),$("#residence_news li span .countryImg").tipsy({gravity:"s"})):($(".media_widget").removeClass("preload"),$(".more_news").attr("href","http://www.erepublik.com/en/main/news/"+l),$("#go1").bind("click",function(){$(".media_widget li").find(".active").attr("rel")==l&&$(".more_news").attr("href","http://www.erepublik.com/en/main/news/"+c)}),$("#go2").bind("click",function(){$(".media_widget li").find(".active").attr("rel")==l&&$(".more_news").attr("href","http://www.erepublik.com/en/main/news/"+c)}))}})})}function BetterIgm(){var t,e=GM_getValue("eRS"+eRS.citizenId+"_Igm")
t="undefined"==typeof e?{sub:"",mess:""}:JSON.parse(e),$("#message_form").append('<a href="javascript:;" id="igmClear" original-title="Forget last remembered message" class="fluid_blue_dark_medium" style="margin-right:10px;float:right"><span class="bold">Clear</span></a><a href="javascript:;" id="igmSave"  original-title="Remember this message" class="fluid_blue_dark_medium" style="margin-right:10px;float:right"><span class="bold">Save</span></a><a href="javascript:;" id="igmFill" original-title="Fill with last remembered message" class="fluid_blue_dark_medium" style="margin-right:10px;float:right"><span class="bold">Fill</span></a>'),$("#igmClear,#igmFill,#igmSave").tipsy({gravity:"s"}),$("#igmFill").click(function(){$("#citizen_subject").val(t.sub),$("#citizen_message").val(t.mess)}),$("#igmSave").click(function(){t.sub=$("#citizen_subject").val(),t.mess=$("#citizen_message").val(),GM_setValue("eRS"+eRS.citizenId+"_Igm",JSON.stringify(t))}),$("#igmClear").click(function(){t.sub="",t.mess="",GM_setValue("eRS"+eRS.citizenId+"_Igm",JSON.stringify(t))})}function AutoBot(){function t(){var t=($j("#heal_btn"),$j("#DailyConsumtionTrigger")),e=$j("#eatload").css("display")
return!$j("input#multihit_food").is(":checked")||t.hasClass("disabled")||t.hasClass("buy")||t.hasClass("energy")||"none"!=e?!1:!0}function e(){function e(){$j("#DailyConsumtionTrigger").addClass("load"),$j.getJSON(c,{},function(t){unsafeWindow.energy.processResponse(t),$j("#DailyConsumtionTrigger").removeClass("load"),i()})}function i(){a<unsafeWindow.globalNS.userInfo.wellness?unsafeWindow.globalNS.userInfo.wellness>=10?(clearTimeout(l),l=setTimeout("jQuery.fn.multiHIT()",250)):t()?e():20==n?$("#multihit_start").click():setTimeout(i,1e3):setTimeout(i,1e3)}var a=parseInt($("#current_health").text().split("/")[0].trim()),n=0
e()}function i(){var t="/en/military/change-weapon"
unsafeWindow.ERPK.disableAllButtons(),$j.post(t,{_token:unsafeWindow.SERVER_DATA.csrfToken,battleId:unsafeWindow.SERVER_DATA.battleId},function(t){if(-1!==$j(".fighter_weapon_image:last").attr("src").indexOf("q0"),unsafeWindow.currentWeaponId!==t.weaponId||unsafeWindow.hasBazookaAmmo!=t.hasBazookaAmmo){{$j(".listing span").eq(0).clone()}$j("#scroller span:last img").attr("src",t.weaponImage)}return unsafeWindow.ERPK.enableAllButtons(),-1!==$j(".listing span img").eq(-1).attr("src").indexOf("q10")?(a=!1,void $j("button#multihit_start").html("Start")):(clearTimeout(l),void(l=setTimeout("jQuery.fn.multiHIT()",250)))},"json")}var a=!1,n=0,o=0,r=0,s=!1,l=0,d=$j("div.user_health input[type=hidden]").attr("id"),c="http://www.erepublik.com/"+LANG+"/main/eat?format=json&_token="+$j("#"+d).val()+"&jsoncallback=?"
$j("div#enemy_defeated").before('<div id="MHP" style="z-index:99;position:relative;margin:-190px 0 0 33px;float:left;clear:both;padding:5px;background-color:#262620;border-radius:4px;opacity:0.8;font-weight:bold;border:1px solid #000;color:#FFF;text-align:left;font-size:10px"><big>Kills:&nbsp;</big><input id="multihit_count" style="text-align:right" type="text" size="3" maxlength="4" value="25" />&nbsp;<button id="multihit_start" style="margin-top:0px;margin-left:0px;margin-bottom:0px;position:relative">Start</button><br />&nbsp;<input type="checkbox" id="multihit_food" name="multihit_food" checked="checked"><label for="multihit_food">&nbsp;Eat food</label><br/>&nbsp;<input type="checkbox" id="multihit_bazooka" name="multihit_bazooka" checked="checked"><label for="multihit_bazooka">&nbsp;Dont use Bazooka</label><br/></div>'),$j("div#MHP").hide(),$j("#pvp_battle_area .player.left_side").before('<div id="autoBot" style="font-weight:bold;color:white;padding:5px 3px 5px 3px;top:315px;left:220px;position:absolute;text-align:center;width:50px;background-color:transparent;border:1px solid #999999;border-radius: 0 5px 5px 0;box-shadow: 0px 0px 2px #ff7373;background-image:linear-gradient(to right, #bf3030, #a60000);cursor:pointer">AutoBot</div>'),$j("#autoBot").click(function(){$j(this).text("ON"==$j(this).text()?"AutoBot":"ON"),$j("div#MHP").is(":visible")?$j("div#MHP").hide():$j("div#MHP").show()}),unsafeWindow.battleFX.hit=function(){return a&&(o++,s=!1,clearTimeout(l),l=setTimeout("jQuery.fn.multiHIT()",1001)),!1},unsafeWindow.battleFX.blow=function(){return a&&(r++,s=!0),!1},unsafeWindow.jQuery.fn.getWell=function(){var t=($j("#heal_btn"),$j("#DailyConsumtionTrigger"))
!$j("input#multihit_food").is(":checked")||t.hasClass("disabled")||t.hasClass("buy")||t.hasClass("energy")||($j("#heal_btn small").hide(),e())},unsafeWindow.jQuery.fn.multiHIT=function(){if(unsafeWindow.globalStop||n==o)return unsafeWindow.ERPK.enableAllButtons(),a=!1,void $j("button#multihit_start").html("Start")
if(unsafeWindow.ERPK.canFire())$j("input#multihit_bazooka").is(":checked")&&-1!==$j(".listing span img").eq(-1).attr("src").indexOf("q10")?i():unsafeWindow.shoot()
else{if(!t())return unsafeWindow.ERPK.enableAllButtons(),a=!1,void $j("button#multihit_start").html("Start")
unsafeWindow.jQuery.fn.getWell()}},$j("button#multihit_start").click(function(){a?(clearTimeout(l),unsafeWindow.ERPK.enableAllButtons(),a=!1,$j("button#multihit_start").html("Start")):(n=$j("input#multihit_count").val(),n>0&&(o=0,r=0,s=!1,a=!0,$j("button#multihit_start").html("Stop"),unsafeWindow.jQuery.fn.multiHIT()))})}function QuickMarket(){var t,e,i,a,n
for(GM_addStyle(".eRS_quickMarket{display:none!important;border-top:1px solid #ccc;position:absolute!important;top:0px!important}.eRS_quickMarket li img{width:18px;height:20px;vertical-align:middle;margin-bottom:2px}"),t="",e="",i="",a=1;3>=a;a++)for(n=1;7>=n;n++)1==a&&7>=n&&(t+='<li><a href="http://www.erepublik.com/'+LANG+"/economy/market/"+img_country[eRS.country].id+"/1/"+n+'/citizen/0/price_asc/1"><img src="'+itemicons[a][n]+'"> Food Q'+n+"</li>",7==n&&(t+='<li><a href="http://www.erepublik.com/'+LANG+"/economy/market/"+img_country[eRS.country].id+'/7/1/citizen/0/price_asc/1"><img src="'+frmicon+'"> Food Raw</li>')),2==a&&7>=n&&(e+='<li><a href="http://www.erepublik.com/'+LANG+"/economy/market/"+img_country[eRS.country].id+"/2/"+n+'/citizen/0/price_asc/1"><img src="'+itemicons[a][n]+'"> Weapon Q'+n+"</li>",7==n&&(e+='<li><a href="http://www.erepublik.com/'+LANG+"/economy/market/"+img_country[eRS.country].id+'/12/1/citizen/0/price_asc/1"><img src="'+wrmicon+'"> Weapon Raw</li>')),3==a&&5>=n&&(i+='<li><a href="http://www.erepublik.com/'+LANG+"/economy/market/"+img_country[eRS.country].id+"/3/"+n+'/citizen/0/price_asc/1"><img src="'+itemicons[a][n]+'"> Ticket Q'+n+"</li>")
$("#menu4 ul li:first").append('<ul class="eRS_quickMarket">'+t+'</ul><ul class="eRS_quickMarket">'+e+'</ul><ul class="eRS_quickMarket">'+i+"</ul>"),$("#menu4 ul li:first").hover(function(){$(".eRS_quickMarket:eq(0)").attr("style","display:block!important"),$(".eRS_quickMarket:eq(1)").attr("style","display:block!important;left:269px!important;"),$(".eRS_quickMarket:eq(2)").attr("style","display:block!important;left:407px!important;")},function(){$(".eRS_quickMarket").hide()})}function NewFuncs(){unsafeWindow.get_citizen_feeds=function(){var t,e
try{$j("#show_friends_feed").addClass("active"),$j("#show_regiment_feed").removeClass("active"),$j("#show_facebook_feed").removeClass("active"),$j("#show_party_feed").removeClass("active"),$j(".fb-like-box").css("display","none"),$j(".shouter").css("display","block"),$j(".wall_post_list ul").css("display","block"),$j("#citizen_older_feeds").css("display","block"),t="/"+(LANG?LANG:"en")+"/main/wall-post/older/",e={_token:$j("#_token").val(),page:0},$j.post(t,e,function(t){options.reShout||options.filterGuerrilla||options.filterMedals?($("body").append('<ul id="boggy" style="display: none;"></ul>'),$("#boggy").append(t),t=FilterPost("#boggy"),$("#boggy").remove(),$j(".wall_post_list > ul").html(t),FilterPostBind()):$j(".wall_post_list > ul").html(t),$j("#isGroupFeed").val(0),parseInt($j("#postCount").val())>unsafeWindow.POSTS_LIMIT+1?$j("#citizen_older_feeds").show():$j("#citizen_feed_friends").show(),$j("#group_older_feeds").hide(),$j("#shout").val(unsafeWindow.wall_texts.say_something_to_your_friends+" ...")})}catch(i){}},unsafeWindow.get_group_feeds=function(){var t,e
try{$j("#show_regiment_feed").addClass("active"),$j("#show_friends_feed").removeClass("active"),$j("#show_facebook_feed").removeClass("active"),$j("#show_party_feed").removeClass("active"),$j(".fb-like-box").css("display","none"),$j(".shouter").css("display","block"),$j(".wall_post_list ul").css("display","block"),t="/"+(LANG?LANG:"en")+"/main/group-wall/older/retrieve",e={_token:$j("#_token").val(),page:0,groupId:$j("#groupId").val(),part:1},$j.post(t,e,function(t){var e
unsafeWindow.feedTabs===!0?options.reShout?($("body").append('<ul id="boggy" style="display:none"></ul>'),$("#boggy").append($(t).find(".wall_post_list ul").html()),e=FilterPost("#boggy"),$("#boggy").remove(),$j("#isGroupFeed").val(1),$(".wall_post_list ul").html(e),FilterPostBind()):($j("#isGroupFeed").val(1),$j(".wall_post_list ul").html($j(t).find(".wall_post_list ul").html()),$j("#shout").val("Say something...")):options.reShout?($("body").append('<ul id="boggy" style="display:none"></ul>'),$("#boggy").append($(t).find(".wall_post_list ul").html()),e=FilterPost("#boggy"),$("#boggy").remove(),$j("#isGroupFeed").val(1),$j("#wall_master").html(t),$(".wall_post_list ul").html(e),FilterPostBind()):($j("#isGroupFeed").val(1),$j("#wall_master").html(t))},"html")}catch(i){}},unsafeWindow.get_party_feeds=function(){var t,e
try{$j("#show_party_feed").addClass("active"),$j("#show_regiment_feed").removeClass("active"),$j("#show_facebook_feed").removeClass("active"),$j("#show_friends_feed").removeClass("active"),$j(".fb-like-box").css("display","none"),$j(".shouter").css("display","block"),$j(".wall_post_list ul").css("display","block"),t="/"+(LANG?LANG:"en")+"/main/party-post/older/",e={_token:$j("#_token").val(),page:0},$j.post(t,e,function(t){options.reShout?($("body").append('<ul id="boggy" style="display:none"></ul>'),$("#boggy").append(t),t=FilterPost("#boggy"),$("#boggy").remove(),$j(".wall_post_list > ul").html(t),FilterPostBind()):$j(".wall_post_list > ul").html(t),$j("#isGroupFeed").val(0),parseInt($j("#partyPostCount").val())>unsafeWindow.POSTS_LIMIT+1?$j("#citizen_older_feeds").show():$j("#citizen_older_feeds").hide(),$j("#group_older_feeds").hide(),$j("#shout").val(unsafeWindow.wall_texts.say_something_to_your_party_colleagues+" ...")})}catch(i){}},unsafeWindow.populatePreviousPosts=function(){var t=parseInt($j("#previous_posts").val()),e=parseInt($j("#posts_count").val()),i="/"+(LANG?LANG:"en")+"/main/wall-post/older/"
$j("#party_feeds").length>0&&(i="/"+(LANG?LANG:"en")+"/main/party-post/older/"),$j.post(i,{_token:$j("#_token").val(),page:t,postId:$j("#viewFirst").val()},function(i){options.reShout||options.filterGuerrilla||options.filterMedals?($("body").append('<ul id="boggy" style="display:none"></ul>'),$("#boggy").append(i),i=FilterPost("#boggy"),$("#boggy").remove(),$j(".wall_post_list > ul").append(i),FilterPostBind()):$j(".wall_post_list > ul").append(i),e>10*(t+1)?$j("#previous_posts").val(t+1):$j(".previous_posts").hide()},"html")}}function FilterPostBind(){$("a[id^=repost_]").bind("click",function(){var t=$(this).parent().parent().parent().find("h6:first a:first").text()+" wrote:\r"+$(this).parent().parent().parent().find("p:first").text().trim()
$("textarea[id=shout]").trigger("click"),$("textarea[id=shout]").val(t),unsafeWindow.new_post()}),$("a[class^=shareButton_]").bind("click",function(){var t=$(this).attr("class").split("_")[1]
"0px"==$(".shareUrl_"+t).css("height")?($(".shareUrl_"+t).show(),$(".shareUrl_"+t).animate({height:"25"},200,"linear",function(){$(".shareUrl_"+t).show(),$(".shareUrl_"+t).animate({opacity:"1"},300).focus().select(),$(".shareUrl_"+t).click(function(){$(".shareUrl_"+t+" input").select()})})):$(".shareUrl_"+t).animate({opacity:"0"},300,"linear",function(){$(".shareUrl_"+t).animate({height:"0"},200,"linear",function(){$(".shareUrl_"+t).hide()})})})}function FilterPost(t){return $(t).find("li").each(function(){var t,e
$(this).hasClass("mu")||($("#show_friends_feed").hasClass("active")?t="viewPost":$("#show_regiment_feed").hasClass("active")?t="unitPost":$("#show_party_feed").hasClass("active")?t="viewPartyPost":"",e=$(this).attr("id").split("_")[1].trim(),options.reShout&&$(this).find(".post_content .post_actions").append('<div class="repost" style="display:inline"><span>·</span><a style="margin-left:3px" id="repost_'+e+'" title="" href="javascript:;">Shout</a><span style="margin-left:3px" class="shareDot">· </span><a class="shareButton_'+e+'" href="javascript:;">Share</a><div class="shareUrl_'+e+'" style="clear:both;width:310px;display:none;padding:5px 0 0 0;height:0px;overflow:hidden"><input value="http://www.erepublik.com/en?'+t+"="+e+'" style="display:block;width:300px;font-size:9px;border-radius:3px;border:1px solid #D2D2D2;color:grey;padding:2px;opacity:1"></div></div>'),options.filterGuerrilla&&$(this).find(".auto_img").length>0&&$(this).find(".auto_img").attr("src").indexOf("/pvpgame/")>0&&$(this).remove(),options.filterMedals&&$(this).find(".auto_img").length>0&&$(this).find(".auto_img").attr("src").indexOf("/achievements/")>0&&$(this).remove())}),$(t).html()}function FireEmployers(){function t(){function t(e){var i="http://www.erepublik.com/"+LANG+"/economy/fire"
params={action_type:"fire",employeeId:parseInt(e.shift()),_token:$("#_token").val()},$.post(i,params,function(i){var a=$(".fire_employee").parent().parent()
0==i.status&&"redirect"==i.message&&1==isLast?window.location.reload():0==i.status&&"redirect"==i.message&&0==isLast||0==i.status&&"lock"==i.message||(1==i.status?0==e.length?window.location.reload():(unsafeWindow.throwNotice(a,"Fired."),setTimeout(function(){t(e)},800)):unsafeWindow.throwError(a,i.message))},"json")}$("#fireThem").length>0?($(".list_group .listing .employee_salary.c3 strong #fireHimd").remove(),$("#fireThem").remove()):(GM_addStyle('button.thoughtbot{margin-top:5px;float:right;background-color:#ee432e;background-image:linear-gradient(#ee432e 0%, #c63929 50%, #b51700 50%, #891100 100%);border:1px solid #951100;border-radius:5px;box-shadow: inset 0px 0px 0px 1px rgba(255, 115, 100, 0.4), 0 1px 3px #333333;color: #fff;font: bold 11px/1 "helvetica neue", helvetica, arial, sans-serif;text-align:center;text-shadow:0px -1px 1px rgba(0, 0, 0, 0.8);width:100px;height:30px}button.thoughtbot:hover{background-color:#f37873;background-image:linear-gradient(#f37873 0%, #db504d 50%, #cb0500 50%, #a20601 100%);cursor:pointer}button.thoughtbot:active{background-color:#d43c28;background-image:linear-gradient(#d43c28 0%, #ad3224 50%, #9c1500 50%, #700d00 100%);box-shadow: inset 0px 0px 0px 1px rgba(255, 115, 100, 0.4)}'),$(".list_group .listing").each(function(){$(this).find(".employee_salary.c3 strong").append('<input type="checkbox" name="fireHim[]" style="vertical-align:middle;margin-left:10px;margin-bottom:3px" id="fireHimd">')}),$(".bottom_details").before('<button class="thoughtbot" id="fireThem">Fire Selected</button>'),$("#fireThem").bind("click",function(){var e=[]
$("input[name='fireHim[]']:checked").each(function(){e.push($(this).parent().parent().find(".current_salary").attr("id").split("_")[2].trim())}),t(e)}))}$(".grey_plastic.right_pos").bind("click",function(){$(this).hasClass("disabled")||t()}),$("#edit_mode").bind("click",function(){$("#fireThem").length>0&&($(".list_group .listing .employee_salary.c3 strong #fireHimd").remove(),$("#fireThem").remove())}),$("#add_mode").bind("click",function(){$("#fireThem").length>0&&($(".list_group .listing .employee_salary.c3 strong #fireHimd").remove(),$("#fireThem").remove())})}function ChangeSalaryAll(){function t(){$("#change_sal_all").length>0?$("#change_sal_all").remove():(GM_addStyle('button.thoughtbot{margin-top:5px;background-color:#ee432e;background-image:linear-gradient(#ee432e 0%, #c63929 50%, #b51700 50%, #891100 100%);border:1px solid #951100;border-radius:5px;box-shadow:inset 0px 0px 0px 1px rgba(255, 115, 100, 0.4), 0 1px 3px #333333;color:#fff;font:bold 11px/1 "helvetica neue", helvetica, arial, sans-serif;text-align:center;text-shadow:0px -1px 1px rgba(0, 0, 0, 0.8);width:100px;height:30px}button.thoughtbot:hover{background-color:#f37873;background-image:linear-gradient(#f37873 0%, #db504d 50%, #cb0500 50%, #a20601 100%);cursor:pointer}button.thoughtbot:active{background-color:#d43c28;background-image:linear-gradient(#d43c28 0%, #ad3224 50%, #9c1500 50%, #700d00 100%);box-shadow:inset 0px 0px 0px 1px rgba(255, 115, 100, 0.4)}'),$(".bottom_details").before('<div id="change_sal_all" style="float:right"><input type="text" style="margin-bottom:0px!important; margin-right:5px!important;width:40px" class="field" id="eRS_same_all"><button class="thoughtbot" id="changeAll">Change For All</button></div>'),$("#changeAll").click(function(){i=[],a=0,$(".list_group").find(".employee_salary.c3").each(function(){var t,e=$(this).find(".old_salary_value").attr("id").split("_")[2]
t=""==$("#eRS_same_all").val()?$(this).find("#salary_value_"+e).val():$("#eRS_same_all").val(),0!=parseFloat(t)&&parseFloat(t)!=parseFloat($(this).find("#old_salary_"+e).val())&&i.push({action_type:"update_salary",employeeId:e,salary:t,_token:$("#_token").val()})}),a=i.length,e(0)}))}function e(t){t>=a?window.location.reload():$.post("http://www.erepublik.com/en/economy/update-salary",i[t],function(a){var n=$("#old_salary_"+i[t].employeeId).parent().parent()
0==a.status&&"redirect"==a.message||0==a.status&&"lock"==a.message||(1==a.status?($("#old_salary_"+i[t].employeeId).val(a.result.salary),$("#current_salary_"+i[t].employeeId).html(a.result.salary+" "+unsafeWindow.salaryDetails.currency),unsafeWindow.throwNotice(n,a.result.message),setTimeout(function(){unsafeWindow.recalculateDues()},50)):unsafeWindow.throwError(n,a.message)),setTimeout(function(){e(t+1)},3e3)},"json")}var i=[],a=0
$("#edit_mode").click(function(){t()}),$("#add_mode,#remove_mode").bind("click",function(){$("#change_sal_all").length>0&&$("#change_sal_all").remove()})}function ShowPriceCompare(){function t(t){e!=t&&($(".compare_other").fadeOut("fast"),$(".compare_other").remove(),GM_xmlhttpRequest({method:"GET",url:"http://www.erepublik.com/"+LANG+"/economy/market/"+t+"/"+n+"/"+o+"/citizen/0/"+r+"/1",onload:function(t){rowCounter=0
var e=t.responseText.replace(/src=/g,"tmpsrc=").replace(/\.css/g,"").replace(/\.js/g,"").replace(/url\(/g,"")
$(e).find("#marketplace .price_sorted tr").each(function(){num=$(this).find(".m_stock").text(),price_major=$(this).find(".m_price strong:eq(0)").text().trim(),price_minor=$(this).find(".m_price sup").text(),$("#marketplace .price_sorted tr:eq("+rowCounter+") .m_stock").append("<div style='display:none;padding-left:5px; margin-top:-10px;' class='compare_other'><br>"+num+"</div>"),current=$("#marketplace .price_sorted tr:eq("+rowCounter+") .m_price").append("<div style='display:none' class='compare_other'><strong>"+price_major+"</strong><sup>"+price_minor+"<strong></strong> </sup></div>"),rowCounter++}),$(".compare_other").fadeIn("slow")}}),e=$("#countryIdCom").val())}var e,i,a=document.location.toString().split("/"),n=(a[6],a[7]),o=a[8],r=a[11],s=$("#countryId").html()
$(".country-select").attr("style","float:left!important; margin-left:110px;"),$("#marketplace h1").attr("style","display:inline!important;"),$(".country-select").before('<h1 style="display:inline;float:right;margin-right:100px">Compare to marketplace</h1><div class="country-select" style="float:right;"><select id="countryIdCom">'+s+"</select></div>"),$j("#countryIdCom").msDropDown({visibleRows:8,rowHeight:29}),i=$("#countryIdCom_child ._msddli_").length>0?"._msddli_":"a",$("#countryIdCom_child "+i).click(function(){$(".onaccount_display").slideUp("fast"),t($("#countryIdCom").val())}),e=$("#countryIdCom").val()}function SortWages(){function t(){i=[],$(".list_group .listing .employee_salary.c3").each(function(){i.push({html:'<div class="'+$(this).parent().attr("class")+'">'+$(this).parent().html()+"</div>",sal:$(this).find(".old_salary_value").attr("value")})})}function e(){$(".list_group").html("")
for(var t=0;t<i.length;t++)$(".list_group").append(i[t].html)}var i
$("#edit_mode").after('<strong style="margin-left:10px">Sort</strong><a href="javascript:;" id="sort_ASC" class="grey_plastic" title="Sort by salaries ASC"><img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAARCAMAAAAMs7fIAAAAgVBMVEUAAAD///9Xe5lZfZr///8/ZYP///8/ZYNCaYf///////9CaYf///8/ZYNyn8H///9vnL5vnL5xnsH///91osVyn8F2osVplbb///9jjq91osVkjq9yn8Fumrxjjq9qlbZZfZpafptTfJxjjq9plbZdh6hagqJXf51umrxyn8F1osUjLickAAAAI3RSTlMAKv36TFFvGpwna6ZRVwZ8FiF6acpB3cYdPH36VJlW4fj3GEhzCLMAAABzSURBVBjTdcvZDoIwEIXh1qVa1FZBZQlr2Hn/B2Q6MBO44Ls7f3LEIeMnZhfe32n6fzbhN6KUgz+sMrM8woYV7hnXO7kQkbIts1bir2Ni1TMqJ3AGVUlFecpzgoDKA9wRlSe4ICovcEVUpKOl1prKjcGYAbyxDlWDhNcxAAAAAElFTkSuQmCC" alt=""></a>'),$("#sort_ASC").after('<a href="javascript:;" id="sort_DESC" class="grey_plastic" title="Sort by salaries DESC"><img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAARCAMAAAAMs7fIAAAAUVBMVEUAAABCaYf///////////9CaYf///9GbYz///8/ZYNyn8Fzn8L///9ql7hrl7lvnL5plbZumrx1osVjjq9plbZdh6hagqJXf51YfJpzoMNumrz8FMt4AAAAE3RSTlMAqlF8apxMGShTBntvVT4h15ncAHG4uwAAAF5JREFUGNNtz1kOgDAIRVG1derkPO5/oSLtQ008nzeBQPavFiiNQGkFSkEqhpKTkqE47XSEsguUTaCsIh7j1CKUopPC9OHvH/r50WXMnslgsDoczL+/HynwhDDWpokLlbYJi9kgmsUAAAAASUVORK5CYII=" alt=""></a>'),$("#sort_ASC").bind("click",function(){t(),i.sort(function(t,e){return parseFloat(t.sal)-parseFloat(e.sal)}),$("#sort_ASC").attr("class","grey_plastic active"),$("#sort_DESC").attr("class","grey_plastic"),e()}),$("#sort_DESC").bind("click",function(){t(),i.sort(function(t,e){return parseFloat(e.sal)-parseFloat(t.sal)}),$("#sort_ASC").attr("class","grey_plastic"),$("#sort_DESC").attr("class","grey_plastic active"),e()})}function FindMyOffer(){function t(){$("button[id^=search_]").remove(),$("button[id^=cancel_]").remove(),$("div[id^=infoTable_]").remove(),d=1,$(".exchange_offers.mine tbody tr").each(function(){var i,l
$(this).find(".ex_amount").css({width:"130px","padding-right":"10px"}),$(this).find(".ex_amount strong").css("left","0px"),$(this).find(".ex_rate").css("width","220px"),$(this).find(".gored").css("margin-right","3px"),i=$(this).find(".gored").attr("id").split("_")[1].trim(),$(this).find(".ex_buy button").css("min-width","0"),$(this).find(".ex_buy").append('<button style="margin-left:3px;min-width:0px" id="search_'+i+'" type="button" class="marketbtn post eRSsearch">Search</button><button style="margin-left:3px" id="cancel_'+i+'" type="button" style="display:none" class="marketbtn post eRSsearchC">Cancel</button>'),"undefined"!=typeof n[i]?(r=n[i].date,o=n[i].page,n[i].use=1,l="/"==r?"No data available":'Offer is on page: <a href="javascript:void(0);" id="eRSShowOffer_'+i+'">'+o+"</a> [Day: "+r+"]"):(r="/",o="No data",n[i]={date:r,page:o,use:1},l="No data available"),$(this).find("#cancel_"+i).attr("style","display: none!important;"),$(this).find("#remove_"+i).bind("click",function(){setTimeout(t,500)}),$(this).find("#update_"+i).bind("click",function(){setTimeout(t,500)}),$(this).find("#search_"+i).bind("click",function(){d=0,$(this).attr("style","display: none!important;"),$(this).parent().find("#cancel_"+i).attr("style","margin-left:3px;display:block!important;min-width:0px!important")
var t="No data"==n[i].page?0:n[i].page
s="GOLD"==$(this).parent().parent().find(".ex_amount em").text().trim()?62:1,e(i,s,t)}),$(this).find("#cancel_"+i).bind("click",function(){d=1,$(this).attr("style","display: none!important;"),$(this).parent().find("#search_"+i).attr("style","margin-left:3px;display:block!important;min-width:0px!important"),"/"==n[i].date?$("#info_"+i).text("No data available"):($("#info_"+i).html('Offer on page: <a href="javascript:void(0);" id="eRSShowOffer_'+i+'">'+n[i].page+"</a> ["+n[i].date+"]"),$("#eRSShowOffer_"+i).bind("click",function(){s="GOLD"==$(this).parent().parent().parent().parent().find(".ex_amount em").text().trim()?62:1
var t=$(this).attr("id").split("_")[1].trim()
a(s,n[t].page)}))}),$(this).find(".ex_buy").append('<div id="infoTable_'+i+'" style="clear:both;display:block;width:100%;text-align:center;"><strong id="info_'+i+'">'+l+"</strong></div>"),$(this).find("#eRSShowOffer_"+i).bind("click",function(){s="GOLD"==$(this).parent().parent().parent().parent().find(".ex_amount em").text().trim()?62:1
var t=$(this).attr("id").split("_")[1].trim()
a(s,n[t].page)})}),$.each(n,function(t,e){$.each(e,function(e,i){"use"==e&&0==i&&delete n[t]})}),GM_setValue("eRSMyOffers",JSON.stringify(n))}function e(t,e){$("#info_"+t).text("Searching please wait: 0%")
var a={_token:$("#_token").val(),personalOffers:0,page:1,currencyId:e}
$.post(l,a,function(e){a._token=e.essentials.replace(/src=/g,"tmpsrc=").replace(/\.css/g,"").replace(/\.js/g,"").replace(/url\(/g,"").split("<input id='_token' name='_token' type='hidden' value='")[1].split("'")[0],i(a,t)},"json")}function i(t,e){setTimeout(function(){0==d&&$.post(l,t,function(a){var o,r,s,l
0==d&&(t._token=a.essentials.replace(/src=/g,"tmpsrc=").replace(/\.css/g,"").replace(/\.js/g,"").replace(/url\(/g,"").split("<input id='_token' name='_token' type='hidden' value='")[1].split("'")[0],$("#footer").after('<div class="boogus" style="display:none"></div>'),$(".boogus").html(a.buy_mode.replace(/src=/g,"tmpsrc=").replace(/\.css/g,"").replace(/\.js/g,"").replace(/url\(/g,"")),$(".boogus").find(".ex_rate #exchange_rate_"+e).length>0?(o=$(".eday strong").text().replace(",","").trim()+" "+$("#live_time").text().trim(),n[e].date=o,n[e].page=t.page+1,n[e].use=1,GM_setValue("eRSMyOffers",JSON.stringify(n)),$("#cancel_"+e).trigger("click")):(r=a.buy_mode.replace(/src=/g,"tmpsrc=").replace(/\.css/g,"").replace(/\.js/g,"").replace(/url\(/g,"").split('class="last" title="Go to page '),s=2==r.length?parseInt(r[1].split('"')[0].trim()):t.page,l=t.page/s*100,100==l?$("#info_"+e).text("Offer doesn't exist anymore"):($("#info_"+e).text("Searching please wait "+l.toFixed(2)+"%"),t.page=parseInt(t.page)+1,i(t,e))),$(".boogus").remove())},"json")},500)}function a(t,e){$(".generic_validate").remove(),$(".generic_error").remove(),$(".create_form").hide()
var i={_token:$("#_token").val(),personalOffers:0,page:parseInt(e)-1,currencyId:t}
$.post(l,i,function(t){unsafeWindow.erepublik.exchange.displayNextPage(t,!0)},"json")}var n,o,r,s,l,d,c,p=GM_getValue("eRSMyOffers")
"undefined"!=typeof p?(n=JSON.parse(p),$.each(n,function(t,e){$.each(e,function(e){"use"==e&&(n[t][e]=0)})})):n={},l="/"+LANG+"/economy/exchange/retrieve/",unsafeWindow.jQuery("body").ajaxComplete(function(e,i,a){(a.url.indexOf("/create")||a.url.indexOf("/update")||a.url.indexOf("/delete"))&&t()}),$("#my_offers").bind("click",function(){setTimeout(function(){c=0,t()},500)})}function GetRecipients(){unb(),$(".message_listing tbody tr").each(function(){var t=$(this).find(".message_get.subject").attr("href"),e=t.split("/")[4],i=0
$(this).css("border-bottom","none"),$(this).after("<tr><td colspan='4'><div style='display:block;padding:5px;background-color:#f1f1f1;border-radius:5px;margin:-20px 0' id=\"eRSRecep_"+e+'">Loading message recipients.</div></td></tr>'),GM_xmlhttpRequest({method:"GET",url:"http://www.erepublik.com"+t,onload:function(t){var a="",n=t.responseText.replace(/src=/g,"tmpsrc=").replace(/\.css/g,"").replace(/\.js/g,"").replace(/url\(/g,"")
$(n).find(".message_container .coloured .nameholder:first a").each(function(){$(this).text().trim()!=$(".user_name").text().trim()&&(a+='<a style="background-color:white;padding:1px;border-radius:5px;margin:0 2px;display:inline-block" href="'+$(this).attr("href")+'">'+$(this).text().trim()+"</a>",i+=1)}),$("#eRSRecep_"+e).html(1==i?"Recipient:"+a:"Recipients:"+a)}})})}function ShowProfitability(){var t,e,i,a=parseInt(window.location.href.split("/")[7]);(1==a||2==a)&&(t=parseInt(window.location.href.split("/")[8]),1==a&&(i="hp",e=7!=t?2*t:20),2==a&&(i="use",e=7!=t?t:10),$("#marketplace thead .m_provider").after('<th style="width:110px">Cost Per Use</th>'),$("#marketplace .price_sorted tr").each(function(){var t=parseFloat($(this).find(".m_price strong:first").text()+""+$(this).find(".m_price sup:first").html().split("<strong>")[0].trim()),a=t/e
a=a.toFixed(.1>=a?4:2),$(this).find(".m_provider").after('<td class="stprice"><strong>'+a.split(".")[0]+"</strong><sup>."+a.split(".")[1]+"<strong> "+$(".currency_amount p img").attr("title")+"/"+i+"</strong></sup></td>")}))}function CheaperPack(){function t(r,s){GM_xmlhttpRequest({method:"GET",url:"http://www.erepublik.com/"+LANG+"/economy/market/"+s+"/2/"+r+"/citizen/0/price_asc/1",onload:function(l){var d=l.responseText.replace(/src=/g,"tmpsrc=").replace(/\.css/g,"").replace(/\.js/g,"").replace(/url\(/g,"")
n[r]=parseFloat($(d).find(".m_price strong:first").text()+""+$(d).find(".m_price sup:first").html().split("<strong>")[0].trim()),6==r?(e(s),i!=a&&(n=[],0==o&&(t(1,i),o=!0))):setTimeout(function(){t(r+1,s)},400)}})}function e(t){var e,o,r,s,l,d=0,c=parseFloat($(".rocket_factory_cost_list li:first strong:first").text().split("/")[1])
for(isNaN(c)&&(c=parseFloat($(".rocket_factory_cost_list li:first strong:first").text())),e=1;6>=e;e++)o=e-1,r="0px 0px 0px 0px;",s="69px",0==o&&t==i?r="0px 0px 0px 3px;":5==o&&t==i&&(r="0px 0px 3px 0px;"),t!=a&&(s="87px"),$(".rocket_factory_cost_list li:eq("+o+") strong:first").css("border-radius","0px 0px 0px 0px"),$(".rocket_factory_cost_list li:eq("+o+")").append('<strong style="top: '+s+";border-radius: "+r+'">'+n[e]+" "+$(".currency_amount p img").attr("title")+"</strong>"),d+=n[e]
l=d*c,$(".chipset_time").length>0&&i!=a&&$(".chipset_time margin-top").attr("style","bottom:-55px"),$(".rocket_factory_cost_list").after(t!=a?'<strong style="position:absolute;top:101px"><img style="vertical-align:middle" src="'+$(".user_country img").attr("src")+'"> '+l.toFixed(2)+" "+$(".currency_amount p img").attr("title")+"</strong>":'<strong style="position:absolute;top:84px"><img style="vertical-align:middle" src="'+$(".currency_amount img").attr("src")+'"> '+l.toFixed(2)+" "+$(".currency_amount p img").attr("title")+"</strong>")}var i,a,n,o
$(".rocket_factory_cost_list").length>0&&(i=img_country[$(".user_country img").attr("src").split("/")[6].split(".")[0]].id,a=img_country[eRS.country].id,n=[],o=!1,i!=a&&$(".rocket_factory_cost_list").attr("style","margin-bottom:30px;"),t(1,a))}function GetItemPrice(){$(".sell_selector .industry_quality_selector").click(function(){var t,e,i,a
$("#sell_price").val(0),t=$(this).attr("quality"),"0"==t&&(t=1),e=$(this).attr("industry"),i="undefined"==typeof unsafeWindow.itemPartials[e]?0:unsafeWindow.itemPartials[e][t],a=0==i?unsafeWindow.itemAmounts[e][t]:unsafeWindow.itemAmounts[e][t]-1,a>99999&&(a=99999),$("#sell_amount").val(a),GM_xmlhttpRequest({method:"GET",url:"http://m.erepublik.com/"+LANG+"/economy/market/"+img_country[eRS.country].id+"/"+e+"/"+t+"/citizen/0/price_asc/1",onload:function(t){$("#sell_price").val(t.responseText.split('<div class="c1">')[2].split("<strong>")[1].split(" ")[0]),$("#sell_price").trigger("keyup")}})})}function BoosterBattle(){function t(){var e=GM_getValue("eRS.buildRocket")
0==e?window.location.href=window.location:"send_reload"!=e&&"reload"!=e&&1!=e&&2!=e&&3!=e?alert(e):setTimeout(t,500)}GM_addStyle("#eRSbuildRocket1{background:linear-gradient(to bottom, #fa665a 5%,#d34639 100%);border-radius:3px;display:inline-block;padding:1px 4px}#eRSbuildRocket1:hover{background:linear-gradient(to bottom, #d34639 5%,#fa665a 100%)}#eRSbuildRocket2{background:linear-gradient(to bottom, #79bbff 5%,#4197ee 100%);border-radius:3px;display:inline-block;padding:1px 4px}#eRSbuildRocket2:hover{background:linear-gradient(to bottom, #4197ee 5%,#79bbff 100%)}#eRSbuildRocket3{background:linear-gradient(to bottom, #89c403 5%,#77a809 100%);border-radius:3px;display:inline-block;padding:1px 4px}#eRSbuildRocket3:hover{background:linear-gradient(to bottom, #77a809 5%,#89c403 100%)}"),$("#pvp_actions").append('<div style="position:absolute;left:254px;color:white;font-size:12px;font-weight:bold;cursor:pointer"><div id="eRSbuildRocket1">Build Booster</div><div id="eRSbuildRocket2">Build Rocket</div><div id="eRSbuildRocket3"">Build Bazooka</div></div>'),$("#eRSbuildRocket1").click(function(){GM_setValue("eRS.buildRocket",1),window.open("http://www.erepublik.com/"+LANG+"/economy/inventory","_blank"),t()}),$("#eRSbuildRocket2").click(function(){GM_setValue("eRS.buildRocket",2),window.open("http://www.erepublik.com/"+LANG+"/economy/inventory","_blank"),t()}),$("#eRSbuildRocket3").click(function(){GM_setValue("eRS.buildRocket",3),window.open("http://www.erepublik.com/"+LANG+"/economy/inventory","_blank"),t()})}function ChekToBuild(){var t,e=GM_getValue("eRS.buildRocket")
if(1==e)$("#build_damage_booster").length>0?$("#build_damage_booster").hasClass("disabled")?(GM_setValue("eRS.buildRocket","You do not have items for booster or you hit daily limit"),window.close()):(GM_setValue("eRS.buildRocket","send_reload"),$("#rocket_factory_build_what").val("build_damage_booster"),$("#rocket_factory_form").submit()):(GM_setValue("eRS.buildRocket","You do not have factory with booster"),window.close())
else if(2==e)$("#build_rocket").length>0?$("#build_rocket").hasClass("disabled")?(GM_setValue("eRS.buildRocket","You do not have items for rocket or you hit daily limit"),window.close()):(GM_setValue("eRS.buildRocket","send_reload"),$("#rocket_factory_build_what").val("build_rocket"),$("#rocket_factory_form").submit()):(GM_setValue("eRS.buildRocket","You do not have rocket factory"),window.close())
else if(3==e)if($(".assemble:first").hasClass("disabled"))GM_setValue("eRS.buildRocket","You do not have necessary parts to build bazooka"),window.close()
else{if(GM_setValue("eRS.buildRocket","send_reload"),t=parseInt($(".assemble:first").attr("rel")),isNaN(t))return
$.post("http://www.erepublik.com/"+LANG+"/main/assemble/",{_token:$("#_token").val(),itemLevel:t},function(){location.reload()},"json")}else"send_reload"==e&&(GM_setValue("eRS.buildRocket",0),window.close())}function DoQuickAccess(){GM_addStyle("#large_sidebar .user_info .user_notify .notify.mudo{left:66px;background-image:url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAA8CAMAAABRqGpkAAAAbFBMVEUAAADc3Nx7e3zc3Nzc3NzZ2dkSEhYSEhbc3Nzc3NwSEhba2toSEhaUlJSVlZWUlJSUlJTc3NyVlZWXl5eUlJSTk5OQkJDc3NyXl5eXl5cSEhbKysqRkpKXl5eOjo4SEhZmZmjU1NSXl5eLjIzD8EThAAAAInRSTlMAXgMTDi1zJmIxDHEcMXAjRUKREwuCuyLQmzqHWvfoX3WBcglxuwAAAW9JREFUOMuVkdmagyAMRiPLyOa+dWpX5/3fcSLUBqw3/VUuzpcI5ACT1qoMo1SmcLVWMjBP1WgppfaRulFPA842Exdie/nUWAe50pzBO4xrlXsIUJRle+kYUqEzhJkUCE/LsrR1UQGXoRJhNyw+v69KJbGd1dcNSrVBqEYPS6wM7QxhX56G3+upwMqwEayp26qqix64h8pDVrV112MP19m2e3UZbmNbFn04fID1+Ie5lR0L/0yvCaFyHQjnwhPB14EgnP3o/PTWp8nmHNxjxiHjg1lXOz8cmPP9J8n9bIAZlydxhgVHKMd7Sh1pvw0mdhTCY0fwcfhMi0OYiJNvmyROvOYZi6N2Ekc2xU5cgKm4rZ3EIaRKEhc2kjwSB+JAHDkSdFGWOMJvAphSR0HTt44O4XG7OzuI40FuYBeD54SPfA/JJkGySTC2SZBsEoxsEiSblsUQhnG1WQBBskkwtkmQbAbo4CPoiO0ZQ0d7iuAf9bIoK/girsYAAAAASUVORK5CYII=');background-repeat:no-repeat;background-position:0 0}#large_sidebar .user_info .user_notify .notify.mudo:hover{background-position:0 -20px}#large_sidebar .user_info .user_notify .notify.mudo:active{background-position:0 -40px}#large_sidebar .user_info .user_notify .notify.nalert{left:22px}#large_sidebar .user_info .user_notify .notify.newleaderboard{left:44px}"),$(".user_notify:first").append('<a href="http://www.erepublik.com/'+LANG+'/main/group-home/military" title="Change MUDO" class="notify mudo"></a>')}function getGuerrillaDmg(){$("#back_to_battle").click(function(){Damage+=parseInt($(".award_damage strong").text().split("+")[1]),setTimeout(function(){GM_setValue(eRS.citizenId+".damageToday"+date,Damage)},0),options.noKillsDamage&&ShowKillDamage()})}function ExchangeMarketButtons(){function t(){$("button[data-currency=GOLD]").each(function(){var t=$(this).attr("data-max")>10?"10.00":$(this).attr("data-max"),e=$(this).attr("data-price"),i=$("#eCash").val()
t*e>i&&(t=Math.floor(100*i/e)/100),$(this).parent().find("input").val(t),$(this).text($(this).attr("data-i18n")+" "+comma(Math.ceil(t*e*100)/100)+" "+unsafeWindow.erepublik.citizen.currency)})}var e
setInterval(function(){$("button[data-currency=GOLD]").eq(0).attr("id")!=e&&(e=$("button[data-currency=GOLD]").eq(0).attr("id"),t())},100),t()}function ImproveInventory(){var t,e,i
GM_addStyle("span#netPriceG,span#netPrice,span#totalNetPriceG,span#totalNetPrice{float:left;height:14px;clear:both;padding:8px 0px 8px 5px;color:#88AFC9;font-size:12px;font-weight:bold}#inventory_overview #sell_offers table td.total_net_price{text-align:right;padding:0 25px 0 0}#inventory_overview .taxTable{background-color:#BAE7F9;float:left;width:730px;border-radius:5px;margin:11px 0 0 15px}#inventory_overview .taxTable table{width:718px;border:1px solid #95D4ED;background:white;margin:5px auto}#inventory_overview .taxTable table th{background:#F7FCFF}#inventory_overview .taxTable table tbody td{border-top:1px solid #E2F3F9;color:#5E5E5E;padding:5px 0 5px 25px}#inventory_overview .taxTable table tbody tr:hover td{background-color:#FFFFE7}#inventory_overview .taxTable table .taxLink{cursor:point}#inventory_overview .taxTable table .taxLink .taxLinkHolder{border:2px solid #CFEFFB;border-radius:3px;position:absolute;margin-top:-7px;display:none;z-index:100}#inventory_overview .taxTable table .taxLink:hover .taxLinkHolder{display:block}#inventory_overview .taxTable table .taxLink .taxLinkHolder .taxLinkItemTransparent{background:none repeat scroll 0 0 transparent;text-align:center;height:25px}#inventory_overview .taxTable table .taxLink .taxLinkHolder .taxLinkItem{background-color:#FFFFE7;text-align:center}#inventory_overview .taxTable table .taxLink .taxLinkHolder .taxLinkItem:hover{background-color:#F7FCFF!important}"),t=parseInt($(".area.storage h4:first strong").text().replace(/,/g,"").split("/")[1].split(")")[0].trim()),e=parseInt($(".area.storage h4:first strong").text().replace(/,/g,"").split("/")[0].split("(")[1].trim()),i=$(".area.storage h4:first strong").text("( "+comma(e)+"/"+comma(t)+" Free slots left: "+comma(t-e)+" )"),GM_xmlhttpRequest({method:"GET",url:"http://www.erepublik.com/"+LANG+"/economy/exchange-market/",onload:function(t){function e(){$("#inventory_overview #sell_offers table th input").css("width","50px"),$("#inventory_overview #sell_offers table th.offers_product").css("width","70px"),$("#inventory_overview #sell_offers table th.offers_price").css("width","120px"),$("#inventory_overview #sell_offers table th.offers_quantity").css("width","80px"),$("#inventory_overview #sell_offers table th.offers_market").css("width","60px"),$("#inventory_overview #sell_offers table th.offers_action").css("width","132px"),$("#inventory_overview #sell_offers table th.offers_action a").css("cssText","left:10px;margin-right:20px"),$("#inventory_overview #sell_offers table .delete_offer").css("opacity","1")}var i=t.responseText.split("data-price='")[1].split("'")[0],a={createButton:function(t){if(1!=$("#visit_market",t).length){var i=$(".offer_flag",t).attr("src").split("/")[6]?t.find(".offer_flag").attr("src").split("/")[6].split(".")[0]:t.find(".offer_flag").attr("src").split("/")[4].split(".")[0],a=$(".offer_image",t).attr("src").split("/")[6]?t.find(".offer_image").attr("src").split("/")[6]:t.find(".offer_image").attr("src").split("/")[4],n=$(".offer_image",t).attr("src").split("/")[7]?t.find(".offer_image").attr("src").split("/")[7].split("_")[0]:t.find(".offer_image").attr("src").split("/")[5].split("_")[0],o=-1!=n.indexOf("q")?n.replace("q",""):"1",r="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABcAAAAXCAMAAADX9CSSAAAAllBMVEUAAABuqcJXnLhHkLBCbYdJeJRGk7FIk7NKgp9MfpxHjq1HiqlKfJpIgJ1IhKFHk7ZKiKbX5OpIhqXl7vJEiaRCg6BFdJA9gJ3N4edUj6zh7PFPlrRekaxyoLXt8fSDrL1dmrVRiqddhZyrx9Xx9PZcnrpFe5d7r8RThKFdjKaMrsBombA8e5Z6o7Zior2Xvs+Ftcu20d2mTY5zAAAAAXRSTlMAQObYZgAAASJJREFUKM9tytm2giAUgGGKQgZFBudE6mhZDg3v/3IHtDv70QXr2xuAfrftCcDued1vOkHw3MfBJpiA6ylAvx0hN4lRkOZLqXvT1WPkGH2KpRZ9PQicu+/9yaGzAsWQpuB8gggm+TRNuS3OiMYSQcgWh9BKrbWUVZ9QWNHVS3fLN6XMND2fH1RDylantKHwYqo+nbtqatyK8s4Y68rSFP1l7vRLdpQJ53UpvI+tHa1uNXtVQgh+A/VFiKQpB2usfLEuYYkS6uuqGY2Z20GphnG3prB3zlVTj8YaHN00V9wVeccYy+FvaZAcc45xlIH67ryVlfZHtngpzMDjHkWYuBW8/BHB7qxOCPGzkPiHf69Owm9uEK7TYwbIcVuWHQDIDj8C/x1kIXdrwdtjAAAAAElFTkSuQmCC",s=$(".offer_amount",t).text().replace(/,/g,""),l=$(".offer_price strong",t).text().replace(/,/g,""),d=$(t).attr("id").split("_")[1],c=$("#large_sidebar .sidebar_container .user_section .user_identity a").text()
$(".delete_offer",t).before('<a title="Visit market" target="_blank" class="fluid_blue_dark_small" style="padding-left:3px" id="visit_market" href="http://www.erepublik.com/'+LANG+"/economy/market/"+img_country[i].id+"/"+a+"/"+o+'/citizen/0/price_asc/1"><span>M</span></a><a title="Show offer on market" class="goto_offer" href="http://www.erepublik.com/'+LANG+"/economy/market/"+img_country[i].id+"/"+a+"/"+o+"?customOffer=true&sellerId="+eRS.citizenId+"&sellerName="+c+"&offerId="+d+"&offerAmount="+s+"&offerPrice="+l+'" target="_blank" style="height:23px;width:23px;display:inline-block;margin-left:10px"><img src="'+r+'"></a>'),e()}},waitForOffer:function(t){1==$("#"+t).length?a.createButton($("#"+t)):setTimeout(function(){waitForOffer(t)},500)}},n={createHolder:function(t){var e,a
$("td.net_price",t).length>0||(e=parseFloat($("td.offer_price strong",t).text()),a=e/i,$("td.offer_price",t).attr("style","text-align:right;padding-right:20px"),$("td.offer_price",t).append('<br><strong style="text-align:right;font-size:11px">'+a.toFixed(2)+'</strong><font style="text-align:right;font-size:11px"> GOLD</font>'),$("td.offer_price",t).after('<td style="text-align:right;padding-left:0px" class="offer_price net_price"></td>'))},createHeader:function(){var t,e=parseFloat($("#inventory_overview #sell_offers table th.offers_price #tax").text().split(" ")[0]),a=e/i
$("#inventory_overview #sell_offers table th.offers_price small").append('<span id="taxGG"><br><div style="display:inline;margin-left:49px"></div><span id="taxG">'+a.toFixed(4)+" GOLD</span>"),t=$("#inventory_overview #sell_offers table th.offers_price").clone(),t.addClass("net_price"),t.css("width","75px"),t.find("input").after('<span id="netPrice"></span>').remove(),t.find("#sell_currency").after('<span id="netPriceG"></span><b id="sell_currency">GOLD</b>'),t.find("#converted").text("Net / unit"),t.find("small").remove(),$("#inventory_overview #sell_offers table th.offers_price").after(t),n.headerNetPrice(),$("#sell_price,#sell_amount").keyup(function(){n.headerNetPrice()}),$("#product_select,.sell_selector").click(function(){n.headerNetPrice()})},headerNetPrice:function(){var t,e,a,n,r
$("#taxG").remove(),t=parseFloat($("#inventory_overview #sell_offers table th.offers_price #tax").text().split(" ")[0]),e=t/i,$("#inventory_overview #sell_offers table th.offers_price small").append('</span><span id="taxG">'+e.toFixed(4)+" GOLD</span>"),a=img_country[$("#market_select img").attr("src").split("/")[6]?$("#market_select img").attr("src").split("/")[6].split(".")[0]:$("#market_select img").attr("src").split("/")[4].split(".")[0]].id,t=parseInt($("#product_select img").attr("src").split("/")[6]?$("#product_select img").attr("src").split("/")[6]:$("#product_select img").attr("src").split("/")[4]),price=parseFloat(""==$("#sell_price").val()?0:$("#sell_price").val()),vat=parseFloat(unsafeWindow.countryList[a].taxes[t].value_added_tax),importTax=parseFloat(unsafeWindow.countryList[a].taxes[t].import_tax),tax=vat,a!=unsafeWindow.citizenshipCountry&&(tax+=importTax),n=price/((100+tax)/100),r=n/i,$("#inventory_overview #sell_offers table #netPrice").text(n.toFixed(2)),$("#inventory_overview #sell_offers table #netPriceG").text(r.toFixed(2)),$("#inventory_overview #sell_offers table #netPriceG").css("font-size","11px"),$("#inventory_overview #sell_offers table #sell_currency:last").css("font-size","11px"),o.calculateSum()},netPrice:function(t){var e,a,n=img_country[t.find(".offer_flag").attr("src").split("/")[6]?t.find(".offer_flag").attr("src").split("/")[6].split(".")[0]:t.find(".offer_flag").attr("src").split("/")[4].split(".")[0]].id,r=parseInt(t.find(".offer_image").attr("src").split("/")[6]?t.find(".offer_image").attr("src").split("/")[6]:t.find(".offer_image").attr("src").split("/")[4])
price=parseFloat($("td.offer_price:not(.net_price) strong",t).text().replace(",","")),vat=parseFloat(unsafeWindow.countryList[n].taxes[r].value_added_tax),importTax=parseFloat(unsafeWindow.countryList[n].taxes[r].import_tax),tax=vat,n!=unsafeWindow.citizenshipCountry&&(tax+=importTax),e=price/((100+tax)/100),a=e/i,$("td.net_price",t).html("<strong>"+e.toFixed(2)+"</strong> "+$("#sell_currency").text()+"<br><strong style='text-align:right;font-size:11px'>"+a.toFixed(2)+"</strong><font style='text-align:right;font-size:11px'> GOLD</font>"),o.calculateSum()},waitForOffer:function(t){1==$("#"+t).length?(n.createHolder($("#"+t)),n.netPrice($("#"+t))):setTimeout(function(){n.waitForOffer(t)},500)}},o={createRow:function(){$("#inventory_overview #sell_offers table").append('<tfoot><tr style="background:#F7FCFF;height:44px"><td colspan="4"><td class="offer_price total_net_price"><strong id="sumPrice"></strong> '+$("#sell_currency").text()+'<br><strong id="sumPriceG" style="font-size:11px"></strong><font style="font-size:11px"> GOLD</font></td><td colspan="2"></td></tr></tfoot>'),o.calculateSum()},calculateSum:function(){$("#sumPrice,#sumPriceG").text("0.00"),$("#inventory_overview #sell_offers table tbody tr[id^=offer_]:visible").each(function(){var t,e=parseFloat($(".total_net_price strong",this).text()),a=parseFloat($("#sumPrice").text())+e
$("#sumPrice").text(a.toFixed(2)),t=a/i,$("#sumPriceG").text(t.toFixed(2))})},waitForOffer:function(t){1==$("#"+t).length?o.calculateSum():setTimeout(function(){o.waitForOffer(t)},500)},waitToDissapear:function(t){0==$("#"+t+":visible").length?o.calculateSum():setTimeout(function(){o.waitToDissapear(t)},500)}},r={createHeader:function(){var t=$("#inventory_overview #sell_offers table th.offers_price:not(.net_price):not(.total_net_price)").clone()
t.addClass("total_net_price"),t.css("width","100px"),t.find("input").after('<span id="totalNetPrice"></span>').remove(),t.find("#sell_currency").after('<span id="totalNetPriceG"></span><b id="sell_currency">GOLD</b>'),t.find("#converted").text("Total Net Value"),t.find("small").remove(),$("#inventory_overview #sell_offers table th.offers_price").eq(1).after(t),r.headerTotalNetPrice(),$("#sell_price,#sell_amount").keyup(function(){r.headerTotalNetPrice()}),$("#product_select,.sell_selector").click(function(){r.headerTotalNetPrice()})},headerTotalNetPrice:function(){var t,e=parseFloat($("#netPrice").text()),a=isNaN(parseInt($("#sell_amount").val()))?0:parseInt($("#sell_amount").val()),n=e*a
$("#totalNetPrice").text(n.toFixed(2)),t=n/i,$("#totalNetPriceG").text(t.toFixed(2)),$("#totalNetPriceG").css("font-size","11px"),$("#totalNetPriceG").next().css("font-size","11px")},createHolder:function(t){$("td.total_net_price",t).length>0||$("td.net_price",t).after('<td class="offer_price total_net_price"></td>')},totalNetPrice:function(t){var e=parseFloat($("td.net_price strong",t).text()),a=parseInt($(".offer_amount",t).text().replace(",","")),n=e*a,r=n/i
$("td.total_net_price",t).html("<strong>"+n.toFixed(2)+"</strong> "+$("#sell_currency").text()+"<br><strong style='font-size:11px'>"+r.toFixed(2)+"</strong><font style='font-size:11px'> GOLD</font>"),o.calculateSum()},waitForOffer:function(t){1==$("#"+t).length?(r.createHolder($("#"+t)),r.totalNetPrice($("#"+t))):setTimeout(function(){r.waitForOffer(t)},500)}},s={createTable:function(){var t='<th style="height:40px;text-align:center;padding-left:0px"><img width="35px" height="35px" src="'
$("#sell_offers").after('<div class="taxTable" style="display:block"><table width="100%"><thead><tr><th style="height:40px;text-align:center;padding-left:0px"> </th>'+t+'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACMAAAAjCAMAAAApB0NrAAAA6lBMVEUAAAAwMjQPCg8IAwl5m3sVFRUAAAB7joKImZkvPTAXHBebpahQiVd5f36qtrigq63q4O6PlZZTW1lD/1/W1t3Fzc/h3eIt3jSVLx7S1tq1wcKnsq52gn6QmZisuLzJ0NM7Pz6UoqZbYmasOSO8sFjt8POasqqglkpuZiqOgzxsbmze4eZ+IxR+dj6EpJNeNySBkJOTqZxCkENa+3hG8F5WaFLBz8iOi1/Wx2a0p050WFNTp1psnHEYGxtgz3HPzbM2pTmpqYr+//99dnaKXFSKcGiUzp9SUEY9wT5+vYPi4s1x5oS1XEIafRzPN4HpAAAAGHRSTlMAGVWOEyV5ASULOEmLyJpoLZpfa5Z3UDf2PwGnAAABhElEQVQ4y+2SZ0/DMBCGm9GsthRogXplNTtN9957wv//OyS4agWCfgaJV7It3z063/ku9a+/KpHqJkC9P3LUykuSxNM73b8QUiaHcb1OiHGXlz5MIoUuyqwCbBhGw1FVFanQeEz8csxdM8kOS+XSWnWqEC2QS7q7epFRGCbgz1B8rPRK+bVcGVah1rUsv4PdxRI1synW5EWRIhldLyWqVYEG+lbku/2ebR+6p8I2TPzJyunDSvxWqePEzNH3rMEgCpdO49Ruj7cFyjyYmzhIDY8hAPbMi3zPHZAlfpu2Wu3RiNaXwZtyRa9XG1oIel7U73uWT2x93py22k1OodAdWe8IaqAuAFYv8ly/FoSBMN93WlOeCSRae95RoQohBDMXD3C46Kgmx2b348NLKpXX7mlp0gOCWpINOvY0G5kTgZX5+Qjci/ErT/SLZEZ5zBEDQUhMczLhBCW2NrPF53Mnz1RaYVlB4DhOENi0mKTAy587S4OlE8nixXEN8s0ciPS4MYi/Xe+4ny7FQWHBuwAAAABJRU5ErkJggg==" title="Food"></th>'+t+'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACMAAAAjCAMAAAApB0NrAAAAY1BMVEUAAABmZmZlZmZwcXF5eXsLCwtzc3NTVFMPDw8VFRUeHh4sLS05Ozu2tbGMi4l1dnc2NjYhISF0c3COjo6ysa4uLi0gHyA8OjRFQzxycnJKSUpkY2JXVlKGg3lpXkWqp57JwKkr4PVqAAAAFXRSTlMAbo5eDRFQASsHHFyOLx83S3C7kZssNSWiAAABR0lEQVQ4y82T23aDIBBFBwQG0MZLwlU0+f+vLBrTtIXVvPQh8+r2sOewgPcZxNfI6wwExl6e0qcI+BfxcemcGZ9MSbDmGoy18sGUxImkFE2eB1MSlyVGlwlr2wqze9wW44w1vtXWKsDSY7reltV566KxgFqVhEhuWY13piOzsbq2S0hp9S4jA6hzsgzxVx9kCmF2bvVGbmIfZw74k6AhLLO3sttbuauqp81GzNMyxzEZxry1RiECKq7wK6Y/z1vGqMTiCVJnDQfkmqtnI533NJhWgRANFeQUsg+Xkn8vRvMuA3ktwoSgE2VMSSlV9Q5IP0SCIMgWUnzeBnoCcSaCAaWHScExypomn0e7E2kAaww02VhpqaUgIgwVCDH/LI5l2EnEFrASQ4UcNB6tDyWThed2XxfvqVVhN3J+EHUKQe8l/s+bfIv5BOQDE2EQYJWVAAAAAElFTkSuQmCC" title="Weapons"></th>'+t+'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACMAAAAjCAMAAAApB0NrAAAAS1BMVEUAAAADAwPQ19ZVWVgYGhrd4+Pg5eQVFhYdHR3L0dDY3962vLvGzczj6emVmZipr67t8vH3+/t1eHdRUVKJi4ufpaQmJSU6OTnM1dNpFJu5AAAACnRSTlMAdomTJGAqUAkTkQ37dwAAAQNJREFUOMvl0FFygzAMBNAQAgRJlmzJxtz/pJXTSZnGaTlA9Ol5s7vjy6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SlCR1XkcZzwvt89zGfL4NY5JUTapoLDNEaHDap2FcmrgXjj+a8eUy4YU9a87A/qWEVRhJ4HMT11z214wWBUve37Dae0qeY3MVWB30Q0qg796w5ZsbSv792g0EXPD8MM4t59BddIzwvsnb0rxmVf/0DgOs63nj+UgyjYheTK/gAAAABJRU5ErkJggg==" title="Hospital"></th>'+t+'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACMAAAAjCAMAAAApB0NrAAAAflBMVEUAAACTkY2Nj42os6w4NzUbGhdfXFd9dXA6Ni9AOjppaGiFfG8bGxu1sKk9PT2JUEyrPzxqaWoyMjGKi4tPT06dnZ5aWlqUlJR7enl0dHSDg4Osq6w9PD0eHh+8u7pJR0OqnoqQgmLY19fJvqLFxMXj4uDd1sRvY0edVlPPKyuwC9OOAAAAEXRSTlMAcEQdBzxXARMgkJSUj4w6l2j20dYAAAGJSURBVDjLxZPbboMwDEC5hQS6tnOceyAwLt32/z84P7EKlXUv0ywukTjCx7ac/XNw/huCPyWu4keIvjUnqws6HCPlSUetdU7HI0QEra2OFg8YTohPq0ftwBzKFnGaFmNAqUvGH8ueU4wYOqkuzeNU19eUcDBglGoOZNnH5we2TDhyQTwX5QOZYvx8LbPSOQ1KDsoA26XjdF+bLNfBB3SUrZP9juFZkedl4QC0DwCgBqVeRLVrrrU2qL5fJo1gOkmXfGE0tW+XyqOlkkHZxWLw3hineinZ1gF6V+RoJKxRuiVqQOhc9LKTTNxBnF0uclwnHdcpSRLuXEJK11T83knU87qmhYwoyyAJgr5v60ZUmxJ53243+lFSQwDyVhh70Ih1teUj6DzPI1rsYhrHt/fBYECrsSbkrrrz7HyAYR7fKAjy4IOvdguQA4BS80jQqc4yUbe+2Xc7t4hKulN+FdsC7QdC3dZU8LZA9NjPtXXBmp5xiu/W7ZimbkGypztaVc+W+NkWb638w/gCvzYg9aZAgpsAAAAASUVORK5CYII=" title="Defence Systems"></th>'+t+frmicon+'" title="Food raw materials"></th>'+t+wrmicon+'" title="Weapons raw materials"></th></tr></thead><tbody></tbody></table></div>'),s.populateTable(),$("#inventory_overview .taxTable table tbody td").each(function(){var t=$(this).width()
$(".taxLinkHolder",this).width(t-4)})},populateTable:function(){$("#market_licenses_select .ml_repeat li").each(function(){function t(t,e,i){return'<a href="http://www.erepublik.com/'+LANG+"/economy/market/"+t+"/"+e+"/"+i+'/citizen/0/price_asc/1" target="_blank"><div class="taxLinkItem">Q'+i+"</div></a>"}var e=img_country[$(this).find("img").attr("src").split("/")[6].split(".")[0]].id,i={1:parseFloat(unsafeWindow.countryList[e].taxes[1].value_added_tax),2:parseFloat(unsafeWindow.countryList[e].taxes[2].value_added_tax),3:parseFloat(unsafeWindow.countryList[e].taxes[3].value_added_tax),5:parseFloat(unsafeWindow.countryList[e].taxes[5].value_added_tax),6:parseFloat(unsafeWindow.countryList[e].taxes[6].value_added_tax),7:parseFloat(unsafeWindow.countryList[e].taxes[7].value_added_tax),12:parseFloat(unsafeWindow.countryList[e].taxes[12].value_added_tax)}
e!=unsafeWindow.citizenshipCountry&&(i[1]+=parseFloat(unsafeWindow.countryList[e].taxes[1].import_tax),i[2]+=parseFloat(unsafeWindow.countryList[e].taxes[2].import_tax),i[3]+=parseFloat(unsafeWindow.countryList[e].taxes[3].import_tax),i[5]+=parseFloat(unsafeWindow.countryList[e].taxes[5].import_tax),i[6]+=parseFloat(unsafeWindow.countryList[e].taxes[6].import_tax),i[7]+=parseFloat(unsafeWindow.countryList[e].taxes[7].import_tax),i[12]+=parseFloat(unsafeWindow.countryList[e].taxes[12].import_tax)),$("#inventory_overview .taxTable table tbody").append('<tr><td style="padding-left:5px"><img style="vertical-align:top" src="'+$("img",this).attr("src")+'"> '+$("img",this).attr("alt")+'</td><td class="taxLink" style="text-align:center;padding-left:0px"><div class="taxLinkHolder"><div class="taxLinkItemTransparent"> </div>'+t(e,1,1)+t(e,1,2)+t(e,1,3)+t(e,1,4)+t(e,1,5)+t(e,1,6)+t(e,1,7)+"</div><span>"+i[1]+'%</span></td><td class="taxLink" style="text-align:center;padding-left:0px"><div class="taxLinkHolder"><div class="taxLinkItemTransparent"> </div>'+t(e,2,1)+t(e,2,2)+t(e,2,3)+t(e,2,4)+t(e,2,5)+t(e,2,6)+t(e,2,7)+"</div><span>"+i[2]+'%</span></td><td class="taxLink" style="text-align:center;padding-left:0px"><div class="taxLinkHolder"><div class="taxLinkItemTransparent"> </div>'+t(e,3,1)+t(e,3,2)+t(e,3,3)+t(e,3,4)+t(e,3,5)+"</div><span>"+i[3]+'%</span></td><td class="taxLink" style="text-align:center;padding-left:0px"><div class="taxLinkHolder"><div class="taxLinkItemTransparent"> </div>'+t(e,5,1)+t(e,5,2)+t(e,5,3)+t(e,5,4)+t(e,5,5)+"</div><span>"+i[5]+'%</span></td><td class="taxLink" style="text-align:center;padding-left:0px"><div class="taxLinkHolder"><div class="taxLinkItemTransparent"> </div>'+t(e,6,1)+t(e,6,2)+t(e,6,3)+t(e,6,4)+t(e,6,5)+"</div><span>"+i[6]+'%</span></td><td class="taxLink" style="text-align:center;padding-left:0px"><a href="http://www.erepublik.com/'+LANG+"/economy/market/"+e+'/7/1/citizen/0/price_asc/1" target="_blank">'+i[7]+'%</a></td><td class="taxLink" style="text-align:center;padding-left:0px"><a href="http://www.erepublik.com/'+LANG+"/economy/market/"+e+'/12/1/citizen/0/price_asc/1" target="_blank">'+i[12]+"%</a></td></tr>")})}}
$("#sell_offers tr[id^=offer_]").each(function(){a.createButton($(this)),n.createHolder($(this)),n.netPrice($(this)),r.createHolder($(this)),r.totalNetPrice($(this))}),e(),n.createHeader(),r.createHeader(),o.createRow(),s.createTable(),unsafeWindow.jQuery("body").ajaxComplete(function(t,e,i){var s,l
i.url.indexOf("/economy/postMarketOffer")>0?(s=$.parseJSON(e.responseText),l=$(s.html).attr("id"),a.waitForOffer(l),n.waitForOffer(l),r.waitForOffer(l),o.waitForOffer(l)):i.url.indexOf("/economy/deleteMarketOffer")>0&&(s=$.parseJSON(e.responseText),l=s.token.offerId,o.waitToDissapear("offer_"+l))})}})}function PreventScroll(){$(window).bind("scroll",function(){$("#large_sidebar").hasClass("fixed")&&($("#large_sidebar").removeClass("fixed"),$("#large_sidebar").attr("style",""),$("#large_sidebar").next().hide())})}function DrawLogo(){GM_addStyle("#eRS_settings{margin:2px 0 -5px 0;width:148px;box-shadow:inset 0px 1px 0px 0px #fff;background:linear-gradient(#ededed,#dfdfdf);border-radius:6px;border:1px solid #dcdcdc;display:inline-block;cursor:pointer;color:#777;font-family:Arial;font-size:11px;font-weight:bold;text-align:center;padding:6px 0px;text-shadow:0px 1px 0px #fff}#eRS_settings:hover{background:linear-gradient(#dfdfdf,#ededed)}#eRS_settings:active{position:relative;top:1px}#close_popup{position:absolute;top:-10px;right:-10px;cursor:pointer;float:right;background:black;border:2px solid white;border-radius:35px;box-shadow:-2px 2px 5px black;color:white;font-size:20px;font-weight:bold;height:23px;line-height:20px;width:23px}.setTitle{text-align:center;font-weight:bold;color:#FFF}#options_popup table{width:100%;text-align:left}#options_popup table td{padding:2px;vertical-align:top}#options_popup table td input{vertical-align:top;float:right;margin-right:10px}#options_popup table .rowHits input{float:none;margin:0 4px}.donateT a{color:white;background:black;border:5px solid black;border-radius:10px;margin:0 120px}.donateT a:hover{text-decoration:underline}"),$("body").append('<div id="eRS_blockUI"></div><div id="options_popup" style="display:none;background:#23b14d;border-radius:20px;box-shadow:0px 0px 10px 2px rgba(0,0,0,0.6);padding:15px;cursor:default"><strong id="close_popup">x</strong><div class="donateT" style="margin:0 0 10px 0;font-size:13px;font-weight:bold"><a href="http://userscripts.org/scripts/show/390674" target="_blank">Script Homepage</a><a href="http://www.erepublik.com/en/citizen/profile/6365664" target="_blank">Donate / Contact</a></div><table><tbody><tr><td><table><tr><td class="setTitle">Battlefield settings</td></tr><tr><td>Improve battlefield<input type="checkbox" id="improveBattlefield" /></td></tr><tr><td>Enable AutoBot<input type="checkbox" id="autoBot" /></td></tr><tr><td>Display hits needed to kill with equipped weapon<input type="checkbox" id="CalculateHits" /></td></tr><tr><td class="rowHits" style="text-align:center">Q0<input type="checkbox" id="CalculateHitsQ0" />Q1&nbsp;<input type="checkbox" id="CalculateHitsQ1" />Q2<input type="checkbox" id="CalculateHitsQ2" />Q3<input type="checkbox" id="CalculateHitsQ3" />Q4<input type="checkbox" id="CalculateHitsQ4" />Q5<input type="checkbox" id="CalculateHitsQ5" />Q6<input type="checkbox" id="CalculateHitsQ6" />Q7<input type="checkbox" id="CalculateHitsQ7" /></td></tr><tr><td>Show TP damage<input type="checkbox" id="TPmedal" /></td></tr><tr><td>Build booster, rocket or bazooka in battle<input type="checkbox" id="boostBattle" /></td></tr><tr><td>Show mercenary kills on each side<input type="checkbox" id="mercBT" /></td></tr><tr><td>Automatically close wrong side warning<input type="checkbox" id="WrongSideNotice" /></td></tr><tr><td></td></tr><tr><td class="setTitle">Campaign settings</td></tr><tr><td>Mark natural enemy<input type="checkbox" id="showNE" /></td></tr><tr><td>Show dom. points and wall percentages<input type="checkbox" id="campaignPoints" /></td></tr><tr><td>Show mercenary points<input type="checkbox" id="mercenaryPoints" /></td></tr><tr><td>Add direct links for each side in RWs<input type="checkbox" id="CampaignRWQuickLinks" /></td></tr><tr><td>Refresh campaign page automatically<input type="checkbox" id="CampaignRefresh" /></td></tr><tr><td></td></tr><tr><td class="setTitle">Company settings</td></tr><tr><td>Company manager<input type="checkbox" id="companyManager" /></td></tr><tr><td>Select multiple employees to fire<input type="checkbox" id="fireSelected" /></td></tr><tr><td>Change salary for all<input type="checkbox" id="changeSalaryAll" /></td></tr><tr><td>Sort employees by salary<input type="checkbox" id="sortWages" /></td></tr></table></td><td><table><tr><td class="setTitle">Common settings</td></tr><tr><td>Automatic energy recovery<input type="checkbox" id="autoEnergyRecover" /></td></tr><tr><td>Stop recovery to maximize level-up refill<input type="checkbox" id="LvlupNoRecovery" /></td></tr><tr><td>Display XP needed to level-up<input type="checkbox" id="XPLeft" /></td></tr><tr><td>Prevent sidebar scroll<input type="checkbox" id="preventSidebarScroll" /></td></tr><tr><td>Show max energy recover<input type="checkbox" id="maxEnergy" /></td></tr><tr><td>Kills, damage and hits on sidebar<input type="checkbox" id="noKillsDamage" /></td></tr><tr><td>Remove external link warning <input type="checkbox" id="removeExternalLinkWarn" /></td></tr><tr><td>Quick access to MUDO change<input type="checkbox" id="doQuickAccess" /></td></tr><tr><td><tr><td class="setTitle">Donation settings</td></tr><tr><td>Remember donation quantity<input type="checkbox" id="rememberDonation" /></td></tr><tr><td>Donate from everywhere<input type="checkbox" id="showDonate" /></td></tr><tr><td></td></tr></td></tr><tr><td class="setTitle">Inventory settings</td></tr><tr><td>Improve inventory<input type="checkbox" id="improveInventory" /></td></tr><tr><td>Display storage inventory<input type="checkbox" id="showStorageInv" /></td></tr><tr><td class="rowHits" style="text-align:right;padding-right:10px">All items<input type="radio" name="AllStock" value="1">Items in stock<input type="radio" name="AllStock" value="2"></td></tr><tr><td>Display storage info<input type="checkbox" id="storageCapacity" /></td></tr><tr><td>Autofill amount and real price<input type="checkbox" id="getItemPrice" /></td></tr><tr><td>Display rocket pack price<input type="checkbox" id="cheaperPack" /></td></tr></table></td><td><table><tr><td class="setTitle">Main page settings</td></tr><tr><td>Shout and share posts on walls<input type="checkbox" id="reShout" /></td></tr><tr><td>Filter posts from guerrilla info<input type="checkbox" id="filterGuerrilla" /></td></tr><tr><td>Filter posts from medals info<input type="checkbox" id="filterMedals" /></td></tr><tr><td>Latest and international news categories<input type="checkbox" id="newNews" /></td></tr><tr><td></td></tr><tr><td class="setTitle">Marketplace settings</td></tr><tr><td>Autofill maximum product amount<input type="checkbox" id="MarketplaceAutofill" /></td></tr><tr><td>Product quick links<input type="checkbox" id="quickMarket" /></td></tr><tr><td>Price comparator<input type="checkbox" id="showPriceCompare" /></td></tr><tr><td>Display cost per use<input type="checkbox" id="showProfitability" /></td></tr><tr><td></td></tr><tr><td class="setTitle">Messaging settings</td></tr><tr><td>Improve message system<input type="checkbox" id="improveMessages" /></td></tr><tr><td>Save last message<input type="checkbox" id="betterIgm" /></td></tr><tr><td>Show recipients in inbox<input type="checkbox" id="showRec" /></td></tr><tr><td></td></tr><tr><td class="setTitle">Monetary market settings</td></tr><tr><td>Autofill maximum gold amount<input type="checkbox" id="improveExchangeMarket" /></td></tr><tr><td>Search my offer<input type="checkbox" id="findOffer" /></td></tr><tr><td></td></tr><tr><td class="setTitle">Profile settings</td></tr><tr><td>Improve profile page<input type="checkbox" id="improveProfilePage" /></td></tr><tr><td>Influence calculator<input type="checkbox" id="InfluenceCalculator" /></td></tr></table></td></tr></tbody><table></table></div>')
for(i in options)"AllStock"!=i?$("input#"+i+"[type=checkbox]").length>0&&$("#"+i).prop("checked",options[i]):$("input[name="+i+"][type=radio][value="+options[i]+"]").prop("checked",!0)
$("#options_popup input").change(function(){"checkbox"==$(this).attr("type")&&(options[$(this).attr("id")]=$(this).prop("checked")),"radio"==$(this).attr("type")&&(options[$(this).attr("name")]=parseInt($("input:radio[name="+$(this).attr("name")+"]:checked").val())),GM_setValue(eRS.citizenId+".eRS_options",JSON.stringify(options))}),$(".user_finances").after("<div id='eRS_settings' original-title='Click to open settings'>eRepublik Stuff++ "+GM_info.script.version+"</div>"),$("#eRS_settings").tipsy({gravity:"n"}),$("#eRS_settings").click(function(){var t=$("#options_popup").height(),e=$(window).height(),i=e>t?Math.round((e-t)/2)+"px":"50px"
$("#eRS_blockUI").css({display:"block",position:"absolute",top:"0px",left:"0px",width:"100%",height:$(document).height(),"background-color":"black","z-index":"999998",opacity:"0.5",cursor:"not-allowed"}),$("#options_popup").css({display:"block",position:"fixed",width:"880px",top:i,left:($(window).width()-880)/2+$(window).scrollLeft()+"px","z-index":"999999","text-align":"center"})}),$("#options_popup #close_popup").click(function(){$("#eRS_blockUI,#options_popup").hide()})}function CheckForUpdate(){date!=GM_getValue("updatecheckdate")&&(GM_setValue("updatecheckdate",date),GM_xmlhttpRequest({method:"GET",url:"http://userscripts.org/scripts/source/390674.meta.js",onload:function(t){t.responseText.split("@version")[1].split("\n")[0].trim()!=GM_info.script.version&&$("#header").after('<div style="width:auto;clear:both;text-align:center;padding:5px;border-radius:5px;background:black;font-weight:bold;font-size:20px;color:red">YOUR CURRENT VERSION OF EREPUBLIK STUFF++ IS OUT OF DATE. UPDATE IT <a href="http://userscripts.org/scripts/source/390674.user.js">HERE</a>.</div>')}}))}function RemoveExternalLinkWarn(){function t(){$('a[href*="/main/warn/"]').each(function(){var t,e=$(this).text()
4==window.location.href.split("/").length||-1!=e.indexOf("www.")||-1!=e.indexOf("http://")||-1!=e.indexOf("https://")?(-1==e.indexOf("http://")&&-1==e.indexOf("https://")&&(e="http://"+e),$(this).attr("href",e)):(t=$(this),GM_xmlhttpRequest({method:"GET",url:$(this).attr("href"),onload:function(e){var i=e.responseText.split('class="content"')[1].split('href="')[1].split('"')[0]
$(t).attr("href",i)}}))})}unsafeWindow.jQuery("body").ajaxComplete(function(e,i,a){(a.url.indexOf("/main/wall-comment/retrieve/")>0||a.url.indexOf("/main/party-comment/retrieve/")>0||a.url.indexOf("/main/party-post/")>0||a.url.indexOf("/main/group-wall/retrieve/")>0||a.url.indexOf("/main/group-wall/older/")>0||a.url.indexOf("/main/messages-compose/")>0||a.url.indexOf("/main/messages-read/")>0)&&setTimeout(function(){t()},500)}),t()}function XPLeft(){var t,e
$("#xpleft").remove(),t=$("#experienceTooltip strong").eq(2).text()-$("#experienceTooltip strong").eq(1).text(),e=unsafeWindow.reset_health_to_recover<=10*t?"#6ebce5":"red",$(".user_level").append('<div id="xpleft" style="float:right;position:relative;top:14px;font-size:10px;color:#777">XP left: <span style="background:'+e+';color:white;font-weight:bold;padding:1px;border-radius:2px">'+t+"</span></div>"),setTimeout(XPLeft,200)}function CompanyManager(){function t(t,e){var i=$(t),a=i.parent().parent()
return $(".area").hasClass("disable_controls")||a.hasClass("disabled")?!1:(i.hasClass("active")&&!e?i.removeClass("active"):e&&i.addClass("active"),unsafeWindow.checkHealth(),void setTimeout(function(){unsafeWindow.calculateProduction(a)},50))}function e(t,e){var i,a,n,o,r
return $(".area").hasClass("disable_controls")?!1:(i=$(t),i.hasClass("worked")?!1:(a=parseInt(i.attr("employee")),n=i.parent().parent().parent(),i.hasClass("active")&&!e?(o=$(".employee_works.row_two.active",n),$(".employee_works",n).removeClass("active"),o.length&&5==a&&$(".no5",n).addClass("active")):e&&($(".employee_works",n).removeClass("active"),a>5&&$(".no5",n).addClass("active"),i.addClass("active")),r=0,$.each($(".employee_works.active"),function(t,e){var i,a=$(e).parent().parent().parent().attr("id").split("_")[1]
company=unsafeWindow.getCompany(a),i=parseInt($(e).attr("employee")),i-=i>5?5:company.todays_works,r+=i}),r>unsafeWindow.pageDetails.total_works?($("#preset_works").parent().attr("title",unsafeWindow.pageDetails.employee_warn),$("#preset_works").parent().parent().addClass("critical")):($("#preset_works").parent().attr("title",unsafeWindow.pageDetails.employee_tooltip),$("#preset_works").parent().parent().removeClass("critical")),$("#preset_works").html(r),void setTimeout(function(){unsafeWindow.calculateProduction(n)},50)))}function i(t,e){var i,n,o,r,s,l,d
if($(".subMenu").hide(),i='<div id="'+e+'" class="area_controls" style="width:100%;margin-top:9px">',i+='<strong title="Select Companies" style="margin-top:6px">Select Companies</strong><div>',n="",o="","factories"==t){for(r=1;8>r;r++)1==r?n="left_pos":7==r?(o='style="margin-right: 10px;"',n="right_pos"):n="mid",i+='<a href="javascript:;" class="grey_plastic '+n+'" '+o+' title="Work in food factory Q'+r+'" name="factory_food_'+r+'"><img src="http://s3.www.erepublik.net/images/modules/myland/buildings/food_q'+r+'.png" style="height:18px"></a>'
for(r=1;8>r;r++)n=1==r?"left_pos":7==r?"right_pos":"mid",i+='<a href="javascript:;" class="grey_plastic '+n+'" title="Work in weapons factory Q'+r+'" name="factory_weapons_'+r+'"><img src="http://s3.www.erepublik.net/images/modules/myland/buildings/weapons_q'+r+'.png" style="height:18px"></a>'}else if("raw"==t){for(s=["grain","fruits","fish","cattle","deer"],l=["iron","oil","aluminum","saltpeter","rubber"],d="managerWork"==e?1:3,r=d;6>r;r++)r==d?n="left_pos":5==r?(o='style="margin-right: 10px;"',n="right_pos"):n="mid",i+='<a href="javascript:;" class="grey_plastic '+n+'" '+o+' title="Work in food raw factory Q'+r+'" name="food_raw_'+s[r-1]+'"><img src="http://s3.www.erepublik.net/images/modules/myland/buildings/'+s[r-1]+'.png" style="height:18px"></a>'
for(r=d;6>r;r++)n=r==d?"left_pos":5==r?"right_pos":"mid",i+='<a href="javascript:;" class="grey_plastic '+n+'" title="Work in weapons raw factory Q'+r+'" name="weps_raw_'+l[r-1]+'"><img src="http://s3.www.erepublik.net/images/modules/myland/buildings/'+l[r-1]+'.png" style="height:18px"></a>'}$(".subMenu").html(i+"</div></div>"),$("#managerWork a").unbind("click"),$("#employeesWork a").unbind("click"),a(),$(".subMenu").show(300)}function a(){$("#managerWork a").click(function(){var e,a,n
$(this).hasClass("disabled")||(e=$(this).attr("name"),"factories"==e?($("#managerWork a").removeClass("active"),$("#employeesWork a").removeClass("active"),$(this).addClass("active"),i("factories","managerWork")):"raws"==e?($("#managerWork a").removeClass("active"),$("#employeesWork a").removeClass("active"),$(this).addClass("active"),i("raw","managerWork")):-1!=e.indexOf("factory_food_")?(a=e.split("_")[2],$("div[id*=company_].upgradeable").each(function(){if(-1!=$("img:eq(2)",this).attr("src").indexOf("food_q"+a)){var e=$(".area_options.c3 a",this)
t(e,!0)}})):-1!=e.indexOf("factory_weapons_")?(a=e.split("_")[2],$("div[id*=company_].upgradeable").each(function(){if(-1!=$("img:eq(2)",this).attr("src").indexOf("weapons_q"+a)){var e=$(".area_options.c3 a",this)
t(e,!0)}})):-1!=e.indexOf("food_raw_")||-1!=e.indexOf("weps_raw_")?(n=e.split("_")[2],$("div[id*=company_]:not(.upgradeable)").each(function(){if(-1!=$("img:eq(1)",this).attr("src").indexOf(n)){var e=$(".area_options.c3 a",this)
t(e,!0)}})):"all"==e?($("#managerWork a").removeClass("active"),$("#employeesWork a").removeClass("active"),$(this).addClass("active"),$("div[id*=company_]").each(function(){var e=$(".area_options.c3 a",this)
t(e,!0)})):"clear"==e&&($("#managerWork a").removeClass("active"),$("#employeesWork a").removeClass("active"),$(this).addClass("active"),$("div[id*=company_]").each(function(){var e=$(".area_options.c3 a",this)
t(e,!1)})))}),$("#employeesWork a").click(function(){var t,a,n
$(this).hasClass("disabled")||(t=$(this).attr("name"),"factories"==t?($("#managerWork a").removeClass("active"),$("#employeesWork a").removeClass("active"),$(this).addClass("active"),i("factories","employeesWork")):"raws"==t?($("#managerWork a").removeClass("active"),$("#employeesWork a").removeClass("active"),$(this).addClass("active"),i("raw","employeesWork")):-1!=t.indexOf("factory_food_")?(a=t.split("_")[2],$("div[id*=company_].upgradeable .employees_selector").each(function(){var t,i;-1!=$("img:eq(2)",$(this).parent().parent()).attr("src").indexOf("food_q"+a)&&(t=parseInt($(this).attr("class").split(" ")[1].replace("allow","")),i=$("a",this).eq(t-1),e(i,!0))})):-1!=t.indexOf("factory_weapons_")?(a=t.split("_")[2],$("div[id*=company_].upgradeable .employees_selector").each(function(){var t,i;-1!=$("img:eq(2)",$(this).parent().parent()).attr("src").indexOf("weapons_q"+a)&&(t=parseInt($(this).attr("class").split(" ")[1].replace("allow","")),i=$("a",this).eq(t-1),e(i,!0))})):-1!=t.indexOf("food_raw_")||-1!=t.indexOf("weps_raw_")?(n=t.split("_")[2],$("div[id*=company_]:not(.upgradeable) .employees_selector").each(function(){var t,i;-1!=$("img:eq(1)",$(this).parent().parent()).attr("src").indexOf(n)&&(t=parseInt($(this).attr("class").split(" ")[1].replace("allow","")),t>0&&(i=$("a",this).eq(t-1),e(i,!0)))})):"all"==t?($("#managerWork a").removeClass("active"),$("#employeesWork a").removeClass("active"),$(this).addClass("active"),$(".employees_selector").each(function(){var t,i=parseInt($(this).attr("class").split(" ")[1].replace("allow",""))
i>0&&(t=$("a",this).eq(i-1),e(t,!0))})):"clear"==t&&($("#managerWork a").removeClass("active"),$("#employeesWork a").removeClass("active"),$(this).addClass("active"),$(".employees_selector").each(function(){var t=parseInt($(this).attr("class").split(" ")[1].replace("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jY9T4geY2RlC+C8DfAAAAABJRU5ErkJggg=="
$(".manager_dashboard .listing_holder .heading").before('<div class="heading"><div id="managerWork" class="area_controls" style="width:351px"><strong title="Manage Companies">Manage Companies</strong><div style="margin-top:9px"><a href="javascript:;" class="grey_plastic left_pos" title="Factories" name="factories"><img src="'+p+'"></a><a href="javascript:;" class="grey_plastic mid" title="Raw Companies" name="raws"><img src="'+A+'"></a><a href="javascript:;" class="grey_plastic mid" title="All Companies" name="all"><img src="'+g+'"></a><a href="javascript:;" class="grey_plastic right_pos" title="Clear All Companies" name="clear"><img src="'+m+'"></a></div></div><div id="employeesWork" class="area_controls" style="width:351px"><strong title="Manage Employees">Manage Employees</strong><div style="margin-top:9px"><a href="javascript:;" class="grey_plastic left_pos" title="Factories" name="factories"><img src="'+p+'"></a><a href="javascript:;" class="grey_plastic mid" title="Raw Companies" name="raws"><img src="'+A+'"></a><a href="javascript:;" class="grey_plastic mid" title="All Companies" name="all"><img src="'+g+'"></a><a href="javascript:;" class="grey_plastic right_pos" title="Clear All Companies" name="clear"><img src="'+m+'"></a></div></div></div><div class="heading subMenu" style="width:100%;display:none"></div>'),n=0,o=0,r=0,s=0,l=0,d=0,c=0,a(),o=parseInt($(".employees_available strong").text().split("/")[1].trim()),c=$("div[id*=company_]:not(.disabled)").length,0==c?$("#managerWork div a").addClass("disabled"):(l=$("div[id*=company_].upgradeable:not(.disabled)").length,d=$("div[id*=company_]:not(.upgradeable):not(.disabled)").length,0==l&&$("#managerWork div a[name=factories]").addClass("disabled"),0==d&&$("#managerWork div a[name=raw]").addClass("disabled")),$("#managerWork a, #employeesWork a").tipsy({gravity:"s"})}function Battlefield(){function t(){$("#left_top5,#right_top5,#campaign_left_top5").remove()
var t='<table><thead><tr><th width="80">Citizen</th><th width="30">Kills</th><th width="90">Influence</th></tr></thead><tbody><tr><td class="nick"></td><td class="kills"></td><td class="influence"></td></tr><tr><td class="nick"></td><td class="kills"></td><td class="influence"></td></tr><tr><td class="nick"></td><td class="kills"></td><td class="influence"></td></tr><tr><td class="nick"></td><td class="kills"></td><td class="influence"></td></tr><tr><td class="nick"></td><td class="kills"></td><td class="influence"></td></tr></tbody><tfoot><tr><td>Sum</td><td class="kills"></td><td class="influence"></td></tr></tfoot></table>'
$("#pvp_battle_area").append('<div id="left_top5" class="top5_list">'+t+'</div><div id="right_top5" class="top5_list">'+t+'</div><div id="campaign_left_top5" class="top5_list">'+t+"</div>")}function e(){var t,e,l,d,c,p,A
try{t=s.stats.current[a][n][o],e=s.stats.current[a][n][r],l=s.stats.overall[0][o],d=0,c=0
for(i in t)p=t[i],d+=parseInt(p.kills),c+=parseInt(p.damage),A=$("#left_top5 tbody tr").eq(i),A.find(".nick").html('<a href="/'+LANG+"/citizen/profile/"+p.citizen_id+'" target="_blank">'+s.fightersData[p.citizen_id].name+"</a>"),A.find(".kills").text(p.kills),A.find(".influence").text(comma(p.damage))
$("#left_top5 tfoot tr td.kills").text(d),$("#left_top5 tfoot tr td.influence").text(comma(c)),d=0,c=0
for(i in e)p=e[i],d+=parseInt(p.kills),c+=parseInt(p.damage),A=$("#right_top5 tbody tr").eq(i),A.find(".nick").html('<a href="/'+LANG+"/citizen/profile/"+p.citizen_id+'" target="_blank">'+s.fightersData[p.citizen_id].name+"</a>"),A.find(".kills").text(p.kills),A.find(".influence").text(comma(p.damage))
$("#right_top5 tfoot tr td.kills").text(d),$("#right_top5 tfoot tr td.influence").text(comma(c)),d=0,c=0
for(i in l)p=l[i],d+=parseInt(p.kills),c+=parseInt(p.damage),A=$("#campaign_left_top5 tbody tr").eq(i),A.find(".nick").html('<a href="/'+LANG+"/citizen/profile/"+p.citizen_id+'" target="_blank">'+s.fightersData[p.citizen_id].name+"</a>"),A.find(".kills").text(p.kills),A.find(".influence").text(comma(p.damage))
$("#campaign_left_top5 tfoot tr td.kills").text(d),$("#campaign_left_top5 tfoot tr td.influence").text(comma(c))}catch(g){}}var a,n,o,r,s
setDamageKills(),GM_addStyle(".top5_list{position:absolute;top:170px;padding:5px;border-radius:5px;width:200px;background:#242b27;box-shadow:0 0 10px black;color:white;cursor:default;z-index:9}.top5_list thead th,.top5_list tfoot{text-align:center;color:#91CC17;font-weight:bold}.top5_list thead th{color:#91CC17}.top5_list tfoot{color:red}.top5_list .influence,.top5_list .kills{text-align:right}.top5_list .nick{white-space:nowrap;max-width:85px;overflow:hidden}#left_top5{left:15px}#right_top5{right:15px}#campaign_left_top5{left:275px;top:180px}#mu_missions{top:240px}.battle-mini-button-holder{z-index:200}#collection_complete,.blockUI.blockOverlay,.blockUI blockMsg blockElement{display:none!important}.booster_activation{background:rgba(0,0,0,0.5);border-radius:5px;padding:0px;bottom:5px}.weapon.selector{top:-10px}#change_weapon{z-index:1}#pvp_header h2{top:2px}.campaign_toggler{margin-top:8px}#pvp_header .battle_hero{top:106px}#pvp_battle_area .player{margin-top:140px}#pvp_battle_area .player.left_side{margin-left:15px}#pvp_battle_area .player.right_side{margin-right:15px}#pvp .campaign_details .entry em{opacity:1}#pvp .campaign_details .entry .pdomi_left em{right:5px}.country{top:7px!important}.resistance_badge{top:120px!important}"),$(".addon").css("cssText","right:570px;background:rgba(0,0,0,0.5);border-radius:5px;padding:0px;top:30px;"),a=unsafeWindow.SERVER_DATA.zoneId,n=GetDivision(),o=img_country[$(".country.left_side a img").attr("src").split("/")[6].split(".")[0]].id,r=img_country[$(".country.right_side a img").attr("src").split("/")[6].split(".")[0]].id,clearInterval(unsafeWindow.globalSleepInterval),unsafeWindow.shootLockout=1,t(),$j(document).ajaxSuccess(function(t,i,a){if(a.url.match(/military\/battle-stats/)){var t=JSON.parse(i.responseText).campaigns
$("div.mission_details").each(function(){for(var e=0;e<t.length;e++)t[e].id===$(this).find("input").attr("id")&&$("div.mission_details").eq(e).find("label div p").eq(1).html(t[e].reward+$("div.currency_amount p span").text()+"/1M Budget: "+t[e].budget+$("div.currency_amount p span").text())}),s=JSON.parse(i.responseText),e()}}),$("#pvp_battle_area").append('<div class="eRSDiviSelect" style="position:absolute;top:290px;left:350px;cursor:pointer"><span style="position:absolute;background:#ec5d04;border-radius:2px;color:white;font-size:11px;font-weight:bold;height:24px;text-align:center;line-height:24px;width:60px">Division '+n+'</span><select style="background-color:transparent;color:#4B5E6B;vertical-align:middle;height:24px;width:60px;opacity:0;position:absolute;z-index:11;cursor:pointer" id="diviselect"><option value="1">Division 1</option><option value="2">Division 2</option><option value="3">Division 3</option><option value="4">Division 4</option></select></div>'),$("#diviselect").change(function(){n=$(this).val(),$(".eRSDiviSelect span").text("Division "+n),t(),e()}),setInterval(function(){$("#notify_link").is(":visible")&&location.reload(!0)},1e3)}function CalculateHits(){function t(){var t,i=$("#enemy_skill").text().replace(/,/g,""),o=$("#scroller .listing span:last img").attr("src").split("_")[1].split(".")[0],r=void 0==$("#enemy_weapon").attr("src").split("_")[1]?"boss":a[$("#enemy_weapon").attr("src").split("_")[1].split(".")[0]],s=void 0==$("#enemy_life").attr("original-title")?$("#enemy_life").attr("title").split(":")[1].trim():$("#enemy_life").attr("original-title").split(":")[1].trim(),l=e(n,i,a[o],r,s)
for(("boss"!=r&&"q10"==o||"q11"==o)&&(l=1),$("#eRS_hitsHolder strong").eq(0).text("EQ: "+l),t=0;8>t;t++)$("#hitsQ"+t).text("Q"+t+": "+e(n,i,a["q"+t],r,s))}function e(t,e,i,a,n){if("boss"==a)return"X"
0==i&&(i=-15)
var o=(60+(t-e)/10)*(1+(i-a)/400)/2
return $(".booster_timer").length>0&&(o*=1.5),Math.ceil(n/o)}var i,a,n
for(GM_addStyle("#eRS_hitsHolder{position:absolute;text-align:center;width:40px;border-radius:7px;padding:5px;top:-7px;left:-48px;background:#242b27;z-index:10}#eRS_hitsHolder div{font-weight:bold;color:white}#eRS_hitsHolder strong{line-height:13px;text-align:center;height:16px;font-size:11px;display:inline;padding:0 4px 0 4px;background-color:#83B70B;border-radius:3px;color:white}"),$("#pvp_battle_area .player.right_side").append('<div id="eRS_hitsHolder"><div>Hits</div><strong></strong></div>'),i=0;8>i;i++)options["CalculateHitsQ"+i]&&$("#eRS_hitsHolder strong").eq(-1).after("<br><strong id='hitsQ"+i+"'></strong>")
$("#eRS_hitsHolder strong").eq(0).css("background-color","#FB7E3D"),a={q0:0,"q-1":0,q1:20,q2:40,q3:60,q4:80,q5:100,q6:120,q7:200,q10:100},n=$("#fighter_skill").text().replace(/,/g,""),t(),setInterval(t,100)}function EnergyRecoverer(){var t=$("#experienceTooltip strong").eq(2).text()-$("#experienceTooltip strong").eq(1).text()
options.LvlupNoRecovery&&unsafeWindow.globalNS.userInfo.wellness+unsafeWindow.food_remaining>=10*t||(setTimeout(function(){location.reload()},18e5),unsafeWindow.globalNS.userInfo.wellness<unsafeWindow.reset_health_to_recover&&unsafeWindow.food_remaining>0&&$j.getJSON("http://www.erepublik.com/"+LANG+"/main/eat?format=json&_token="+unsafeWindow.SERVER_DATA.csrfToken+"&buttonColor=blue&jsoncallback=?",{},function(t){unsafeWindow.energy.processResponse(t)}),setTimeout(EnergyRecoverer,1e4))}function CustomOffer(){var t,e,i,a,n,o,r,s
if(0==$(".success_message").length&&0==$(".error_message").length){if(t=window.location.href.split("?")[1],"undefined"==typeof t)return
if(e="true"==t.split("customOffer=")[1].split("&")[0]?!0:!1,i=parseInt(t.split("sellerId=")[1].split("&")[0]),a=decodeURI(t.split("sellerName=")[1].split("&")[0]),n=parseInt(t.split("offerId=")[1].split("&")[0]),o=parseInt(t.split("offerAmount=")[1].split("&")[0]),r=t.split("offerPrice=")[1],!e||isNaN(i)||isNaN(o)||isNaN(r))return
$("#marketplace table tbody tr:not(:first),#marketplace .pager").remove(),s=$("#marketplace table tbody tr:first"),$(".m_product",s).attr("id","productId_"+n),$(".m_provider a",s).attr("href","/en/citizen/profile/"+i),$(".m_provider a",s).text(a),$(".m_stock",s).text(o),$(".m_price strong:first",s).text(r.split(".")[0]),$(".m_price sup",s).html("."+r.split(".")[1]+" "+unsafeWindow.erepublik.citizen.currency),$(".m_quantity input",s).attr({id:"amount_"+n,maxlength:"6"}),$(".m_buy a",s).attr({id:n,"data-max":o,"data-price":r})}}function ShowMercenary(){GM_addStyle("#achievment .hinter .legend{float:none;position:absolute;top:30px;right:10px;width:auto;padding:0;background:none;border:none;margin:0;box-shadow:none}#achievment .hinter .country_list em{opacity:1;position:static;float:left}#achievment .hinter .region_list em{position:absolute}#achievment .hinter .country_list li small{cursor:default;color:#666}#achievment .hinter .country_list li img{opacity:1}"),$("#achievment .hinter .country_list:eq(1) li em").each(function(){var t=$(this).text().split("/")[0],e=.5
25==t?e=1:t>=20?e=.8:t>=10?e=.7:t>0&&(e=.6),$(this).css("opacity",e)}),$("#achievment .hinter .country_list").eq(1).before('<ul class="country_list legend"><li><em style="opacity:0.5">0</em></li><li><em style="opacity:0.6">1-9</em></li><li><em style="opacity:0.7">11-19</em></li><li><em style="opacity:0.8">21-24</em></li><li><em style="opacity:1">25</em></li></ul>')}function AddLinks(){$(".citizen_profile_header img").wrap('<a href="'+$(".citizen_profile_header img").css("background-image").split('url("')[1].split("_")[0]+'.jpg" target="_blank"></a>'),$("#donate_to_friend div").remove(),GM_addStyle("a.ambassador{margin-top:26px}span.top_player{margin-right:45px}span.game_mod3{margin-right:-38px}")}function InfluenceCalculator(){function t(){var t,i,a,o=$("#InfCalc_hits").val()
for(t=0;8>t;t++)i=7>t?20*t:200,a=10*(1+$(".citizen_military").eq(0).find(".stat small strong").text().split("/")[0].trim().replace(",","")/400)*(1+img_rank[$(".citizen_military").eq(1).find("h4 img").attr("src").split("/")[6].split(".")[0]]/5)*(1+i/100),$("#InfCalc_NE").is(":checked")&&(a*=1.1),$("#InfCalc_BO").is(":checked")&&(a*=1.5),$(".citizen_level").eq(0).text()>101&&(a*=1.1),$("#InfCalc_Q"+t+" span").html("<br>Dmg: "+comma(Math.round(o*a))+"<br>Need: "+comma(Math.ceil(n/a))+"<br>Days: "+comma(Math.ceil(n/a/o))+"<br>Cost: "+comma(Math.ceil(100*e[t]*1e6/a)/100)+$("div.currency_amount p span").text()+"/1M")}var e,i,a,n,o,r,s
for(GM_addStyle("#eRS_InfCalc #InfCalc_hits{background:white;box-shadow:inset 0px 1px 1px #a6a6a6;border-color:#AEAEAE #C8C8C8 #E3E3E3;border-radius:3px;border-style:solid;border-width:1px;color:#333;padding:4px;text-align:center;width:35px;font-size:10px;margin:0 20px 0 5px}#eRS_InfCalc table td{width:25%}#eRS_InfCalc table td span{width:44px;font-size:11px;color:#666;margin-left:10px}#eRS_InfCalc table img{vertical-align:middle}#InfCalc_BO,#InfCalc_NE{vertical-align:middle;margin-left:5px}"),e=[0],n=10*($(".citizen_military").eq(1).find(".stat small strong").text().split("/")[1].trim().replace(/,/g,"")-$(".citizen_military").eq(1).find(".stat small strong").text().split("/")[0].trim().replace(/,/g,"")),o=1;8>o;o++)GM_xmlhttpRequest({method:"GET",url:"http://m.erepublik.com/"+LANG+"/economy/market/"+img_country[eRS.country].id+"/2/"+o+"/citizen/0/price_asc/1",onload:function(n){i=n.responseText.split('" quality="')[1].split('"')[0],a=7>i?i:10,e[i]=n.responseText.split('<div class="c1">')[2].split("<strong>")[1].split(" ")[0]/a,t()}})
$(".citizen_military").eq(1).after('<h3>Influence Calculator</h3><div id="eRS_InfCalc" class="citizen_military"><div style="margin:0 15px;line-height:44px;color:#666;font-size:11px"><span>Hits <input type="text" id="InfCalc_hits" /></span><span>Natural Enemy <input type="checkbox" id="InfCalc_NE" /></span><span style="margin-left:15px">50% bonus <input type="checkbox" id="InfCalc_BO" /></span></div><table style="width:100%;margin-left:15px"><tr><td id="InfCalc_Q0"><img src="'+itemicons[2][1]+'" style="opacity:0.5"><span></span></td><td id="InfCalc_Q1"><img src="'+itemicons[2][1]+'"><span></span></td><td id="InfCalc_Q2"><img src="'+itemicons[2][2]+'"><span></span></td><td id="InfCalc_Q3"><img src="'+itemicons[2][3]+'"><span></span></td></tr><tr><td id="InfCalc_Q4"><img src="'+itemicons[2][4]+'"><span></span></td><td id="InfCalc_Q5"><img src="'+itemicons[2][5]+'"><span></span></td><td id="InfCalc_Q6"><img src="'+itemicons[2][6]+'"><span></span></td><td id="InfCalc_Q7"><img src="'+itemicons[2][7]+'"><span></span></td></tr></table></div>'),r=GM_getValue(eRS.citizenId+".eRS_Hits"),s="undefined"==typeof r?1:JSON.parse(r),$("#InfCalc_hits").val(s),$("#InfCalc_hits").keyup(function(){GM_setValue(eRS.citizenId+".eRS_Hits",JSON.stringify($(this).val())),t()}),$("#InfCalc_NE,#InfCalc_BO").change(function(){t()})}function GetDivision(t){var t=parseInt($(".user_level b").text())
return t>=70?4:t>=50?3:t>=35?2:1}function GetPoints(){GM_addStyle(".tipsy-inner,.tipsy{max-width:313px!important}"),$(".bod_listing li,.country_battles li,.allies_battles li,.all_battles li").each(function(){var t=$(this),e=img_country[t.find("img.side_flags").eq(0).attr("src").split("/")[6].split(".")[0]].id,i=img_country[t.find("img.side_flags").eq(1).attr("src").split("/")[6].split(".")[0]].id
$.getJSON("/"+LANG+"/military/battle-stats/"+t.attr("id").split("-")[1],function(a){function n(t){return t==g?'style="background:#C1E4F1;color:#000;border-radius:5px"':void 0}var o=a.stats.current[Object.getOwnPropertyNames(a.stats.current)],r="domination",s="points",l=a.division,d=Math.round(l[r][1]),c=Math.round(l[r][2]),p=Math.round(l[r][3]),A=Math.round(l[r][4]),g=GetDivision()
t.find(".tank_img").attr("original-title",'<table width="300px"><tr><td> Points </td><td> Dom </td><td> Wall </td><td> Div </td><td> Wall </td><td> Dom </td><td> Points </td></tr><tr '+n(1)+"><td> "+l[e][1][s]+" </td><td>"+l[e][1][r]+"</td><td> "+(100-d)+"% </td><td>I</td><td> "+d+"% </td><td>"+l[i][1][r]+"</td><td> "+l[i][1][s]+" </td></tr><tr "+n(2)+"><td> "+l[e][2][s]+"</td><td>"+l[e][2][r]+"</td><td> "+(100-c)+"% </td><td>II</td><td> "+c+"% </td><td>"+l[i][2][r]+"</td><td> "+l[i][2][s]+" </td></tr><tr "+n(3)+"><td> "+l[e][3][s]+"</td><td>"+l[e][3][r]+"</td><td> "+(100-p)+"% </td><td>III</td><td> "+p+"% </td><td>"+l[i][3][r]+"</td><td> "+l[i][3][s]+" </td></tr><tr "+n(4)+"><td> "+l[e][4][s]+"</td><td>"+l[e][4][r]+"</td><td> "+(100-A)+"% </td><td>IV</td><td> "+A+"% </td><td>"+l[i][4][r]+"</td><td> "+l[i][4][s]+' </td></tr><tr><td colspan="3">D'+g+" - BH damage:<br>"+comma(o[g][e][0].damage)+'</td><td></td><td colspan="3">D'+g+" - BH damage:<br>"+comma(o[g][i][0].damage)+"</td></tr></table>"),t.find(".tank_img").tipsy({gravity:"s",html:!0})})})}function MercenaryCountForBT(){GM_xmlhttpRequest({method:"GET",url:"http://www.erepublik.com/"+LANG+"/citizen/profile/"+eRS.citizenId,onload:function(t){var e,i,a,n=t.responseText.replace(/src=/g,"tmpsrc=").replace(/\.css/g,"").replace(/\.js/g,"").replace(/url\(/g,""),o=$(n).find("#achievment li ul.country_list li")
for(e=0;e<o.length;e++)img_country[$("img",o[e]).attr("tmpsrc").split("/")[6].split(".")[0]].mercenary=parseInt($(o[e]).find("em").text().split("/")[0])
i="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABYAAAAeCAMAAAAfOR5kAAAA6lBMVEUAAAAAAAAAAABFMwDUpQANBwC8jQB5XQCQbgDTpgAzJADSqAAEAwDHlgAkHAC+lAAAAADDkwDJmwDaqwDPpgC8kgAAAAAAAADLoABnTwCoggARDQAJBQDjrwBXPwAcFAAMCQCBYQAHBgAAAACcdADRpQDOowBrVQAyIgB+XADLowC5kABhRwBwVQAAAACgegAIBgC8jwBUPwAwJQBkTACfegA+LgAwIwBhSgC2jgCNYwDClQBBMgBZRQAZEABGMQCPawAAAQEdFQBUQwB0WQBQPwAyJwAAAABUPwAhGQBAMAB6WACxggARDQD1+GToAAAAR3RSTlMAfesGOiEUAwFHC46eKBQcvCEvPn0Jk9xjT1I1XjMnkG2tiNBBUVxoQoBziIIyxI9HlHOEmHBumKx0iLDE6utjmfjLy8uS6N99TFMAAAFcSURBVCjPrdHZcoIwFAZgkEASFpFVVhFw17rv1e5t0Lbv/zoFdRTa2+bizORLzj8nE+q/FscVtgo8a7PIknNyZLclDlEURGlBSqNdu5yzgwVQ7KnjSDLuPvLXPn75pLcw8PVw3YH5vF4LYwB6/QGTU6ZvyEoTAwjv7BzfbSgO+1jFBrNEN7YxaGk+QJTRDfgbNzSgypplQSc55FhuYg1iQZD7h+AWYoCJrkuCIEwSslXgRTnV6vYEXbj/+iTe1lfPXlO1edmwUjx+j1FnITXKGbvzsJMNmbzu0rfA2Wh1YsoLmKwpbE+zdvaBPWejdMfwtXAwLfPpHLnnu+LH+9t+d1wDVPgga5LsN6PjSIZ5HkezYFZfHV5oNs9shZA4TgsNCyyWiBjRpFr/wyUzY/SbiUgTUs+NV2bdaEiqEf1ciofeNcY1zUoaUqmQtND89bZHm1USi2a1NKTH2e0f9K0lHsHnrIgAAAAASUVORK5CYII=",a=' style="background:#ffffff;border-radius:5px;padding:0 5px"',$("#defender_allies").after('<div class="eRSMerscBT"'+a+'><img src="'+i+'"><strong>'+img_country[$(".country.left_side img:eq(0)").attr("src").split("/")[6].split(".")[0]].mercenary+"</strong></div>"),$("#attacker_allies").after("<div"+a+'><img src="'+i+'"><strong>'+img_country[$(".country.right_side img:eq(0)").attr("src").split("/")[6].split(".")[0]].mercenary+"</strong></div>")}})}function MercenaryBTUpdate(){var t=parseInt($(".eRSMerscBT strong").text())
25>t&&(t+=1),$(".eRSMerscBT strong").text(t)}function GetMercenaryCountForCampaignsPage(){GM_addStyle(".battle_mercenary{cursor:default;width:33px;text-align:center;float:right;margin:14px 2px 10px 0;background:#E0EDD4;padding:3px 2px;border-radius:5px;font-weight:bold;font-size:11px;color:#5A8931}.cod_mercenary{background:#F5DF99;color:#8A560C}.battle_mercenary span{padding:0 1px}.battle_mercenary .merc{color:#DD0000}.battle_mercenary .half{color:#FF6600}.influence_multiplier{margin:6px -2px 0 -2px!important}.isEpicBattle{margin-left:3px!important;margin-right:-2px!important}"),GM_xmlhttpRequest({method:"GET",url:"http://www.erepublik.com/"+LANG+"/citizen/profile/"+eRS.citizenId,onload:function(t){var e,i=t.responseText.replace(/src=/g,"tmpsrc=").replace(/\.css/g,"").replace(/\.js/g,"").replace(/url\(/g,""),a=$("#achievment li ul.country_list li",i)
for(e=0;e<a.length;e++)img_country[$("img",a[e]).attr("tmpsrc").split("/")[6].split(".")[0]].mercenary=parseInt($("em",a[e]).text().split("/")[0])
$(".bod_listing li,.country_battles li,.allies_battles li,.all_battles li").each(function(){var t,e,i,a,n="battle_mercenary"
$(this).parent().hasClass("bod_listing")&&(n+=" cod_mercenary"),t=img_country[$("img.side_flags",this).eq(0).attr("src").split("/")[6].split(".")[0]].mercenary,e="merc",25==t&&(e=""),t>0&&25>t&&(e="half"),i=img_country[$("img.side_flags",this).eq(1).attr("src").split("/")[6].split(".")[0]].mercenary,a="merc",25==i&&(a=""),i>0&&25>i&&(a="half"),$("a.fight_button",this).after('<div class="'+n+'" title="Mercenary Medal kills for each side"><span class="'+e+'">'+t+'</span><span>-</span><span class="'+a+'">'+i+"</span></div>"),$(".battle_mercenary",this).tipsy({gravity:"s"})})}})}function CampaignRWQuickLinks(){GM_addStyle(".RWQuickLink:hover{opacity:0.8}.RWQuickLink:active{position:relative;top:1px}.county{margin:12px 0 0 3px!important}.county span{padding:3px 3px 0 3px!important}"),$("#battle_listing li").each(function(){var t,e,i,a,n
$("img.resistance_sign",this).length>0&&!$(this).parent().hasClass("victory_listing")&&(t=$(this).attr("id").split("-")[1],e=$("img.side_flags",this).eq(0).attr("alt"),i=$("img.side_flags",this).eq(1).attr("alt"),a=$("strong",this).eq(0).children().clone(),n=$("strong",this).eq(1).children().clone(),$("strong",this).eq(0).html('<a href="http://www.erepublik.com/'+LANG+"/military/battlefield-choose-side/"+t+"/"+img_country[$("img.side_flags",this).eq(0).attr("src").split("/")[6].split(".")[0]].id+'" class="RWQuickLink" original-title="Fight for '+e+'">'+e+"</a>").append(a),$("strong",this).eq(1).html('<a href="http://www.erepublik.com/'+LANG+"/military/battlefield-choose-side/"+t+"/"+img_country[$("img.side_flags",this).eq(1).attr("src").split("/")[6].split(".")[0]].id+'" class="RWQuickLink" original-title="Fight for '+i+'">'+i+"</a>").append(n),$(".RWQuickLink",this).css("cssText","float:left;color:white;height:auto;padding:2px 3px;border-radius:10px;margin:-1px -2px 0 0"),$(this).parent().hasClass("bod_listing")?$(".RWQuickLink",this).css("background","linear-gradient(#B83A04,#EB4C06)"):$(".RWQuickLink",this).css("background","linear-gradient(#578732,#71B043)"),$(".RWQuickLink",this).tipsy({gravity:"s"}))})}function MarketplaceAutofill(){$("a.buyOffer").each(function(){var t=$(this).attr("data-max"),e=$(this).attr("data-price"),i=unsafeWindow.erepublik.citizen.currencyAmount-1
t*e>i&&(t=Math.floor(i/e)),$(this).parent().parent().find("input").val(t),$("span",this).text($(this).attr("data-i18n")+" "+comma(Math.ceil(t*e*100)/100)+" "+unsafeWindow.erepublik.citizen.currency)})}var currentTP,nextTP,doneTP,startTP,i,img_country,img_rank,defaultoptions,eRS,options,LANG=location.href.split("/")[3].split("?")[0],date=$(".eday strong").text().replace(",","").trim(),Kills=0,Damage=0,Hits=0,frmicon="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADcAAAA3CAMAAACfBSJ0AAABDlBMVEUAAACgaiUdHR4dHR0bHSAqIh0ZGh0pIRkYHB8bGx3dtFAYGx+OTg/bsk+OUBHZsFHasU7ft1oZFhLXrUnNpEcxGgUmFweHSw+FSQ6lXRX30nXcs1DhuVjXrUnlu1z72Hvvxmn41XjowGGyfjbfuGH87qWPZSj75JPtxGS/iT6LYSSmdTKYairQlUSGWR6GRgqeby7xzG49HAD30HPhv2753oqvbyX/3n+3gzrGkELeslr8656VVBLEhjV5UBp5OAHXqVfUolD98atlOApNJgLLmUn42YT++beQSwt+QAa7fS6sfDaiXRfNnk+iaCT/7Ivzy2ry0Xj/9qznxXczEwD655tdKAPnumT/5Ibio07nj0YAAAAAGnRSTlMADxMuTgogA1pAJGRGY4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aHhBEKbTtNcLDf4ct0+HLVDD6ys/zA94Xy9vJke1d24Gwjg44WVHCSzCXQnTaCdKqCj+k9DfxruwHU+hVqoFkY3AAAAABJRU5ErkJggg==",itemicons[3][3]="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB4AAAAeCAMAAAAM7l6QAAAArlBMVEUAAAAAAADM1NPd5OMNDg1GSUjT2dgAAADb4d/U3Nv///9+goFwcnK3urqVl5cAAAB9goHBx8cQERAUFBRgZGTk6ejn6upISkq/ycjp7eyUm5mcnp7b4eHp7+7EzMvT29rZ3t64vbyjqanx9fTN1tXi6ehxc3OyubidoKCLj47L0M/f5OR4e3qprq1gYGD7/v09PT29xsWstLKTmJhYWVhpampKSUk1NDWChYTCw8NWiy11AAAAHHRSTlMAGxwmTHtfEQ1xLkAqyslZyaWEK3O2kbY82/GbpE0NxQAAAPhJREFUKM/d0MdywkAMBmA6mNBD+mq7t7h3m/d/sfhgxpkYcg//TfONNJJGDxZn8geuXuFjdVcXVICIp7dx+gJBKLyQrm/NdXwX3KhoGMB6gAuKfF/gotQxxPT5F0rUxneVF0eNwJX90T9xJCHMa51SARc/r/h2c8X3oySS8VAiipALsReVl91s3DViLHGYZ2mKEUGuIKoybD7uTpEqp3kT8JQxjlsMkoB99Xuddcozy3UWagJY1RE/bkZ9lnOPM1cbjUAXdWS2Tx30HlQYiE0SZXY99q5sVtaFNYdZWw79rJLS2LcOh376PJz2yyFcfd994Z6P/le+AVfqHpdJcaExAAAAAElFTkSuQmCC",itemicons[3][4]="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB4AAAAeCAMAAAAM7l6QAAAAk1BMVEUAAAB+hIOwurfc4d+gp6bl6emanp4ZGRnS2dhHR0e3vbzo6+u9xcPW2tm8w8IAAAB7gYDJz87Z3d2Xn57c4eHS2to0NjWPmpikr63q7u3R1dXa39/L0M/AxsXh5eWosK62vLvm6+rk6OjDyMi5wcCwt7aiqKft8vH0+PeIiopbW1uamZmAgoOPl5b///90en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VTsoXIEgZwZ8mpi6VYAAAAASUVORK5CYII=",$=jQuery=jQuery.noConflict(!0),$j=unsafeWindow.jQuery,jQuery.fn.tipsy=unsafeWindow.jQuery.fn.tipsy,img_country={Romania:{id:1},Brazil:{id:9},Italy:{id:10},France:{id:11},Germany:{id:12},Hungary:{id:13},China:{id:14},Spain:{id:15},Canada:{id:23},USA:{id:24},Mexico:{id:26},Argentina:{id:27},Venezuela:{id:28},"United-Kingdom":{id:29},Switzerland:{id:30},Netherlands:{id:31},Belgium:{id:32},Austria:{id:33},"Czech-Republic":{id:34},Poland:{id:35},Slovakia:{id:36},Norway:{id:37},Sweden:{id:38},Finland:{id:39},Ukraine:{id:40},Russia:{id:41},Bulgaria:{id:42},Turkey:{id:43},Greece:{id:44},Japan:{id:45},"South-Korea":{id:47},India:{id:48},Indonesia:{id:49},Australia:{id:50},"South-Africa":{id:51},"Republic-of-Moldova":{id:52},Portugal:{id:53},Ireland:{id:54},Denmark:{id:55},Iran:{id:56},Pakistan:{id:57},Israel:{id:58},Thailand:{id:59},Slovenia:{id:61},Croatia:{id:63},Chile:{id:64},Serbia:{id:65},Malaysia:{id:66},Philippines:{id:67},Singapore:{id:68},"Bosnia-Herzegovina":{id:69},Estonia:{id:70},Latvia:{id:71},Lithuania:{id:72},"North-Korea":{id:73},Uruguay:{id:74},Paraguay:{id:75},Bolivia:{id:76},Peru:{id:77},Colombia:{id:78},"Republic-of-Macedonia-FYROM":{id:79},Montenegro:{id:80},"Republic-of-China-Taiwan":{id:81},Cyprus:{id:82},Belarus:{id:83},"New-Zealand":{id:84},"Saudi-Arabia":{id:164},Egypt:{id:165},"United-Arab-Emirates":{id:166},Albania:{id:167}},img_rank={recruit_0:1,private_0:2,private_1:3,private_2:4,private_3:5,corporal_0:6,corporal_1:7,corporal_2:8,corporal_3:9,sergeant_0:10,sergeant_1:11,sergeant_2:12,sergeant_3:13,lieutenant_0:14,lieutenant_1:15,lieutenant_2:16,lieutenant_3:17,captain_0:18,captain_1:19,captain_2:20,captain_3:21,major_0:22,major_1:23,major_2:24,major_3:25,commander_0:26,commander_1:27,commander_2:28,commander_3:29,lt_colonel_0:30,lt_colonel_1:31,lt_colonel_2:32,lt_colonel_3:33,colonel_0:34,colonel_1:35,colonel_2:36,colonel_3:37,general_0:38,general_1:39,general_2:40,general_3:41,field_marshal_0:42,field_marshal_1:43,field_marshal_2:44,field_marshal_3:45,supreme_marshal_0:46,supreme_marshal_1:47,supreme_marshal_2:48,supreme_marshal_3:49,national_force_0:50,national_force_1:51,national_force_2:52,national_force_3:53,world_class_force_0:54,world_class_force_1:55,world_class_force_2:56,world_class_force_3:57,legendary_force_0:58,legendary_force_1:59,legendary_force_2:60,legendary_force_3:61,god_of_war_0:62,god_of_war_1:63,god_of_war_2:64,god_of_war_3:65,titan_0:66,titan_1:67,titan_2:68,titan_3:69},defaultoptions={improveProfilePage:!0,InfluenceCalculator:!0,improveBattlefield:!0,autoEnergyRecover:!0,LvlupNoRecovery:!0,companyManager:!1,XPLeft:!0,removeExternalLinkWarn:!0,preventSidebarScroll:!1,improveInventory:!0,improveExchangeMarket:!0,noKillsDamage:!0,TPmedal:!0,mercenaryPoints:!0,CampaignRWQuickLinks:!0,campaignPoints:!0,CampaignRefresh:!1,showNE:!0,maxEnergy:!0,showStorageInv:!0,AllStock:2,showDonate:!1,rememberDonation:!1,newNews:!1,betterIgm:!1,autoBot:!1,CalculateHits:!0,CalculateHitsQ0:!0,CalculateHitsQ1:!0,CalculateHitsQ2:!0,CalculateHitsQ3:!0,CalculateHitsQ4:!0,CalculateHitsQ5:!0,CalculateHitsQ6:!0,CalculateHitsQ7:!0,quickMarket:!0,reShout:!1,filterGuerrilla:!1,filterMedals:!1,fireSelected:!0,changeSalaryAll:!0,showPriceCompare:!1,sortWages:!0,mercBT:!1,findOffer:!1,showRec:!1,improveMessages:!1,showProfitability:!0,cheaperPack:!1,getItemPrice:!0,boostBattle:!1,storageCapacity:!0,doQuickAccess:!0,MarketplaceAutofill:!0,WrongSideNotice:!0},eRS={citizenId:$("#large_sidebar .user_section .user_identity .user_name").attr("href").split("/profile/")[1],country:$(".currency_amount p img").attr("src").split("/")[6].split(".")[0]},options={},$(document).ready(function(){var t,e,i,a=GM_getValue(eRS.citizenId+".killsToday"+date),n=GM_getValue(eRS.citizenId+".damageToday"+date),o=GM_getValue(eRS.citizenId+".hitsToday"+date)
Kills="undefined"==typeof a?0:JSON.parse(a),Damage="undefined"==typeof n?0:JSON.parse(n),Hits="undefined"==typeof o?0:JSON.parse(o),t="undefined"==typeof GM_getValue(eRS.citizenId+".eRS_options")?0:GM_getValue(eRS.citizenId+".eRS_options")
for(e in defaultoptions)defaultoptions.hasOwnProperty(e)&&(options[e]="undefined"!=typeof JSON.parse(t)[e]?JSON.parse(t)[e]:defaultoptions[e])
CheckForUpdate(),DrawLogo(),$("#point").remove(),options.autoEnergyRecover&&EnergyRecoverer(),options.XPLeft&&XPLeft(),options.preventSidebarScroll&&PreventScroll(),options.doQuickAccess&&DoQuickAccess(),options.removeExternalLinkWarn&&(4==window.location.href.split("/").length&&(i=new MutationObserver(function(t){t.forEach(function(){RemoveExternalLinkWarn()})}),i.observe(document.querySelector("#wall_master"),{childList:!0,subtree:!0})),RemoveExternalLinkWarn()),options.quickMarket&&QuickMarket(),-1==window.location.href.indexOf("/economy/inventory")&&(options.showStorageInv||options.storageCapacity)&&StorageInventory(),options.noKillsDamage&&ShowKillDamage(),options.maxEnergy&&MaxRecoverEnergy(),4==window.location.href.split("/").length&&((options.reShout||options.filterGuerrilla||options.filterMedals)&&(NewFuncs(),unsafeWindow.filter=!0,0==$("#isGroupFeed").val()?(FilterPost(".wall_post_list ul"),FilterPostBind()):(FilterPost("#wall_master"),FilterPostBind())),options.newNews&&NewsCategories()),window.location.href.indexOf("/article/")>0?(options.showDonate&&donateEverywhere(1),$(".load-more-comments").bind("click",function(){setTimeout(function(){options.showDonate&&donateEverywhere(1),options.removeExternalLinkWarn&&RemoveExternalLinkWarn()},1500)})):window.location.href.indexOf("/military/campaigns")>0?($(".combat_missions,.noborder").remove(),options.CampaignRWQuickLinks&&CampaignRWQuickLinks(),options.showNE&&NaturalEnemy(),options.mercenaryPoints&&GetMercenaryCountForCampaignsPage(),options.campaignPoints&&GetPoints(),options.CampaignRefresh&&setTimeout(function(){location.reload()},12e4)):window.location.href.indexOf("/economy/donate-money/")>0?options.rememberDonation&&(ShowRememberDonate(2),$(".marketbtn").bind("click",function(){RememberDonate(2,$(this))})):window.location.href.indexOf("/economy/donate-items/")>0?options.rememberDonation&&(ShowRememberDonate(1),$(".marketbtn").bind("click",function(){RememberDonate(1,$(this))})):window.location.href.indexOf("/citizen/profile/")>0?(options.improveProfilePage&&(AddLinks(),ShowMercenary()),options.InfluenceCalculator&&InfluenceCalculator(),options.rememberDonation&&ShowRememberDonate(3)):window.location.href.indexOf("/economy/market/")>0?(CustomOffer(),options.showPriceCompare&&ShowPriceCompare(),options.showProfitability&&ShowProfitability(),options.MarketplaceAutofill&&MarketplaceAutofill()):window.location.href.indexOf("/economy/exchange-market/")>0?(options.improveExchangeMarket&&ExchangeMarketButtons(),options.findOffer&&FindMyOffer()):window.location.href.indexOf("/main/pvp")>0?options.noKillsDamage&&getGuerrillaDmg():window.location.href.indexOf("/military/battlefield/")>0?(options.WrongSideNotice&&$(".pvp_location:contains('You will now be fighting against')").remove(),options.boostBattle&&BoosterBattle(),options.mercBT&&MercenaryCountForBT(),options.improveBattlefield&&Battlefield(),options.CalculateHits&&CalculateHits(),options.showNE&&NaturalEnemy(),options.autoBot&&AutoBot(),options.TPmedal&&TP()):window.location.href.indexOf("/economy/myCompanies")>0?options.companyManager&&CompanyManager():window.location.href.indexOf("/economy/manage-employees")>0?(options.fireSelected&&FireEmployers(),options.sortWages&&SortWages(),options.changeSalaryAll&&ChangeSalaryAll()):window.location.href.indexOf("/economy/inventory")>0?(options.boostBattle&&ChekToBuild(),options.improveInventory&&ImproveInventory(),options.cheaperPack&&CheaperPack(),options.getItemPrice&&GetItemPrice()):window.location.href.indexOf("/main/messages-compose")>0?((options.improveMessages||options.showDonate||options.showRec)&&unb(),options.betterIgm&&BetterIgm(),options.showDonate&&donateEverywhere(2)):window.location.href.indexOf("/main/messages-inbox")>0||window.location.href.indexOf("/main/messages-paginated")>0?((options.improveMessages||options.showDonate)&&unb(),options.showRec&&GetRecipients()):window.location.href.indexOf("/main/messages-read")>0?((options.improveMessages||options.showRec)&&(addLock(),unb()),options.showDonate&&donateEverywhere(3)):window.location.href.indexOf("/main/group-list/members")>0&&options.showDonate&&donateEverywhere(5)})