\n ").concat(a.name,"\n ").concat(a.help(Math.max(1,e.perks[a.id])),"\n
\n ").concat(t.reverse().join(""),"\n".concat($("score_panel.upgrades_picked"),"
")+a.join("")}function eI(e,a){if(!e.perks.clairvoyant||e.creative)return"";for(var r="",t=0;t".concat($("score_panel.upcoming_levels"),"
").concat(r,"
")}function eV(e){return e.level}function eZ(e){return -1!==e.bricks.indexOf(e.ballsColor)}function eN(e){if(!e.perks.reach)return -1;for(var a=e.level.size,r=-1,t=-1,n=-1,s=0;s0&&Q(1-a.y/e.gameZoneHeight*1.1+.1,0,1)||0}function eY(e,a){return Math.pow(e.x-a.x,2)+Math.pow(e.y-a.y,2)}function eX(e,a){return Math.sqrt(eY(e,a))}function eJ(e){return!!(e.lastPuckMove&&e.perks.passive_income&&e.lastPuckMove>e.levelTime-250*e.perks.passive_income)}function e$(){try{return parseInt(localStorage.getItem("breakout-3-hs-short")||"0")}catch(e){}return 0}function eQ(e){var a=[],r=[],t=Math.max(-1e3+100*e,0);if(e>20){var n=es.slice(0,Math.floor(e/2)).map(function(e){return e}).filter(function(e){var a;return a=e.id,_||(_=new Set(["extra_levels","extra_life","one_more_choice","instant_upgrade","shunt","slow_down"]),es.forEach(function(e){e.requires&&_.add(e.requires)})),!_.has(a)}).sort(function(a,r){return eo(e+a.id)-eo(e+r.id)}),s=Math.min(3,Math.ceil(e/30));a=n.slice(0,s),r=n.slice(s,s+s)}return{required:a,forbidden:r,minScore:t}}function e0(e,a,r){var t=eQ(e),n=t.required,s=t.forbidden,i=t.minScore,_=function(e){var a,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],t=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[];return(a=Math).max.apply(a,[0].concat(M(e.filter(function(e){return!r.find(function(a){var r;return!(null==e?void 0:null===(r=e.perks)||void 0===r?void 0:r[a.id])})&&!t.find(function(a){var r;return null==e?void 0:null===(r=e.perks)||void 0===r?void 0:r[a.id]})}).map(function(e){return e.score}))))}(a,n,s),o=_&&r?$("unlocks.reached",{reached:_}):"";return _>=i?null:n.length||s.length?{reached:_,minScore:i,text:$("unlocks.minScoreWithPerks",{minScore:i,required:n.map(function(e){return e.name}).join(", "),forbidden:s.map(function(e){return e.name}).join(", ")})+o}:{reached:_,minScore:i,text:$("unlocks.minScore",{minScore:i})+o}}function e1(e,a){return a.perks.transparency?Q(a.perks.transparency*(1-e.y/a.gameZoneHeight*1.2),0,1):0}function e2(e,a){return e.perks.metamorphosis||ef("colorful_coins")||e.perks.hypnosis||e.perks.rainbow?a.color:"#ffd300"}function e4(e){return(e.levelTime?e.perks.corner_shot*e.brickWidth:0)-e.perks.unbounded*e.brickWidth}var e3={};if(e3=y("kqXj6").getBundleURL("lgcGd")+"sw-b71.8f558b6a.js","serviceWorker"in navigator&&window.location.href.endsWith("/index.html?isPWA=true")){var e5=new URL(e3);navigator.serviceWorker.register(e5)}var W=y("5mG9B"),q=y("6QuVk"),e6=document.getElementById("game"),e7=e6.getContext("2d",{alpha:!1}),e8=document.createElement("img");e8.src="data:image/svg+xml;base64,"+btoa(''),e8.onload=function(){return rK.needsRender=!0};var e9=document.createElement("img");e9.onload=function(){return rK.needsRender=!0};var ae=document.createElement("canvas"),aa=document.createElement("canvas"),ar=aa.getContext("2d",{alpha:!1});function at(){return 16*(ef("precise_lighting")?1:2)}function an(e,a,r,t,n,s,i){var _=arguments.length>7&&void 0!==arguments[7]?arguments[7]:1;t=Math.round(t),n=Math.round(n),s=Math.round(s),i=Math.round(i),e.globalAlpha=_,r&&(e.strokeStyle=r,"#FF0000"==r?(e.lineDashOffset=ah(a),e.lineWidth=2,e.setLineDash(ab)):e.lineWidth=1,e.beginPath(),e.moveTo(t,n),e.lineTo(s,i),e.stroke(),"#FF0000"==r&&(e.setLineDash(ag),e.lineWidth=1),e.globalAlpha=1)}var as=document.createElement("canvas"),ai="",a_={};function ao(e,a,r,t,n){var s=arguments.length>5&&void 0!==arguments[5]?arguments[5]:"",i="ball"+a+"_"+r+"_"+s,_=Math.round(r);if(!a_[i]){var o=document.createElement("canvas");o.width=_,o.height=_;var l=o.getContext("2d");l.beginPath(),l.arc(_/2,_/2,Math.round(_/2)-1,0,2*Math.PI),l.fillStyle=a,l.fill(),s&&(l.lineWidth=2,l.strokeStyle=s,l.stroke()),a_[i]=o}e.drawImage(a_[i],Math.round(t-_/2),Math.round(n-_/2))}function al(e,a,r,t,n,s,i){var _=(Math.round(i/Math.PI*64)%32+32)%32,o="coin with halo_"+a+"_"+r+"_"+s+"_"+("#ffd300"===a?_:"whatever");if(!a_[o]){var l=document.createElement("canvas");l.width=r,l.height=r;var u=l.getContext("2d");u.beginPath(),u.arc(r/2,r/2,r/2,0,2*Math.PI),u.fillStyle=a,u.fill(),u.strokeStyle=s,"#FF0000"==s&&(u.lineWidth=2,u.setLineDash(ab)),"transparent"===a&&(u.lineWidth=2),u.stroke(),"#ffd300"===a&&(u.beginPath(),u.arc(r/2,r/2,r/2*.6,0,2*Math.PI),u.fillStyle="rgba(255,255,255,0.5)",u.fill(),u.translate(r/2,r/2),u.rotate(_/16),u.translate(-r/2,-r/2),u.globalCompositeOperation="multiply",ac(u,"$",a,r-2,r/2,r/2+1),ac(u,"$",a,r-2,r/2,r/2+1)),a_[o]=l}e.drawImage(a_[o],Math.round(t-r/2),Math.round(n-r/2))}function au(e,a,r,t,n){var s="fuzzy-circle"+a+"_"+r;null==a||a.startsWith("#");var i=Math.round(3*r);if(!(!i||isNaN(i))){if(!a_[s]){var _=document.createElement("canvas");_.width=i,_.height=i;var o=_.getContext("2d"),l=o.createRadialGradient(i/2,i/2,0,i/2,i/2,i/2);l.addColorStop(0,a),l.addColorStop(.3,a+"88"),l.addColorStop(.6,a+"22"),l.addColorStop(1,"transparent"),o.fillStyle=l,o.fillRect(0,0,i,i),a_[s]=_}e.drawImage(a_[s],Math.round(t-i/2),Math.round(n-i/2))}}function ad(e,a,r,t,n){var s=arguments.length>5&&void 0!==arguments[5]?arguments[5]:0,i=arguments.length>6?arguments[6]:void 0,_=Math.ceil(t-e.brickWidth/2),o=Math.ceil(n-e.brickWidth/2),l=Math.ceil(t+e.brickWidth/2)-1,u=Math.ceil(n+e.brickWidth/2)-1,d=l-_,c=u-o,p="brick"+r+"__"+d+"_"+c+"_"+s+"_"+i+"_";if(!a_[p]){var m,g,b,h,v,k,y=document.createElement("canvas");y.width=d,y.height=c;var f=y.getContext("2d");f.fillStyle=r,f.setLineDash(-1!==s?ab:ag),f.lineDashOffset=s,f.strokeStyle=-1!==s&&"#FF000033"||r,f.lineJoin="round",f.lineWidth=4,m=f,g=2,b=2,h=d-4,v=c-4,k=2,m.beginPath(),m.moveTo(4,2),m.lineTo(g+h-k,b),m.quadraticCurveTo(g+h,b,g+h,b+k),m.lineTo(g+h,b+v-k),m.quadraticCurveTo(g+h,b+v,g+h-k,b+v),m.lineTo(g+k,b+v),m.quadraticCurveTo(g,b+v,g,b+v-k),m.lineTo(g,b+k),m.quadraticCurveTo(g,b,g+k,b),m.closePath(),i||f.fill(),f.stroke(),a_[p]=y}a.drawImage(a_[p],_,o,d,c)}function ac(e,a,r,t,n,s){var i=arguments.length>6&&void 0!==arguments[6]&&arguments[6],_="text"+a+"_"+r+"_"+t+"_"+i;if(!a_[_]){var o=document.createElement("canvas");o.width=t*a.length,o.height=t;var l=o.getContext("2d");l.fillStyle=r,l.textAlign=i?"left":"center",l.textBaseline="middle",l.font=t+"px monospace",l.fillText(a,i?0:o.width/2,o.height/2,o.width),a_[_]=o}e.drawImage(a_[_],i?n:Math.round(n-a_[_].width/2),Math.round(s-a_[_].height/2))}var ap=document.getElementById("score"),am=document.getElementById("menuLabel"),ag=[],ab=[5,5];function ah(e){return ef("basic")?0:Math.floor(e.levelTime%500/500*10)%10}var av=null,ak=!1,W=y("5mG9B"),q=y("6QuVk");function ay(){ef("record")&&(null==o?void 0:o.state)==="recording"&&(null==o||o.pause())}function af(){ef("record")&&o&&(null==o||o.stop(),o=null)}var W=y("5mG9B"),q=y("6QuVk"),aW=0,az=null,aw=document.getElementById("popup"),aS=document.getElementById("close-modale");aS.addEventListener("click",function(e){e.preventDefault(),az&&az()}),aS.title=$("play.close_modale_window_tooltip");var ax=-1;function aB(e){return aM.apply(this,arguments)}function aM(){return(aM=(0,W._)(function(e){var a,r,t,n,s,i,_;return(0,q.__generator)(this,function(o){return a=e.title,t=void 0===(r=e.content)?[]:r,s=void 0===(n=e.allowClose)||n,_=void 0===(i=e.className)?"":i,aq(1),[2,new Promise(function(e){var r,n=function(a){o||(o=!0,Array.prototype.forEach.call(i.querySelectorAll("button:not([disabled])"),function(e){return e.disabled=!0}),document.body.style.minHeight=document.body.scrollHeight+"px",setTimeout(function(){return document.body.style.minHeight=""},0),i.remove(),e(a))};aw.className=_,aS.style.display=s?"":"none";var i=document.createElement("div"),o=!1;if(az=s?function(){n(void 0)}:null,a){var l=document.createElement("h1");l.innerHTML=a,i.appendChild(l)}null==t||t.filter(function(e){return e}).forEach(function(e,a){if(e){if("string"==typeof e){var r,t,s=document.createElement("div");s.innerHTML=e,i.appendChild(s);return}(null===(r=i.lastChild)||void 0===r?void 0:r.nodeName)=="SECTION"?t=i.lastChild:((t=document.createElement("section")).className="actions",i.appendChild(t));var _=e.text,o=e.value,l=e.help,u=e.disabled,d=e.className,c=e.icon,p=e.tooltip,m=document.createElement("button");m.innerHTML="\n".concat(void 0===c?"":c,"\n\n ").concat(e.name,"\n ").concat(e.help(1),"\n
\n".concat(a,"
\n").concat($("gameOver.cumulative_total",{startTs:n,endTs:t}),"
\n "),{icon:eg["icon:new_run"],value:null,text:$("confirmRestart.yes"),help:""},'',i,function(e){if(e.creative)return"";var a="",r="";try{var t=ev.map(function(e,a){var r;return{li:a,l:e,r:null===(r=e0(a,aD,!1))||void 0===r?void 0:r.text}}).filter(function(e){return e.r});e.runStatistics.runTime=Math.round(e.runStatistics.runTime);var n=w({},e.perks);for(var s in n)n[s]||delete n[s];aD.push(S(w({},e.runStatistics),{perks:n,appVersion:em}));var i=t.filter(function(e){var a=e.li;return!e0(a,aD,!0)});i.length&&(a="\n\n\n ").concat(a.name,"\n ").concat(eL(a),"\n
\n".concat($("gameOver.stats_intro",{count:aD.length-1}),"
")+r)}catch(e){console.warn(e)}return a+r}(rK)]}).then(function(){return rY({levelToAvoid:eV(rK).name})})}}function aH(e){return e.creative?""+$("gameOver.creative")+"
":""}var aD=[];try{aD=JSON.parse(localStorage.getItem("breakout_71_runs_history")||"[]").sort(function(e,a){return a.score-e.score}).slice(0,100)}catch(e){}var aF=document.createElement("div");function aI(e){aF.classList="toast visible",aF.innerHTML=e,p&&clearTimeout(p),p=setTimeout(function(){p=void 0,aF.classList="hidden toast"},1500)}function aV(e,a){e.startParams.computer_controlled||(e.puckPosition=a,e.needsRender=!0)}function aZ(e){aN(e);var a,r=1+((null===(a=e.perks)||void 0===a?void 0:a.multiball)||0),t=e.puckWidth/(r+1);e.balls=[],e.ballsColor="#FFFFFF",(e.perks.picky_eater||e.perks.pierce_color)&&(e.ballsColor=function(e){var a,r={};e.forEach(function(e){return r[e]=(r[e]||0)+1});var t=(a=Math).max.apply(a,M(Object.keys(r).map(function(e){return r[e]})));return eR(Object.keys(r).filter(function(e){return r[e]==t}))}(e.bricks.filter(function(e){return e}))||"#FFFFFF");for(var n=0;n".concat($("score_panel.close_to_unlock"),'
\n\n ").concat(i,"\n ").concat(null===(a=t.reason)||void 0===a?void 0:a.text,"\n
\n".concat($("level_up.before_buttons",{score:e.score-e.levelStartScore,catchGain:n,levelSpawnedCoins:e.levelSpawnedCoins,time:Math.round(e.levelTime/1e3),timeGain:t,levelMisses:e.levelMisses,missesGain:i,levelWallBounces:e.levelWallBounces,wallHitsGain:s,compliment:o}),"\n
\n").concat($("level_up.after_buttons",{level:e.currentLevel+1,max:eD(e)}),"
\n").concat(eI(e,e.currentLevel+1),"
\n")].concat(M(_),[eF(e),rv(e),''])}),{allowClose:!1}))];case 2:return"reroll"===(l=u.sent())?(r++,e.rerolls--):(e.perks[l]++,"instant_upgrade"===l&&(r+=2),e.runStatistics.upgrades_picked++),[3,1];case 3:return[2]}})})).apply(this,arguments)}function rS(e,a){return eE(rK,Math.floor(a/rK.brickWidth),Math.floor((e-rK.offsetX)/rK.brickWidth))}function rx(e){if(rK.bricks[e])return e}function rB(e,a,r){var t,n,s;return null!==(s=null!==(n=null!==(t=rx(rS(e-r,a-r)))&&void 0!==t?t:rx(rS(e+r,a-r)))&&void 0!==n?n:rx(rS(e+r,a+r)))&&void 0!==s?s:rx(rS(e-r,a+r))}window.addEventListener("resize",function(){return rz(rK)}),window.addEventListener("fullscreenchange",function(){return rz(rK)}),setInterval(function(){var e=window.innerWidth,a=window.innerHeight;(e!==rK.canvasWidth||a!==rK.canvasHeight)&&rz(rK)},1e3),e6.addEventListener("mouseup",function(e){0===e.button&&(rK.running?rW(!0):(ry(),ef("pointerLock")&&e6.requestPointerLock&&e6.requestPointerLock().then()))}),e6.addEventListener("mousemove",function(e){document.pointerLockElement===e6?aV(rK,rK.puckPosition+e.movementX):aV(rK,e.x)}),e6.addEventListener("touchstart",function(e){var a;e.preventDefault(),(null===(a=e.touches)||void 0===a?void 0:a.length)&&(aV(rK,e.touches[0].pageX),aN(rK),ry())}),e6.addEventListener("touchend",function(e){e.preventDefault(),rW(!0)}),e6.addEventListener("touchcancel",function(e){e.preventDefault(),rW(!0)}),e6.addEventListener("touchmove",function(e){var a;(null===(a=e.touches)||void 0===a?void 0:a.length)&&aV(rK,e.touches[0].pageX)});var rM=0,rq=60;setInterval(function(){rq=rM,rM=0},1e3);var rP=document.getElementById("stats"),rO={},rL=performance.now(),rR="idle";function rG(e){if(rK.startParams.stress){var a=performance.now();rR&&(rO[rR]=(rO[rR]||0)+(a-rL)),rL=a,rR=e}}setInterval(function(){if(!rK.startParams.stress){rP.style.display="none";return}rP.style.display="block";var e=eG(rO);rP.innerHTML="\n\n ").concat(e.name,"
\n ").concat(e.help(1),"\n
\n ").concat(e.name," \n
\n ").concat(er(e.credit||""),"\n\n Made in France by Renan LE CARO. \n Donate\n Discord\n F-Droid\n Google Play\n itch.io \n Gitlab\n Web version\n HackerNews\n Privacy Policy\n Archives\n v.'.concat(em,"\n
")]),allowClose:!0})];case 1:return(a=r.sent())&&(a(),rK.needsRender=!0),[2]}})})).apply(this,arguments)}function rE(){return rA.apply(this,arguments)}function rA(){return(rA=(0,W._)(function(){var e,a,r,t,n,s,i,_,o;return(0,q.__generator)(this,function(l){switch(l.label){case 0:rW(!0),(a=[{disabled:ef("easy"),icon:eg["icon:starting_perks"],text:$("starting_perks.title"),help:$("starting_perks.help"),value:function(){return(0,W._)(function(){return(0,q.__generator)(this,function(e){switch(e.label){case 0:return[4,rl()];case 1:return e.sent(),[2]}})})()}}]).push({icon:eg[null===(e=K.find(function(e){return e.value===J()}))||void 0===e?void 0:e.levelName],text:$("settings.language"),help:$("settings.language_help"),value:function(){return(0,W._)(function(){var e,a;return(0,q.__generator)(this,function(r){switch(r.label){case 0:return[4,aB({title:$("settings.language"),content:[$("settings.language_help")].concat(M(K.map(function(e){return S(w({},e),{icon:eg[e.levelName]})}))),allowClose:!0})];case 1:if(!(a=(e=r.sent())&&e!==J()))return[3,3];return[4,rI(rK)];case 2:a=r.sent(),r.label=3;case 3:return a&&(V("lang",e),Z(),window.location.reload()),[2]}})})()}}),r=!0,t=!1,n=void 0;try{for(s=function(){var e=_.value;ey[e]&&a.push({icon:ef(e)?eg["icon:checkmark_checked"]:eg["icon:checkmark_unchecked"],text:ey[e].name,help:ey[e].help,disabled:ef("basic")&&["extra_bright","contrast","smooth_lighting","precise_lighting"].includes(e)||!1,value:function(){eW(e),rz(rK),rH(),rE()}})},i=Object.keys(ey)[Symbol.iterator]();!(r=(_=i.next()).done);r=!0)s()}catch(e){t=!0,n=e}finally{try{r||null==i.return||i.return()}finally{if(t)throw n}}return a.push({icon:eg["icon:download"],text:$("settings.download_save_file"),help:$("settings.download_save_file_help"),value:function(){return(0,W._)(function(){var e,a;return(0,q.__generator)(this,function(r){return e=rc(),(a=document.createElement("a")).setAttribute("href","data:application/json;base64,"+btoa(JSON.stringify({fileType:"B71-save-file",appVersion:em,signedPayload:e,key:eo("Security by obscurity, but really the game is oss so eh"+e)}))),a.setAttribute("download","b71-save-"+new Date().toISOString().slice(0,19).replace(/[^0-9]+/gi,"-")+".b71"),document.body.appendChild(a),a.click(),setTimeout(function(){return document.body.removeChild(a)},1e3),[2]})})()}}),a.push({icon:eg["icon:upload"],text:$("settings.load_save_file"),help:$("settings.load_save_file_help"),value:function(){return(0,W._)(function(){var e,a;return(0,q.__generator)(this,function(r){if(!document.getElementById("save_file_picker")){var t;(a=document.createElement("input")).setAttribute("type","file"),a.setAttribute("id","save_file_picker"),a.setAttribute("accept",".b71,.json"),a.style.position="absolute",a.style.left="-1000px",a.addEventListener("change",(t=(0,W._)(function(e){var r,t,n,s,i,_,o,l;return(0,q.__generator)(this,function(e){switch(e.label){case 0:if(e.trys.push([0,4,,6]),!(t=a&&(null===(r=a.files)||void 0===r?void 0:r.item(0))))return[3,3];return[4,new Promise(function(e,a){var r=new FileReader;r.onload=function(){var a;e((null===(a=r.result)||void 0===a?void 0:a.toString())||"")},r.onerror=function(){a(r.error)},r.readAsText(t)})];case 1:if(s=(n=JSON.parse(e.sent())).fileType,n.appVersion,i=n.signedPayload,_=n.key,"B71-save-file"!==s)throw Error("Not a B71 save file");if(_!==eo("Security by obscurity, but really the game is oss so eh"+i))throw Error("Key does not match content.");for(var u in o=JSON.parse(i),localStorage.clear(),o)localStorage.setItem(u,o[u]);return[4,aB({title:$("settings.save_file_loaded"),content:[$("settings.save_file_loaded_help"),{text:$("settings.save_file_loaded_ok")}]})];case 2:e.sent(),window.location.reload(),e.label=3;case 3:return[3,6];case 4:return l=e.sent(),[4,aB({title:$("settings.save_file_error"),content:[l.message,{text:$("settings.save_file_loaded_ok")}]})];case 5:return e.sent(),[3,6];case 6:return a.value="",[2]}})}),function(e){return t.apply(this,arguments)})),document.body.appendChild(a)}return null===(e=document.getElementById("save_file_picker"))||void 0===e||e.click(),[2]})})()}}),a.push({icon:eg["icon:coins"],text:$("settings.max_coins",{max:U()}),help:$("settings.max_coins_help"),value:function(){return(0,W._)(function(){return(0,q.__generator)(this,function(e){switch(e.label){case 0:return V("max_coins",(F("max_coins",2)+1)%7),[4,rE()];case 1:return e.sent(),[2]}})})()}}),a.push({icon:eg["icon:reset"],text:$("settings.reset"),help:$("settings.reset_help"),value:function(){return(0,W._)(function(){return(0,q.__generator)(this,function(e){switch(e.label){case 0:return[4,aB({title:$("settings.reset"),content:[$("settings.reset_instruction"),{text:$("settings.reset_confirm"),value:!0},{text:$("settings.reset_cancel"),value:!1}],allowClose:!0})];case 1:return e.sent()&&(localStorage.clear(),window.location.reload()),[2]}})})()}}),a.push({text:$("settings.autoplay"),help:$("settings.autoplay_help"),value:function(){return(0,W._)(function(){return(0,q.__generator)(this,function(e){return rX(!1),[2]})})()}}),a.push({text:$("settings.stress_test"),help:$("settings.stress_test_help"),value:function(){return(0,W._)(function(){return(0,q.__generator)(this,function(e){return rX(!0),[2]})})()}}),[4,aB({title:$("main_menu.settings_title"),content:[$("main_menu.settings_help")].concat(M(a)),allowClose:!0,className:"settings"})];case 1:return(o=l.sent())&&(o(),rK.needsRender=!0),[2]}})})).apply(this,arguments)}function rH(){return rD.apply(this,arguments)}function rD(){return(rD=(0,W._)(function(){var e;return(0,q.__generator)(this,function(a){switch(a.label){case 0:if(a.trys.push([0,10,,11]),!(document.fullscreenEnabled||document.webkitFullscreenEnabled))return[2,!1];if(!(null!==document.fullscreenElement&&!ef("fullscreen")))return[3,5];if(!document.exitFullscreen)return[3,2];return[4,document.exitFullscreen()];case 1:case 3:case 6:case 8:return a.sent(),[2,!0];case 2:if(!document.webkitCancelFullScreen)return[3,4];return[4,document.webkitCancelFullScreen()];case 4:return[3,9];case 5:if(!(ef("fullscreen")&&!document.fullscreenElement))return[3,9];if(!(e=document.documentElement).requestFullscreen)return[3,7];return[4,e.requestFullscreen()];case 7:if(!e.webkitRequestFullscreen)return[3,9];return[4,e.webkitRequestFullscreen()];case 9:return[3,11];case 10:return console.warn(a.sent()),[3,11];case 11:return[2,!1]}})})).apply(this,arguments)}function rF(){return(rF=(0,W._)(function(){var e,a,r,t,n,s;return(0,q.__generator)(this,function(i){switch(i.label){case 0:return e=N(),a=ef("mobile-mode")?"help":"tooltip",r=ek.sort(function(e,a){return e.threshold-a.threshold}).map(function(r){var t=r.name,n=r.id,s=r.threshold,i=r.icon,_=r.help;return z({text:t,disabled:e".concat($("unlocks.intro",{ts:e}),"\n ").concat(r.find(function(e){return e.disabled})?$("unlocks.greyed_out_help"):"","
")].concat(M(r),[$("unlocks.level",{unlocked:n.filter(function(e){return!e.disabled}).length,out_of:n.length})],M(n)),allowClose:!0,className:ef("mobile-mode")?"":"actionsAsGrid"})];case 1:if(!(s=i.sent()))return[3,3];return[4,rI(rK)];case 2:i.sent()&&rY(w({},s)),i.label=3;case 3:return[2]}})})).apply(this,arguments)}function rI(e){return rV.apply(this,arguments)}function rV(){return(rV=(0,W._)(function(e){return(0,q.__generator)(this,function(a){return!e.currentLevel||aW?[2,!0]:(rW(!0),[2,aB({title:$("confirmRestart.title"),content:[$("confirmRestart.text"),{value:!0,text:$("confirmRestart.yes")},{value:!1,text:$("confirmRestart.no")}]})])})})).apply(this,arguments)}var rZ={ArrowLeft:0,ArrowRight:0,Shift:0};function rN(e,a){rZ[e]=a,rK.keyboardPuckSpeed=(rZ.ArrowRight-rZ.ArrowLeft)*(1+2*rZ.Shift)*rK.gameZoneWidth/50}document.addEventListener("keydown",(r=(0,W._)(function(e){return(0,q.__generator)(this,function(a){return"f"!==e.key.toLowerCase()||e.ctrlKey||e.metaKey?e.key in rZ&&rN(e.key,1):(eW("fullscreen"),rH())," "!==e.key||aW||(rK.running?rW(!0):ry(),e.preventDefault()),[2]})}),function(e){return r.apply(this,arguments)}));var rU=new Date;document.addEventListener("keyup",(t=(0,W._)(function(e){var a,r,t,n,s;return(0,q.__generator)(this,function(i){switch(i.label){case 0:if(s=document.querySelector("button:focus"),!(e.key in rZ))return[3,1];return rN(e.key,0),[3,10];case 1:if("ArrowDown"!==e.key||(null==s?void 0:null===(a=s.nextElementSibling)||void 0===a?void 0:a.tagName)!=="BUTTON")return[3,2];return null==s||null===(r=s.nextElementSibling)||void 0===r||r.focus(),[3,10];case 2:if("ArrowUp"!==e.key||(null==s?void 0:null===(t=s.previousElementSibling)||void 0===t?void 0:t.tagName)!=="BUTTON")return[3,3];return null==s||null===(n=s.previousElementSibling)||void 0===n||n.focus(),[3,10];case 3:if(!("Escape"===e.key&&az))return[3,4];return az(),[3,10];case 4:if(!("Escape"===e.key&&rK.running))return[3,5];return rW(!0),[3,10];case 5:if(!("m"===e.key.toLowerCase()&&!aW))return[3,6];return rT().then(),[3,10];case 6:if(!("s"===e.key.toLowerCase()&&!aW))return[3,7];return rb(rK).then(),[3,10];case 7:if(!("r"===e.key.toLowerCase()&&!aW&&rU