{"version":3,"file":"gameIndex.js","sources":["webpack:///gameIndex.js"],"sourcesContent":["(window.webpackJsonp=window.webpackJsonp||[]).push([[6],{BRaT:function(e,t,a){},N8gD:function(e,t,a){\"use strict\";(function(e){a(\"ra74\"),a(\"RsId\");var t=a(\"RpkX\");a(\"x9jI\");Array.from(document.querySelectorAll(\"[data-dataLayer]\")).forEach((function(t){t.addEventListener(\"click\",(function(){var a=t.dataset.datalayer;e.dataLayer.push(JSON.parse(a))}))}));new t.default('a[href*=\"#\"]')}).call(this,a(\"yLpj\"))},RpkX:function(e,t,a){\"use strict\";(function(e){var t,l,n=a(\"cDf5\");\n/*! SmoothScroll v16.1.4 | (c) 2020 Chris Ferdinandi | MIT License | http://github.com/cferdinandi/smooth-scroll */\nt=void 0,l=function(){window.Element&&!Element.prototype.closest&&(Element.prototype.closest=function(e){var t,a=(this.document||this.ownerDocument).querySelectorAll(e),l=this;do{for(t=a.length;--t>=0&&a.item(t)!==l;);}while(t<0&&(l=l.parentElement));return l}),function(){if(\"function\"==typeof window.CustomEvent)return!1;function e(e,t){t=t||{bubbles:!1,cancelable:!1,detail:void 0};var a=document.createEvent(\"CustomEvent\");return a.initCustomEvent(e,t.bubbles,t.cancelable,t.detail),a}e.prototype=window.Event.prototype,window.CustomEvent=e}(),\n/**\n * requestAnimationFrame() polyfill\n * By Erik Möller. Fixes from Paul Irish and Tino Zijdel.\n * @link http://paulirish.com/2011/requestanimationframe-for-smart-animating/\n * @link http://my.opera.com/emoller/blog/2011/12/20/requestanimationframe-for-smart-er-animating\n * @license MIT\n */\nfunction(){for(var e=0,t=[\"ms\",\"moz\",\"webkit\",\"o\"],a=0;a=1&&t<=31||127==t||0===n&&t>=48&&t<=57||1===n&&t>=48&&t<=57&&45===s?\"\\\\\"+t.toString(16)+\" \":t>=128||45===t||95===t||t>=48&&t<=57||t>=65&&t<=90||t>=97&&t<=122?a.charAt(n):\"\\\\\"+a.charAt(n)}return\"#\"+o},l=function(){return Math.max(document.body.scrollHeight,document.documentElement.scrollHeight,document.body.offsetHeight,document.documentElement.offsetHeight,document.body.clientHeight,document.documentElement.clientHeight)},n=function(e){return e?(t=e,parseInt(window.getComputedStyle(t).height,10)+e.offsetTop):0;var t},o=function(e,t,a){0===e&&document.body.focus(),a||(e.focus(),document.activeElement!==e&&(e.setAttribute(\"tabindex\",\"-1\"),e.focus(),e.style.outline=\"none\"),window.scrollTo(0,t))},s=function(e,t,a,l){if(t.emitEvents&&\"function\"==typeof window.CustomEvent){var n=new CustomEvent(e,{bubbles:!0,detail:{anchor:a,toggle:l}});document.dispatchEvent(n)}};return function(m,i){var d,r,g,c,v={cancelScroll:function(e){cancelAnimationFrame(c),c=null,e||s(\"scrollCancel\",d)},animateScroll:function(a,m,i){v.cancelScroll();var r=t(d||e,i||{}),u=\"[object Number]\"===Object.prototype.toString.call(a),p=u||!a.tagName?null:a;if(u||p){var f=window.pageYOffset;r.header&&!g&&(g=document.querySelector(r.header));var h,I,D,y=n(g),_=u?a:function(e,t,a,n){var o=0;if(e.offsetParent)do{o+=e.offsetTop,e=e.offsetParent}while(e);return o=Math.max(o-t-a,0),n&&(o=Math.min(o,l()-window.innerHeight)),o}(p,y,parseInt(\"function\"==typeof r.offset?r.offset(a,m):r.offset,10),r.clip),E=_-f,b=l(),w=0,B=function(e,t){var a=t.speedAsDuration?t.speed:Math.abs(e/1e3*t.speed);return t.durationMax&&a>t.durationMax?t.durationMax:t.durationMin&&a1?1:I),window.scrollTo(0,Math.floor(D)),function(e,t){var l=window.pageYOffset;if(e==t||l==t||(f=b)return v.cancelScroll(!0),o(a,t,u),s(\"scrollStop\",r,a,m),h=null,c=null,!0}(D,_)||(c=window.requestAnimationFrame(L),h=e)};0===window.pageYOffset&&window.scrollTo(0,0),function(e,t,a){t||history.pushState&&a.updateURL&&history.pushState({smoothScroll:JSON.stringify(a),anchor:e.id},document.title,e===document.documentElement?\"#top\":\"#\"+e.id)}(a,u,r),\"matchMedia\"in window&&window.matchMedia(\"(prefers-reduced-motion)\").matches?o(a,Math.floor(_),!1):(s(\"scrollStart\",r,a,m),v.cancelScroll(!0),window.requestAnimationFrame(L))}}},u=function(e){if(!e.defaultPrevented&&!(0!==e.button||e.metaKey||e.ctrlKey||e.shiftKey)&&\"closest\"in e.target&&(r=e.target.closest(m))&&\"a\"===r.tagName.toLowerCase()&&!e.target.closest(d.ignore)&&r.hostname===window.location.hostname&&r.pathname===window.location.pathname&&/#/.test(r.href)){var t,l;try{t=a(decodeURIComponent(r.hash))}catch(e){t=a(r.hash)}if(\"#\"===t){if(!d.topOnEmptyHash)return;l=document.documentElement}else l=document.querySelector(t);(l=l||\"#top\"!==t?l:document.documentElement)&&(e.preventDefault(),function(e){if(history.replaceState&&e.updateURL&&!history.state){var t=window.location.hash;t=t||\"\",history.replaceState({smoothScroll:JSON.stringify(e),anchor:t||window.pageYOffset},document.title,t||window.location.href)}}(d),v.animateScroll(l,r))}},p=function(){if(null!==history.state&&history.state.smoothScroll&&history.state.smoothScroll===JSON.stringify(d)){var e=history.state.anchor;\"string\"==typeof e&&e&&!(e=document.querySelector(a(history.state.anchor)))||v.animateScroll(e,null,{updateURL:!1})}};return v.destroy=function(){d&&(document.removeEventListener(\"click\",u,!1),window.removeEventListener(\"popstate\",p,!1),v.cancelScroll(),d=null,r=null,g=null,c=null)},function(){if(!(\"querySelector\"in document&&\"addEventListener\"in window&&\"requestAnimationFrame\"in window&&\"closest\"in window.Element.prototype))throw\"Smooth Scroll: This browser does not support the required JavaScript methods and browser APIs.\";v.destroy(),d=t(e,i||{}),g=d.header?document.querySelector(d.header):null,document.addEventListener(\"click\",u,!1),d.updateURL&&d.popstate&&window.addEventListener(\"popstate\",p,!1)}(),v}},\"object\"===(\"undefined\"==typeof exports?\"undefined\":a.n(n)()(exports))&&void 0!==e?e.exports=l():\"function\"==typeof define&&a(\"PDX0\")?define(l):(t=t||self).SmoothScroll=l()}).call(this,a(\"3UD+\")(e))},RsId:function(e,t,a){(function(e){var t;(t=e).fn.rwdImageMaps=function(){var e=this;return t(window).resize((function(){e.each((function(){if(void 0!==t(this).attr(\"usemap\")){var e=t(this);t(\"\").on(\"load\",(function(){var a=e.attr(\"width\"),l=e.attr(\"height\");if(!a||!l){var n=new Image;n.src=e.attr(\"src\"),a||(a=n.width),l||(l=n.height)}var o=e.width()/100,s=e.height()/100,m=e.attr(\"usemap\").replace(\"#\",\"\"),i=\"coords\";t('map[name=\"'+m+'\"]').find(\"area\").each((function(){var e=t(this);e.data(i)||e.data(i,e.attr(i));for(var n=e.data(i).split(\",\"),m=new Array(n.length),d=0;dv;v++)if(p=e[v],f=L.style[p],m(p,\"-\")&&(p=r(p)),L.style[p]!==a){if(s||l(n,\"undefined\"))return i(),\"pfx\"!=t||p;try{L.style[p]=n}catch(e){}if(L.style[p]!=f)return i(),\"pfx\"!=t||p}return i(),!1}function c(e,t){return function(){return e.apply(t,arguments)}}function v(e,t,a,n,o){var s=e.charAt(0).toUpperCase()+e.slice(1),m=(e+\" \"+w.join(s+\" \")+s).split(\" \");return l(t,\"string\")||l(t,\"undefined\")?g(m,t,n,o):function(e,t,a){var n;for(var o in e)if(e[o]in t)return!1===a?e[o]:l(n=t[e[o]],\"function\")?c(n,a||t):n;return!1}(m=(e+\" \"+C.join(s+\" \")+s).split(\" \"),t,a)}function u(e,t,l){return v(e,a,a,t,l)}var p=[],f={_version:\"3.3.1\",_config:{classPrefix:\"\",enableClasses:!0,enableJSClass:!0,usePrefixes:!0},_q:[],on:function(e,t){var a=this;setTimeout((function(){t(a[e])}),0)},addTest:function(e,t,a){p.push({name:e,fn:t,options:a})},addAsyncTest:function(e){p.push({name:null,fn:e})}},h=function(){};h.prototype=f,h=new h;var I=[],D=t.documentElement,y=\"svg\"===D.nodeName.toLowerCase(),_=f._config.usePrefixes?\" -webkit- -moz- -o- -ms- \".split(\" \"):[];f._prefixes=_;var E=f.testStyles=s;h.addTest(\"touchevents\",(function(){var a;if(\"ontouchstart\"in e||e.DocumentTouch&&t instanceof DocumentTouch)a=!0;else{var l=[\"@media (\",_.join(\"touch-enabled),(\"),\"heartz\",\")\",\"{#modernizr{top:9px;position:absolute}}\"].join(\"\");E(l,(function(e){a=9===e.offsetTop}))}return a}));var b=\"Moz O ms Webkit\",w=f._config.usePrefixes?b.split(\" \"):[];f._cssomPrefixes=w;var B={elem:o(\"modernizr\")};h._q.push((function(){delete B.elem}));var L={style:B.elem.style};h._q.unshift((function(){delete L.style}));var C=f._config.usePrefixes?b.toLowerCase().split(\" \"):[];f._domPrefixes=C,f.testAllProps=v,f.testAllProps=u,h.addTest(\"flexbox\",u(\"flexBasis\",\"1px\",!0)),function(){var e,t,a,n,o,s;for(var m in p)if(p.hasOwnProperty(m)){if(e=[],(t=p[m]).name&&(e.push(t.name.toLowerCase()),t.options&&t.options.aliases&&t.options.aliases.length))for(a=0;a0,t=document.querySelectorAll(\"script[src='https://platform.twitter.com/widgets.js']\").length>0;if(!e){var a=document.createElement(\"script\");a.src=\"//connect.facebook.net/en_US/sdk.js#xfbml=1&version=v3.1&appId=279555116032660&autoLogAppEvents=1\",document.body.appendChild(a)}if(!t){var l=document.createElement(\"script\");l.src=\"//platform.twitter.com/widgets.js\",document.body.appendChild(l)}}}).call(this,a(\"yLpj\"))},x9jI:function(e,t,a){\"use strict\";(function(e,t){var l=a(\"J4zp\"),n=a.n(l),o=a(\"vDqi\"),s=a.n(o),m=a(\"sYUy\");window.addEventListener(\"DOMContentLoaded\",(function(){var a;document.getElementsByTagName(\"HTML\")[0].setAttribute(\"id\",\"top-of-page\"),m.initialize(e.hl_globals.braze.apiKey,{baseUrl:e.hl_globals.braze.baseUrl,enableLogging:e.hl_globals.enableLogging});var l=document.querySelector(\"#time\"),o=document.querySelector(\"#score\"),i=document.querySelector(\"#levelTitle\");function d(e,t,l,n){var o,s,m,i=Date.now();function d(){o=e-((Date.now()-i)/1e3|0),m=(m=o%60|0)<10?\"0\"+m:m;var d=(s=(s=o/60|0)<10?\"0\"+s:s).toString().split(\"\"),r=m.toString().split(\"\"),g=(d=''+d[0]+''+d[1]+\"\")+\":\"+(r=''+r[0]+''+r[1]+\"\");t.innerHTML=g,m<11&&\"00\"===s&&(10===m&&gsap.fromTo(\"#timer--tenth-second\",{scale:3},{scale:1,duration:.5,ease:\"Power4.out\"}),gsap.fromTo(\"#timer--single-second\",{scale:3},{scale:1,duration:.5,ease:\"Power4.out\"})),o<=0&&(i=Date.now()+1e3,clearInterval(a),function(e,t){var a=gsap.timeline(),l=document.getElementById(e+\"__modal--out-of-time--\"+t);l.classList.contains(\"show\")?a.to(l,{autoAlpha:1,duration:.5,ease:\"Power4.out\"}):a.to(l,{autoAlpha:1,duration:.5,ease:\"Power4.out\",onStart:f,onStartParams:[l]})}(l,n))}d(),a=setInterval(d,1e3),document.getElementById(\"game-header__container\").classList.add(\"active-game\")}function r(e,t,a){e.innerHTML=''+a+\" / \"+t,gsap.fromTo(\"#total-hotspots--clicked\",{scale:2.25},{scale:1,duration:.35,ease:\"Power4.out\"})}function g(e,t,a){var l,o;isNaN(t)&&(t=1);var i=\"level-\"+(parseInt(a)+1);l=gameData.games[0].levels[a].levelHotspotValue?e*gameData.games[0].levels[a].levelHotspotValue:e*gameData.games[0].gameHotspotValue,o=gameData.games[0].levels[0].levelRemainingTimeValue?t*gameData.games[0].levels[a].levelRemainingTimeValue:t*gameData.games[0].gameRemainingTimeValue;var d=document.getElementsByClassName(\"user-score--\"+gameData.games[0].gameId),r=l+o,g=[];if(c(\"gameLevelScores--\"+gameData.games[0].gameId)){g=JSON.parse(c(\"gameLevelScores--\"+gameData.games[0].gameId));var u=0;Array.from(g).forEach((function(e,t){g[t][i]=r,v(\"gameLevelScores--\"+gameData.games[0].gameId,JSON.stringify(g));for(var l=t,o=0,s=Object.entries(Object.entries(g[l]));oTurn your phone to play.\",gameData.games[0].gameAgeGate){p(X,\"div\",{id:\"game-intro__consent-row\",class:\"row mb-4 landscape-only\"});var ae=document.getElementById(\"game-intro__consent-row\");p(ae,\"div\",{class:\"col-12\"}),p(ae.firstChild,\"label\",{id:gameData.games[0].gameId+\"--consent-label\"});var le=document.getElementById(gameData.games[0].gameId+\"--consent-label\");/<\\/?[a-z][\\s\\S]*>/i.test(gameData.games[0].gameAgeGateMessage)?p(le,\"input\",{type:\"checkbox\",name:\"checkbox\",class:\"d-inline-block v-align--middle\",id:gameData.games[0].gameId+\"--consent-checkbox\",value:t(gameData.games[0].gameAgeGateMessage).text()}):p(le,\"input\",{type:\"checkbox\",name:\"checkbox\",class:\"d-inline-block v-align--middle\",id:gameData.games[0].gameId+\"--consent-checkbox\",value:gameData.games[0].gameAgeGateMessage}),p(le,\"p\",{class:\"consent-copy d-inline-block v-align--middle mb-0 ml-2\",id:gameData.games[0].gameId+\"--consent-msg\"}),document.getElementById(gameData.games[0].gameId+\"--consent-msg\").innerHTML=gameData.games[0].gameAgeGateMessage}p(X,\"div\",{id:\"game-intro__link-row\",class:\"row\"}),p(\"game-intro__link-row\",\"div\",{id:\"game-intro__link-col\",class:\"col-12 landscape-only\"}),p(\"game-intro__link-col\",\"a\",{id:\"game-intro__link--game\",class:\"btn btn-game-primary text-uppercase mx-auto\",href:\"#\"}),document.getElementById(\"game-intro__link--game\").innerHTML=gameData.games[0].introBtnCopy,gameData.games[0].introVideoURL&&(p(ee,\"div\",{id:\"game-intro__video-container\",class:\"videoWrapper game-intro__video-container d-none\"}),p(\"game-intro__video-container\",\"a\",{id:\"game-intro__video-container--close\",href:\"javascript:void(0);\",class:\"game-intro__video-container--close\"}),document.getElementById(\"game-intro__video-container--close\").innerHTML=\"Skip\",p(\"game-intro__video-container\",\"iframe\",{id:\"player\",class:\"xy-center position-absolute\",width:\"560\",height:\"349\",src:gameData.games[0].introVideoURL})),K=document.getElementById(\"game-intro__video-container\"),gameData.games[0].gameHowToPlayAnimationBool?(p($.firstChild,\"div\",{id:\"game-intro__instructions-content\",class:\"row justify-content-center d-none\"}),p(Y=document.getElementById(\"game-intro__instructions-content\"),\"div\",{id:\"game-intro__instructions-content-container\",class:\"col-12 game-intro__instructions-content-container\"}),p(Q=document.getElementById(\"game-intro__instructions-content-container\"),\"div\",{class:\"row\"}),p(Q.firstChild,\"div\",{id:\"game-intro__instructions-img-container\",class:\"col-12 game-intro__instructions-img-container\"}),p(document.getElementById(\"game-intro__instructions-img-container\"),\"img\",{id:gameData.games[0].gameId+\"--HowToPlayAnimationImg\",class:\"game-intro__instructions-img mx-auto\",src:gameData.games[0].gameHowToPlayAnimationImage}),p(Q.firstChild,\"div\",{id:\"game-intro__instructions-copy-container\",class:\"col-12 game-intro__instructions-copy-container\"}),p(document.getElementById(\"game-intro__instructions-copy-container\"),\"p\",{id:\"game-intro__instructions-copy\",class:\"text-white game-intro__instructions-copy text-center mt-4 mb-2 mb-md-4\"}),document.getElementById(\"game-intro__instructions-copy\").innerHTML=gameData.games[0].gameHowToPlayAnimationCopy):(p($.firstChild,\"div\",{id:\"game-intro__instructions-content\",class:\"row justify-content-center game-intro__instructions-container d-none\"}),p(Y=document.getElementById(\"game-intro__instructions-content\"),\"div\",{id:\"game-intro__instructions-content-container\",class:\"col-10 game-intro__instructions-content-container\"}),p(Q=document.getElementById(\"game-intro__instructions-content-container\"),\"div\",{id:\"game-intro__instructions-title-container\",class:\"col-12 game-intro__instructions-title-container\"}),gameIntroInstructionTitleContainer=document.getElementById(\"game-intro__instructions-title-container\"),p(gameIntroInstructionTitleContainer,\"h1\",{id:\"game-intro__instructions-title\",class:\"game-intro__instructions-title text-uppercase mb-1 mb-md-4\"}),document.getElementById(\"game-intro__instructions-title\").innerHTML=gameData.games[0].instructionsTitle,p(Q,\"div\",{id:\"game-intro__instructions-copy-container\",class:\"col-12 game-intro__instructions-copy-container\"}),p(document.getElementById(\"game-intro__instructions-copy-container\"),\"p\",{id:\"game-intro__instructions-copy\",class:\"game-intro__instructions-copy text-center mb-2 mb-md-4\"}),document.getElementById(\"game-intro__instructions-copy\").innerHTML=gameData.games[0].instructionsCopy,p(Q,\"div\",{id:\"game-intro__instructions-link-container\",class:\"col-12 game-intro__instructions-link-container\"}),gameIntroInstructionLinkContainer=document.getElementById(\"game-intro__instructions-link-container\"),p(gameIntroInstructionLinkContainer,\"a\",{id:\"game-intro__instructions-link\",class:\"btn btn-game-primary text-uppercase\",href:\"#\"}),document.getElementById(\"game-intro__instructions-link\").innerHTML=gameData.games[0].instructionsBtnCopy),p($.firstChild,\"div\",{id:\"game-menu__container\",class:\"row game-menu__container d-none\"}),p(b=document.getElementById(\"game-menu__container\"),\"div\",{id:\"menu-container__title-container\",class:\"menu-container__title-container\"}),p(\"menu-container__title-container\",\"h2\",{id:\"menu-container__title\",class:\"text-uppercase text-center menu-container__title\"}),document.getElementById(\"menu-container__title\").innerHTML=gameData.games[0].menuTitle,p(b,\"div\",{id:\"menu-container__copy-container\",class:\"menu-container__copy-container\"}),p(\"menu-container__copy-container\",\"p\",{id:\"menu-container__copy\",class:\"text-center mb-3 mb-lg-5 menu-container__copy\"}),document.getElementById(\"menu-container__copy\").innerHTML=gameData.games[0].menuCopy,p(b,\"div\",{id:\"menu-container__menu-container-inner\",class:\"col-12 game-menu\"}),p(w=document.getElementById(\"menu-container__menu-container-inner\"),\"div\",{class:\"row\"});for(var ne=0;ne0&&gameData.games[0].gameForceSequentialLevels)if(\"true\"===gameData.games[0].levels[ne].levelAuthenticationRequired&&-1===document.cookie.indexOf('\"authenticated\":true'))me=document.createElement(\"a\"),p(B,\"div\",{id:\"game-menu__title-container-\"+ne,class:\"game-menu__title-container\"}),p(L=document.getElementById(\"game-menu__title-container-\"+ne),\"h3\",{id:\"game-menu__title-\"+ne,class:\"game-menu__item-title text-center\"}),p(B,\"img\",{class:\"game-menu__item-img w-100\",src:gameData.games[0].levels[ne].levelMenuRestrictedImage}),me.innerHTML=\"Log In or Register To Play\",u(me,{class:\"game-menu__item-link not-authenticated text-white w-100 text-center btn-link\",href:\"javascript:void(0);\",\"data-toggle\":\"auth\",\"data-target\":\"registerModal\",\"data-mode\":\"sign-in\"});else{me=document.createElement(\"a\");var ie=\"d-none\";if(0===ne&&(ie=\"\"),p(B,\"div\",{id:\"game-menu__title-container-\"+ne,class:\"game-menu__title-container\"}),L=document.getElementById(\"game-menu__title-container-\"+ne),c(\"gameLevelsToUnlock--\"+gameData.games[0].gameId).indexOf(gameData.games[0].levels[ne].levelID)<0?(p(L,\"h3\",{id:\"game-menu__title-\"+ne,class:\"game-menu__item-title text-center\"}),p(B,\"img\",{class:\"game-menu__item-img w-100\",src:gameData.games[0].levels[ne].levelMenuRestrictedImage}),me.innerHTML=\"Play more to unlock!\",u(me,{class:\"game-menu__item-link not-authenticated not-unlocked text-white w-100 text-center btn-link\",disabled:!0,levelID:gameData.games[0].levels[ne].levelID})):(p(L,\"h3\",{id:\"game-menu__title-\"+ne,class:\"game-menu__item-title text-center bg-level-active\"}),p(B,\"img\",{class:\"game-menu__item-img w-100\",src:gameData.games[0].levels[ne].levelMenuImage}),me.innerHTML=\"Play Now\",u(me,{class:\"game-menu__item-link w-100 text-center btn btn-game-primary text-uppercase\",href:\"javascript:void(0);\",id:\"game-menu__item-link--\"+gameData.games[0].levels[ne].levelID,levelID:gameData.games[0].levels[ne].levelID})),p(ee,\"div\",{id:\"gameContainer_\"+ne,class:\"gameImg vh-100 hero \"+se+ie,levelID:gameData.games[0].levels[ne].levelID}),p(h=document.getElementById(\"gameContainer_\"+ne),\"map\",{id:\"gameMap_\"+ne,name:\"gameMap_\"+ne}),I=document.getElementById(\"gameMap_\"+ne),p(h,\"img\",{id:\"gameImg_\"+ne,class:\"w-100 vh-100 position-absolute zindex--10\",usemap:\"#gameMap_\"+ne,src:gameData.games[0].levels[ne].backgroundImg}),gameData.games[0].levels[ne].levelImitateBGVideoSrc||gameData.games[0].gameImitateBGVideoSrc){var de=gameData.games[0].levels[ne].levelImitateBGVideoSrc||gameData.games[0].gameImitateBGVideoSrc;p(h,\"video\",{id:\"gameVid_\"+ne,class:\"w-100 vh-100 position-absolute zindex--9 gameVid\",loop:\"true\",playsinline:\"true\"}),p(document.getElementById(\"gameVid_\"+ne),\"source\",{src:de,type:\"video/mp4\"})}gameData.games[0].levels[ne].levelModalCenterContentBool?p(h,\"div\",{id:\"modal-instructions--\"+gameData.games[0].levels[ne].levelID,class:\"modal level-modal fade p-0 text-center\",levelIndex:ne}):p(h,\"div\",{id:\"modal-instructions--\"+gameData.games[0].levels[ne].levelID,class:\"modal level-modal fade p-0\",levelIndex:ne}),p(C=document.getElementById(\"modal-instructions--\"+gameData.games[0].levels[ne].levelID),\"div\",{class:\"container h-100\"}),p(C.firstChild,\"div\",{class:\"row h-100\"}),gameData.games[0].levels[ne].levelModalCenterContentBool?p(C.firstChild.firstChild,\"div\",{id:\"modal-card--\"+gameData.games[0].levels[ne].levelID,class:\"modal-card col-12 h-100 m-auto text-center d-flex justify-content-center align-items-center\",style:\"background-image:url(\"+gameData.games[0].levels[ne].levelModalBgImg+\")\",levelID:gameData.games[0].levels[ne].levelID}):p(C.firstChild.firstChild,\"div\",{id:\"modal-card--\"+gameData.games[0].levels[ne].levelID,class:\"modal-card col-12 h-100 m-auto d-flex justify-content-center align-items-center\",style:\"background-image:url(\"+gameData.games[0].levels[ne].levelModalBgImg+\")\",levelID:gameData.games[0].levels[ne].levelID}),p(document.getElementById(\"modal-card--\"+gameData.games[0].levels[ne].levelID),\"div\",{id:\"modal-card__content--\"+gameData.games[0].levels[ne].levelID,class:\"modal-card__content modal-card__content--\"+gameData.games[0].levels[ne].levelID}),p(x=document.getElementById(\"modal-card__content--\"+gameData.games[0].levels[ne].levelID),\"h2\",{id:\"modal-title--\"+gameData.games[0].levels[ne].levelID,class:\"level-modal-title\"}),document.getElementById(\"modal-title--\"+gameData.games[0].levels[ne].levelID).innerHTML=gameData.games[0].levels[ne].levelIntroTitle,p(x,\"p\",{id:\"modal-copy--\"+gameData.games[0].levels[ne].levelID,class:\"level-modal-copy\"}),document.getElementById(\"modal-copy--\"+gameData.games[0].levels[ne].levelID).innerHTML=gameData.games[0].levels[ne].levelIntroCopy,p(x,\"a\",{id:\"modal-btn--instructions-\"+gameData.games[0].levels[ne].levelID,href:\"#continue\",class:\"game-modal-btn my-3 d-table btn btn-game-primary text-uppercase mx-auto\",parentModal:\"modal-instructions--\"+gameData.games[0].levels[ne].levelID,levelID:gameData.games[0].levels[ne].levelID.substr(-1)}),document.getElementById(\"modal-btn--instructions-\"+gameData.games[0].levels[ne].levelID).innerHTML=gameData.games[0].levels[ne].levelIntroBtn,gameData.games[0].levels[ne].levelModalCenterContentBool?p(h,\"div\",{id:\"modal-level-finished--\"+gameData.games[0].levels[ne].levelID,class:\"modal fade p-0 text-center\",levelIndex:ne}):p(h,\"div\",{id:\"modal-level-finished--\"+gameData.games[0].levels[ne].levelID,class:\"modal fade p-0\",levelIndex:ne}),p(M=document.getElementById(\"modal-level-finished--\"+gameData.games[0].levels[ne].levelID),\"div\",{class:\"container h-100\"}),p(M.firstChild,\"div\",{class:\"row h-100\"}),p(M.firstChild.firstChild,\"div\",{id:\"modal-card--finished-\"+gameData.games[0].levels[ne].levelID,class:\"modal-card h-100 col-12 m-auto d-flex justify-content-center align-items-center\",style:\"background-image:url(\"+gameData.games[0].levels[ne].levelModalFinishedBgImg+\")\"}),T=document.getElementById(\"modal-card--finished-\"+gameData.games[0].levels[ne].levelID),gameData.games[0].levels[ne].levelModalCenterContentBool,p(T,\"div\",{id:\"modal-card-finished__content--\"+gameData.games[0].levels[ne].levelID,class:\"modal-card__content modal-card-finished__content--\"+gameData.games[0].levels[ne].levelID}),p(k=document.getElementById(\"modal-card-finished__content--\"+gameData.games[0].levels[ne].levelID),\"div\",{class:\"row justify-content-center align-items-center\"}),gameData.games[0].levels[ne].winnerModalFeaturedImgBool&&(p(k.firstChild,\"div\",{id:\"modal-card--finished__img--\"+gameData.games[0].levels[ne].levelID,class:\"col-5\"}),p(\"modal-card--finished__img--\"+gameData.games[0].levels[ne].levelID,\"img\",{class:\"modal-card--finished__img mx-auto d-block\",src:gameData.games[0].levels[ne].winnerModalFeaturedImg})),p(k.firstChild,\"div\",{id:\"modal-card--finished-\"+gameData.games[0].levels[ne].levelID+\"-copy\",class:\"modal-card__form\"}),p(S=document.getElementById(\"modal-card--finished-\"+gameData.games[0].levels[ne].levelID+\"-copy\"),\"h2\",{id:\"modal-title--finished-\"+gameData.games[0].levels[ne].levelID,class:\"level-modal-title\"}),O=document.getElementById(\"modal-title--finished-\"+gameData.games[0].levels[ne].levelID),p(S,\"p\",{id:\"modal-copy--finished-\"+gameData.games[0].levels[ne].levelID,class:\"level-modal-copy\"}),F=document.getElementById(\"modal-copy--finished-\"+gameData.games[0].levels[ne].levelID),gameData.games[0].levels[ne].levelModalRemoveFormBool?p(S,\"a\",{id:\"modal-btn--finished-\"+gameData.games[0].levels[ne].levelID,href:\"#keepPlaying\",class:\"btn btn-game-primary text-uppercase btn-keep-playing\",parentModal:\"modal-level-finished--\"+gameData.games[0].levels[ne].levelID}):(c(\"userEnteredContest-\"+gameData.games[0].levels[ne].levelID)||(A=document.getElementById(\"entry-form-\"+gameData.games[0].levels[ne].levelID+\"-widget\"),(H=document.getElementById(\"entry-form-\"+gameData.games[0].levels[ne].levelID))&&(H.classList.remove(\"d-none\"),S.appendChild(A),ne===gameData.games[0].levels.length-1&&(p(H,\"a\",{class:\"btn btn-game-primary btn-submit btn-promo-entry-submit mb-3 mx-auto\",id:\"btn--return-to-menu\"}),document.getElementById(\"btn--return-to-menu\").innerHTML=gameData.games[0].levels[ne].levelFinishEnteredBtn))),p(S,\"a\",{id:\"modal-btn--finished-\"+gameData.games[0].levels[ne].levelID,href:\"#keepPlaying\",class:\"btn btn-game-primary text-uppercase btn-keep-playing d-none\",parentModal:\"modal-level-finished--\"+gameData.games[0].levels[ne].levelID})),gameData.games[0].levels[ne].levelFinishLinkLeaderboardBool&&(p(S,\"a\",{id:\"viewLeaderboard--\"+ne,href:gameData.games[0].levels[ne].viewLeaderboardLinkHREF,class:\"link mt-4 d-table mx-auto text-dark\"}),document.getElementById(\"viewLeaderboard--\"+ne).innerHTML=gameData.games[0].levels[ne].viewLeaderboardLinkText),N=document.getElementById(\"modal-btn--finished-\"+gameData.games[0].levels[ne].levelID),!c(\"userEnteredContest-\"+gameData.games[0].levels[ne].levelID)||gameData.games[0].levels[ne].levelModalRemoveFormBool?(O.innerHTML=gameData.games[0].levels[ne].levelFinishTitle,F.innerHTML=gameData.games[0].levels[ne].levelFinishCopy,N.innerHTML=gameData.games[0].levels[ne].levelFinishBtn):(O.innerHTML=gameData.games[0].levels[ne].levelFinishEnteredTitle,F.innerHTML=gameData.games[0].levels[ne].levelFinishEnteredCopy,N.innerHTML=gameData.games[0].levels[ne].levelFinishEnteredBtn),gameData.games[0].levels[ne].levelModalCenterContentBool?p(h,\"div\",{id:gameData.games[0].gameId+\"__modal--out-of-time--\"+gameData.games[0].levels[ne].levelID,class:\"modal fade p-0 text-center modal--oot\",levelIndex:ne}):p(h,\"div\",{id:gameData.games[0].gameId+\"__modal--out-of-time--\"+gameData.games[0].levels[ne].levelID,class:\"modal fade p-0 modal--oot\",levelIndex:ne}),p(V=document.getElementById(gameData.games[0].gameId+\"__modal--out-of-time--\"+gameData.games[0].levels[ne].levelID),\"div\",{class:\"container h-100\"}),p(V.firstChild,\"div\",{class:\"row h-100\"}),p(V.firstChild.firstChild,\"div\",{id:gameData.games[0].gameId+\"__modal-card--out-of-time--\"+gameData.games[0].levels[ne].levelID,class:\"modal-card h-100 col-12 m-auto d-flex justify-content-center align-items-center\",style:\"background-image:url(\"+gameData.games[0].levels[ne].levelModalOOTBgImg+\")\"}),P=document.getElementById(gameData.games[0].gameId+\"__modal-card--out-of-time--\"+gameData.games[0].levels[ne].levelID),gameData.games[0].levels[ne].levelModalCenterContentBool,p(P,\"div\",{id:gameData.games[0].gameId+\"__modal-content--out-of-time--\"+gameData.games[0].levels[ne].levelID,class:\"col-10 modal-card__content modal-card-finished__content--\"+gameData.games[0].levels[ne].levelID}),p(j=document.getElementById(gameData.games[0].gameId+\"__modal-content--out-of-time--\"+gameData.games[0].levels[ne].levelID),\"div\",{class:\"row justify-content-center align-items-center\"}),p(j.firstChild,\"div\",{id:gameData.games[0].gameId+\"__modal-copy--out-of-time--\"+gameData.games[0].levels[ne].levelID,class:\"col-7 modal-card__form\",levelid:gameData.games[0].levels[ne].levelID,levelindex:ne}),p(q=document.getElementById(gameData.games[0].gameId+\"__modal-copy--out-of-time--\"+gameData.games[0].levels[ne].levelID),\"h2\",{id:gameData.games[0].gameId+\"__modal-title--out-of-time--\"+gameData.games[0].levels[ne].levelID,class:\"level-modal-title\"}),R=document.getElementById(gameData.games[0].gameId+\"__modal-title--out-of-time--\"+gameData.games[0].levels[ne].levelID),p(q,\"p\",{id:gameData.games[0].gameId+\"__modal-text--out-of-time--\"+gameData.games[0].levels[ne].levelID,class:\"level-modal-form-copy\"}),G=document.getElementById(gameData.games[0].gameId+\"__modal-text--out-of-time--\"+gameData.games[0].levels[ne].levelID),p(q,\"a\",{id:gameData.games[0].gameId+\"__modal-btn--out-of-time--\"+gameData.games[0].levels[ne].levelID,href:\"#keepPlaying\",class:\"btn btn-game-primary text-uppercase authenticated-btn\",parentModal:gameData.games[0].gameId+\"__modal--out-of-time--\"+gameData.games[0].levels[ne].levelID}),gameData.games[0].levels[ne].levelFinishLinkLeaderboardBool&&(p(q,\"a\",{id:\"viewLeaderboard--oot--\"+ne,href:gameData.games[0].levels[ne].viewLeaderboardLinkHREF,class:\"link mt-4 d-table mx-auto text-dark\"}),document.getElementById(\"viewLeaderboard--oot--\"+ne).innerHTML=gameData.games[0].levels[ne].viewLeaderboardLinkText),z=document.getElementById(gameData.games[0].gameId+\"__modal-btn--out-of-time--\"+gameData.games[0].levels[ne].levelID),c(\"userEnteredContest-\"+gameData.games[0].levels[ne].levelID)&&!gameData.games[0].levels[ne].levelModalRemoveFormBool||(R.innerHTML=gameData.games[0].levels[ne].levelOOTTitle,G.innerHTML=gameData.games[0].levels[ne].levelOOTCopy,z.innerHTML=gameData.games[0].levels[ne].levelOOTBtn),W=ne;for(var re=0;re0&&re0&&re').appendTo(\".active-level\");for(var v=0;v<4;++v)v%2==0?0===v?t('
').css({left:\"\".concat(c,\"px\"),top:r+5+\"px\"}).append(t('')).appendTo(t(\".hotspot-found__container\")):t('
').css({left:\"\".concat(c,\"px\"),top:Math.min.apply(Math,n)-5+\"px\"}).append(t('')).appendTo(t(\".hotspot-found__container\")):1===v?t('
').css({left:\"\".concat(g,\"px\"),top:r+5+\"px\"}).append(t('')).appendTo(t(\".hotspot-found__container\")):t('
').css({left:\"\".concat(g,\"px\"),top:d-5+\"px\"}).append(t('')).appendTo(t(\".hotspot-found__container\"));var u=document.getElementById(\"hotspot-found__top-left--\"+e),p=document.getElementById(\"hotspot-found__bottom-right--\"+e),f=p.offsetLeft+39-u.offsetLeft,h=p.offsetTop+39-u.offsetTop,I=u.offsetLeft-20,D=u.offsetTop-20;t('
').css({width:\"\".concat(f,\"px\"),height:\"\".concat(h,\"px\"),left:\"\".concat(I,\"px\"),top:\"\".concat(D,\"px\")}).appendTo(t(\"#hotspot-found__container--\"+e)),s.to(\"#hotspot-found__container--\"+e,{autoAlpha:1,duration:.3,ease:\"power4.out\"}).to(\"#hotspot-found__container--\"+e,{autoAlpha:0,delay:1.5,duration:1,ease:\"power4.out\",onComplete:He,onCompleteParams:[e]}),o.fromTo(\".hotspot-found__individual-container--\"+e,{scale:.8},{scale:1.2,duration:.2,ease:\"power4.out\"}).to(\".hotspot-found__individual-container--\"+e,{scale:1,duration:.2,ease:\"power4.out\"}),m.fromTo(\"#hotspot-found__camera-flash--\"+e,{autoAlpha:.5},{autoAlpha:.2,duration:.2,ease:\"power4.out\"}).to(\"#hotspot-found__camera-flash--\"+e,{autoAlpha:.65,duration:.1,ease:\"power4.out\"}).to(\"#hotspot-found__camera-flash--\"+e,{autoAlpha:0,duration:.2,ease:\"power4.out\"})},Fe=function(){t(\"#missedMessage\").remove()},Ne=gsap.timeline(),Ve=gsap.timeline(),Pe=gsap.timeline(),je=gsap.timeline(),qe=(gsap.timeline(),gsap.timeline(),[\"Not quite!\",\"Keep looking!\",\"Almost!\",\"Nope!\",\"Good try!\",\"No dice!\",\"Guess again!\",\"You're close!\",\"Look again!\",\"Nothing doing!\"]),Re=function(){var e=t(\"#levelTitle\").height();Ve.fromTo(\"#missedMessage\",{scale:1},{scale:1.3,duration:.5}).to(\"#missedMessage\",{scale:1,duration:.5}),Ve.fromTo(\"#missedMessage\",{y:0-e/2},{y:100,duration:.6,delay:1,onComplete:Fe}),Ve.paused()&&Ve.play()},Ge=function(e){var a=t(\"#levelMessageContainer\"),l=t(\"#levelTitle\"),n=l.height();(Pe.progress()<1||je.progress()<1)&&(Pe.clear(),je.clear(),ze()),t(\"#missedMessage\").length<=0&&(Ne.fromTo(l,{y:0},{y:100,duration:.6}),t('

'+e+\"

\").appendTo(a),Ne.fromTo(\"#missedMessage\",{y:-100,opacity:1},{y:0-n/2,opacity:1,duration:.6,onComplete:Re}),Ne.fromTo(l,{y:-100},{y:0,duration:1,delay:2.25}),Ne.paused()&&Ne.play())},ze=function(){t(\"#foundMessage\").remove()},Ue=function(){var e=t(\"#levelTitle\").height();je.fromTo(\"#foundMessage\",{scale:1},{scale:1.3,duration:.5}).to(\"#foundMessage\",{scale:1,duration:.5}),je.fromTo(\"#foundMessage\",{y:0-e/2},{y:100,duration:.6,delay:1,onComplete:ze}),je.paused()&&je.play()},Je=function(e){var a=t(\"#levelMessageContainer\"),l=t(\"#levelTitle\"),n=l.height();(Ne.progress()<1||Ve.progress()<1)&&(Ne.clear(),Ve.clear(),Fe()),t(\"#foundMessage\").length<=0&&(Pe.fromTo(l,{y:0},{y:100,duration:.6}),t('

Hoosiers '+e+\"!

\").appendTo(a),Pe.fromTo(\"#foundMessage\",{y:-100,opacity:1},{y:0-n/2,opacity:1,duration:.6,onComplete:Ue}),Pe.fromTo(l,{y:-100},{y:0,duration:1,delay:2.25})),Pe.paused()&&Pe.play()},Ye=function(e,n){var s,m,i=document.getElementsByClassName(\"active-level\")[0],d=n.target.id,u=Array.from(document.getElementById(d).parentNode.children).indexOf(document.getElementById(d));if(gameData.games[0].levels[e].levelEnforceHotspotOrderBool)if(d===ve)if(Te.length+1===ke){Je(document.getElementById(d).alt.toLowerCase()),Oe(d),Ee&&(Ee[0].disable(),t(\".active-level\").off(),gsap.set(i,{x:0,y:\"-\"+t(\".active-level\").css(\"padding-top\")})),c(\"userEnteredContest-\"+gameData.games[0].levels[e].levelID)&&(document.getElementById(\"modal-title--finished-\"+gameData.games[0].levels[e].levelID).innerHTML=gameData.games[0].levels[e].levelFinishEnteredTitle,document.getElementById(\"modal-copy--finished-\"+gameData.games[0].levels[e].levelID).innerHTML=gameData.games[0].levels[e].levelFinishEnteredCopy,document.getElementById(\"modal-btn--finished-\"+gameData.games[0].levels[e].levelID).classList.remove(\"d-none\"),document.getElementById(\"modal-btn--finished-\"+gameData.games[0].levels[e].levelID).innerHTML=gameData.games[0].levels[e].levelFinishEnteredBtn),document.activeElement.blur();var f=document.getElementById(\"modal-btn--finished-\"+he);dataLayer.push({event:gameData.games[0].gameGAID+\" level complete\",eventCategory:\"N/A\",eventAction:\"N/A\",eventLabel:gameData.games[0].gameGAID+\" level complete - \"+gameData.games[0].levels[e].levelID}),f.addEventListener(\"click\",(function(e){e.preventDefault(),Ze(e)})),document.getElementById(\"gameImg_\"+e).src=gameData.games[0].levels[e].backgroundImgWinner,clearInterval(a),l.innerHTML=\"\",setTimeout((function(){if(document.body.classList.contains(\"game-active\")&&(gsap.set(i,{x:0,y:\"-\"+t(\".active-level\").css(\"padding-top\")}),document.getElementById(\"modal-level-finished--\"+he).classList.add(\"show\"),c(\"userContestDetails\"))){var e=c(\"userContestDetails\").split(\",\"),a=e[0],l=e[1],n=e[2],o=e[3],s=document.getElementById(\"firstName-\"+he),m=document.getElementById(\"lastName-\"+he),d=document.getElementById(\"dob-\"+he),r=document.getElementById(\"email-\"+he);s.value=a,m.value=l,d.value=n,r.value=o}}),1500)}else document.getElementById(\"modal--\"+d).classList.add(\"show\"),document.getElementById(\"game-header__container\").classList.add(\"active-modal\");else Te.length!=u&&-1===Te.indexOf(d)?document.getElementById(\"modal__out-of-order--\"+d).classList.add(\"show\"):Te.length===u?(Je(document.getElementById(d).alt.toLowerCase()),Oe(d),Te.push(d)):(Je(document.getElementById(d).alt.toLowerCase()),Oe(d),document.activeElement.blur());else if(Te.length+1!==ke||Te.includes(d))if(Te.includes(d)){var h=qe[Math.floor(Math.random()*qe.length)],I=t(\"#\"+event.target.id).offset().top,D=t(\"#\"+event.target.id).offset().left,y=t('
').css({left:event.pageX-D+\"px\",top:event.pageY-I+\"px\"}).append(t('\"Oops,')).appendTo(t(i));Ge(h),setTimeout((function(){y.addClass(\"fade-out\"),setTimeout((function(){y.remove()}),1e3)}),1e3)}else Je(document.getElementById(d).alt.toLowerCase()),Oe(d),document.activeElement.blur(),Te.push(d),r(o,ke,Te.length);else{Te.push(d),r(o,ke,Te.length),clearInterval(a),Je(document.getElementById(d).alt.toLowerCase()),Oe(d),gameData.games[0].gameForceSequentialLevels&&function(e){var a,l;if(document.querySelectorAll(\"[requiresauthentication=true]\"),document.getElementById(\"playArea\"),(a=t(\"a[levelid=level-\"+(parseInt(e)+2)+\"]\")).length>0){l=a.parent().attr(\"id\");var n=document.getElementById(l).firstChild;document.createElement(\"a\"),t(\"#\"+l).children(\"img\")[0].remove(),a.remove(),n.firstChild.classList.add(\"bg-level-active\");var o=parseInt(e)+1;p(l,\"img\",{class:\"game-menu__item-img w-100\",src:gameData.games[0].levels[o].levelMenuImage}),p(l,\"a\",{class:\"game-menu__item-link w-100 text-center btn btn-game-primary text-uppercase\",href:\"javascript:void(0);\",id:\"game-menu__item-link--\"+gameData.games[0].levels[o].levelID,levelID:gameData.games[0].levels[o].levelID}),document.getElementById(\"game-menu__item-link--\"+gameData.games[0].levels[o].levelID).innerHTML=\"Play Now\",document.getElementById(\"game-menu__item-link--\"+gameData.games[0].levels[o].levelID).addEventListener(\"click\",Qe)}}(e),Ee&&(Ee[0].disable(),t(\".active-level\").off(),gsap.set(i,{x:0,y:\"-\"+t(\".active-level\").css(\"padding-top\")})),c(\"userEnteredContest-\"+gameData.games[0].levels[e].levelID)&&(document.getElementById(\"modal-title--finished-\"+gameData.games[0].levels[e].levelID).innerHTML=gameData.games[0].levels[e].levelFinishEnteredTitle,document.getElementById(\"modal-copy--finished-\"+gameData.games[0].levels[e].levelID).innerHTML=gameData.games[0].levels[e].levelFinishEnteredCopy,document.getElementById(\"modal-btn--finished-\"+gameData.games[0].levels[e].levelID).classList.remove(\"d-none\"),document.getElementById(\"modal-btn--finished-\"+gameData.games[0].levels[e].levelID).innerHTML=gameData.games[0].levels[e].levelFinishEnteredBtn),document.activeElement.blur();var _=document.getElementById(\"modal-btn--finished-\"+he);dataLayer.push({event:gameData.games[0].gameGAID+\" level complete\",eventCategory:\"N/A\",eventAction:\"N/A\",eventLabel:gameData.games[0].gameGAID+\" level complete - \"+gameData.games[0].levels[e].levelID}),_.addEventListener(\"click\",(function(e){e.preventDefault(),Ze(e)})),document.getElementById(\"gameImg_\"+e).src=gameData.games[0].levels[e].backgroundImgWinner,setTimeout((function(){if(document.body.classList.contains(\"game-active\")&&(gsap.set(i,{x:0,y:\"-\"+t(\".active-level\").css(\"padding-top\")}),document.getElementById(\"modal-level-finished--\"+he).classList.add(\"show\"),document.getElementById(\"game-header__container\").classList.contains(\"active-game\")&&document.getElementById(\"game-header__container\").classList.remove(\"active-game\"),document.getElementById(\"game-header__container\").classList.add(\"active-modal\"),c(\"userContestDetails\"))){var e=c(\"userContestDetails\").split(\",\"),a=e[0],l=e[1],n=e[2],o=e[3],s=document.getElementById(\"firstName-\"+he),m=document.getElementById(\"lastName-\"+he),d=document.getElementById(\"dob-\"+he),r=document.getElementById(\"email-\"+he);s.value=a,m.value=l,d.value=n,r.value=o}}),1500),Array.from(i.childNodes[0].children).forEach((function(e,t){e.removeEventListener(\"click\",(function(a){Ye(t,a),e.setAttribute(\"hasClickListener\",!1)}),!1),e.removeEventListener(\"touchstart\",(function(e){}),!1)}));var E=gameData.games[0].levels[e].levelID.match(/\\d/g);if(E=E.join(\"\"),E=parseInt(E)+1,c(\"gameLevelsToUnlock--\"+gameData.games[0].gameId)){var b=c(\"gameLevelsToUnlock--\"+gameData.games[0].gameId);b.indexOf(\"level-\"+E)<0&&v(\"gameLevelsToUnlock--\"+gameData.games[0].gameId,[b,\"level-\"+E])}else v(\"gameLevelsToUnlock--\"+gameData.games[0].gameId,[\"level-\"+E]);g(ke,(s=t(\"#time\").text(),60*+(m=s.split(\":\"))[0]+ +m[1]),e)}},Qe=function(e){ue=document.getElementsByClassName(\"gameImg\"),pe=document.getElementsByClassName(\"gameVid\"),fe=e.target.parentElement.getAttribute(\"levelindex\"),he=e.target.parentElement.getAttribute(\"levelid\"),Ie=document.getElementById(\"modal-instructions--\"+he),De=document.getElementById(\"gameContainer_\"+fe),ye=document.getElementById(\"gameImg_\"+fe),_e=document.getElementById(\"gameVid_\"+fe),e.target.id.indexOf(\"out-of-time\")>0&&Xe(e),e.target.classList.contains(\"not-authenticated\")||(b.classList.contains(\"d-block\")&&b.classList.remove(\"d-block\"),dataLayer.push({event:gameData.games[0].gameGAID+\" level start\",eventCategory:\"N/A\",eventAction:\"N/A\",eventLabel:gameData.games[0].gameGAID+\" level start - \"+he}),m.getUser().addToCustomAttributeArray(gameData.games[0].gameId+\" Level Start\",he),b.classList.add(\"d-none\"),Ce.classList.add(\"game-active\"),Te=[],ke=0,Ie.classList.add(\"show\"),Array.from(pe).forEach((function(e,t){e.paused||e.pause()})),Array.from(ue).forEach((function(e,a){e.id===De.id?(De.classList.contains(\"d-none\")?(ye.src=gameData.games[0].levels[fe].backgroundImg,_e.paused&&_e.play(),De.classList.remove(\"d-none\"),De.classList.add(\"active-level\")):(gameData.games[0].gameLevelVideoBgs?ye.src=gameData.games[0].gamePixelBGsrc:ye.src=gameData.games[0].levels[fe].backgroundImg,_e.paused&&_e.play(),De.classList.add(\"active-level\")),gsap.set(\"#gameContainer_\"+fe,{y:\"-\"+t(\"#gameContainer_\"+fe).css(\"padding-top\")})):(e.classList.contains(\"d-none\")||e.classList.add(\"d-none\"),e.classList.contains(\"active-level\")&&e.classList.remove(\"active-level\"))})))},Xe=function(e){if(e.target.getAttribute(\"parentModal\")){if(document.getElementById(e.target.getAttribute(\"parentModal\")).classList.remove(\"show\"),e.target.id.indexOf(\"out-of-time\")<0&&document.getElementById(\"game-header__container\").classList.remove(\"active-modal\"),e.target.hasAttribute(\"levelID\")){var a=e.target.attributes.levelid.value-1;!function(e,a){var n=document.getElementsByClassName(\"active-level\")[0];Ee=Draggable.create(t(n),{bounds:t(\"#playArea\"),edgeResistance:.65,type:\"x,y\",throwProps:!0,autoScroll:0,inertia:!0,dragClickables:!1});var s=n.id.substr(-1);Ee[0].enable(),t(e).rwdImageMaps(),Array.from(n.childNodes[0].children).forEach((function(e){e.hasAttribute(\"hasClickListener\")||(t(e).on(\"click touchstart\",(function(e){Ye(s,e)})),e.setAttribute(\"hasClickListener\",!0)),ke++,ve=e.id})),t(n).on(\"click touchstart\",(function(e){var a,l;if(\"touchstart\"===e.type){var o=e.originalEvent.touches[0]||e.originalEvent.changedTouches[0];a=o.pageX,l=window.innerHeight<=415?o.pageY+window.innerHeight/10:window.innerHeight<=770?o.pageY+window.innerHeight/15:o.pageY+window.innerHeight/20}else a=e.pageX,l=e.pageY+50;var s=qe[Math.floor(Math.random()*qe.length)];if(\"AREA\"!==e.target.nodeName&&\"A\"!==e.target.nodeName){var m=t(\"#\"+e.target.id).offset().top,i=t(\"#\"+e.target.id).offset().left,d=t('
').css({left:a-i+\"px\",top:l-m+\"px\"}).append(t('\"Oops,')).appendTo(t(n));setTimeout((function(){d.addClass(\"fade-out\"),setTimeout((function(){d.remove()}),1e3)}),1e3),Ge(s)}})),r(o,ke,Te.length),d(gameData.games[0].levels[a].levelTimeLimit,l,gameData.games[0].gameId,gameData.games[0].levels[a].levelID),i.innerHTML=gameData.games[0].levels[a].levelTagline}(t(\"#gameImg_\"+a),a)}}else document.getElementById(\"modal-level-finished--\"+gameData.games[0].levels[fe].levelID).classList.remove(\"show\"),document.getElementById(\"game-header__container\").classList.remove(\"active-modal\")},Ke=function(){Ee&&(gsap.set(\".active-level\",{y:\"-\"+t(\".active-level\").css(\"padding-top\")}),Ee[0].disable(),t(\".active-level\").off(),gsap.set(document.getElementsByClassName(\"active-level\")[0],{y:\"-\"+t(\".active-level\").css(\"padding-top\")})),document.getElementById(\"game\").scrollLeft=0,Ce.classList.remove(\"close-required\");var e=document.getElementsByClassName(\"modal\");if(U.classList.contains(\"d-none\")&&U.classList.remove(\"d-none\"),gameData.games[0].useIntroVideoBool&&!K.classList.contains(\"d-none\")&&(K.classList.add(\"d-none\"),K.classList.remove(\"active\")),Y.classList.contains(\"d-none\")||Y.classList.add(\"d-none\"),b.classList.contains(\"d-none\")||(b.classList.contains(\"d-block\")&&b.classList.remove(\"d-block\"),b.classList.add(\"d-none\")),Array.from(e).forEach((function(e){e.classList.contains(\"show\")&&e.classList.remove(\"show\")})),gameData.games[0].useIntroVideoBool)try{player.pauseVideo()}catch(e){console.log(e.message)}Ae()},We=function(){U.classList.add(\"d-none\"),K.classList.remove(\"d-none\"),setTimeout((function(){K.classList.add(\"active\")}),300),player.playVideo()},$e=function(){if(v(\"gameTotalScore--\"+gameData.games[0].gameId,0),gameData.games[0].useIntroVideoBool)try{player.pauseVideo()}catch(e){console.log(e.message)}if(gameData.games[0].useIntroVideoBool&&!document.getElementById(\"game-intro__video-container\").classList.contains(\"d-none\")&&document.getElementById(\"game-intro__video-container\").classList.add(\"d-none\"),U.classList.contains(\"d-none\")||U.classList.add(\"d-none\"),Ce.classList.add(\"close-required\"),document.getElementById(\"game-header__container\").classList.add(\"active-modal\"),document.getElementById(\"game-intro__instructions-content\").classList.remove(\"d-none\"),gameData.games[0].gameHowToPlayAnimationBool){var e=document.getElementById(gameData.games[0].gameId+\"--HowToPlayAnimationImg\"),t=gsap.timeline({paused:!0});t.fromTo(e,{rotation:\"-40%\"},{rotation:\"40%\",duration:1,ease:\"circ.out\"}).to(e,{rotation:\"-40%\",duration:1,ease:\"circ.out\"}).to(e,{rotation:\"40%\",duration:1,ease:\"circ.out\"}).to(e,{rotation:\"0%\",duration:1,ease:\"circ.out\"}),t.play(),setTimeout((function(){t.pause(),Ce.classList.contains(\"close-required\")&&Ze()}),4e3)}},Ze=function(e){if(document.getElementById(\"game-header__container\").classList.contains(\"active-game\")&&document.getElementById(\"game-header__container\").classList.remove(\"active-game\"),document.getElementById(\"game-header__container\").classList.contains(\"active-modal\")||document.getElementById(\"game-header__container\").classList.add(\"active-modal\"),he&&document.getElementById(\"modal-level-finished--\"+he).classList.contains(\"show\")){if(e.target.previousElementSibling.classList.contains(\"promotion-entry-widget\")){var t=e.target.previousElementSibling.lastElementChild.previousElementSibling.lastElementChild;null!=t&&t.click()}clearInterval(a),l.innerHTML=\"\",Xe(e),document.getElementById(\"game\").scrollLeft=0,Ae()}Y.classList.add(\"d-none\"),b.classList.contains(\"d-block\")||b.classList.add(\"d-block\"),b.classList.remove(\"d-none\")},et=document.getElementById(\"game-intro__link--game\"),tt=(document.getElementById(\"game-form__init-intro--game\"),document.getElementById(\"game-intro__instructions-link\")),at=document.getElementById(\"game-intro__video-container--close\"),lt=document.getElementById(\"reset-game-btn\"),nt=function(e){e.parentNode.remove()},ot=c(\"userEnteredContest-form-1--landing\"),st=c(\"userEnteredContest-\"+xe),mt=document.getElementById(\"etw-form\"),it=document.getElementById(gameData.games[0].gameId+\"--consent-checkbox\");(ot||st)&&(mt.classList.add(\"user-entered-contest\"),document.getElementById(\"entry-form-form-1--landing\").parentElement.remove(),document.getElementById(\"promotion-form__intro-title\").innerHTML=gameData.games[0].finishGameTitle,document.getElementById(\"promotion-form__intro-copy\").innerHTML=gameData.games[0].finishGameMessage,p(\"promotion-form__intro\",\"button\",{class:\"btn btn-game-primary btn-submit my-4 mx-auto d-block\",id:\"game-form__init-lp-intro--game\"}),p(\"promotion-form__intro\",\"div\",{id:\"social-share-container\"}),loadSocialScripts(),document.getElementById(\"social-share-container\").innerHTML='',document.getElementById(\"game-form__init-lp-intro--game\").innerHTML=\"Keep Playing\"),et.classList.add(\"dom-loaded\"),gameData.games[0].useIntroVideoBool&&at&&at.addEventListener(\"click\",(function(e){e.preventDefault(),function(){if(gameData.games[0].useIntroVideoBool){try{player.pauseVideo()}catch(e){console.log(e.message)}window.localStorage.setItem(\"hideVideo\",\"1\"),document.getElementById(\"player\").remove()}$e()}()})),et.addEventListener(\"click\",(function(e){if(e.preventDefault(),gameData.games[0].gameImitateBGVideoSrc&&document.getElementById(\"gameVid_0\").play(),gameData.games[0].useIntroVideoBool&&\"1\"!=window.localStorage.getItem(\"hideVideo\"))try{We()}catch(e){console.log(e.message),$e()}else if(it.checked)$e();else{var t=gsap.timeline(),a=gsap.timeline(),l=document.getElementById(\"game-intro__link-row\");if(null===document.getElementById(gameData.games[0].gameId+\"--consentErrorMsgCol\")){a.fromTo(\"#\"+gameData.games[0].gameId+\"--consent-label\",{scale:1},{scale:1.2,duration:.5,ease:\"Power4.out\"}),a.to(\"#\"+gameData.games[0].gameId+\"--consent-label\",{scale:1,duration:.5,delay:.5}),p(l,\"div\",{class:\"col-12 mt-4\",id:gameData.games[0].gameId+\"--consentErrorMsgCol\"}),p(document.getElementById(gameData.games[0].gameId+\"--consentErrorMsgCol\"),\"p\",{class:\"consent-error-msg mb-0\",id:gameData.games[0].gameId+\"--consentErrorMsg\"});var n=document.getElementById(gameData.games[0].gameId+\"--consentErrorMsg\");n.innerHTML=gameData.games[0].gameAgeGateErrorMessage,t.to(\"#\"+gameData.games[0].gameId+\"--consentErrorMsg\",{opacity:1,duration:.75}),t.to(\"#\"+gameData.games[0].gameId+\"--consentErrorMsg\",{opacity:0,duration:.75,delay:10,onComplete:nt,onCompleteParams:[n]})}}})),null!==tt&&tt.addEventListener(\"click\",(function(e){e.preventDefault(),Ze()})),lt.addEventListener(\"click\",(function(e){e.preventDefault(),Ke()})),gameData.games[0].useIntroVideoBool&&document.body.addEventListener(\"keydown\",(function(e){\"MediaPlayPause\"===e.key&&setTimeout((function(){player.pauseVideo()}),200)})),Array.from(Me).forEach((function(e){e.addEventListener(\"click\",Qe)})),Array.from(Se).forEach((function(e){e.addEventListener(\"click\",Xe)})),document.addEventListener(\"click\",(function(e){if(e.target.classList.contains(\"authenticated-btn\")&&Qe(e),e.target.classList.contains(\"authenticated-modal-btn\")&&Xe(e),e.target.classList.contains(\"btn-keep-playing\")&&Ze(e),\"game-form__init-lp-intro--game\"===e.target.id)if(e.preventDefault(),Ae(),window.scrollTo(0,0),\"1\"!=window.localStorage.getItem(\"hideVideo\"))try{We()}catch(e){console.log(e.message),$e()}else $e();\"game-form__init-game-menu\"!==e.target.id&&\"btn--return-to-menu\"!==e.target.id||(e.preventDefault(),Ze(e))})),window.addEventListener(\"orientationchange\",(function(e){0==window.orientation&&(document.body.classList.contains(\"game-active\")&&document.body.classList.remove(\"game-active\"),Ke())})),window.addEventListener(\"ajaxBeginCallback\",(function(e){var t=document.getElementById(\"firstName-\"+e.detail),a=document.getElementById(\"lastName-\"+e.detail),l=document.getElementById(\"dob-\"+e.detail),n=document.getElementById(\"email-\"+e.detail);be=t.value,we=a.value,Be=l.value,Le=n.value})),window.addEventListener(\"ajaxSuccessCallback\",(function(e){var t=document.getElementById(\"promotion-form__intro\");e.detail.includes(\"landing\")&&((!document.getElementById(\"termsAgree-\"+he)||document.getElementById(\"termsAgree-\"+he).checked)&&(t.classList.add(\"d-none\"),v(\"userEnteredContest-\"+xe,\"true\",\"30\")),document.getElementById(\"termsAgree-\"+he).checked),e.detail.includes(\"level\")&&(!document.getElementById(\"termsAgree-\"+he)||document.getElementById(\"termsAgree-\"+he).checked)&&(document.getElementById(\"modal-card--finished-\"+gameData.games[0].levels[fe].levelID+\"-copy\").classList.add(\"user-entered-contest\"),document.getElementById(\"modal-title--finished-\"+e.detail).classList.add(\"d-none\"),document.getElementById(\"modal-copy--finished-\"+e.detail).classList.add(\"d-none\"),v(\"userEnteredContest-\"+e.detail,\"true\",\"30\")),v(\"userContestDetails\",[be,we,Be,Le],\"30\")}))}))}).call(this,a(\"yLpj\"),a(\"lTfz\"))}},[[\"eWSr\",0,1]]]);"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA","sourceRoot":""}