diff --git a/asset-manifest.json b/asset-manifest.json index 4cc3e1688..af5bb21e3 100644 --- a/asset-manifest.json +++ b/asset-manifest.json @@ -1,7 +1,7 @@ { "files": { - "main.css": "/Transcendence/static/css/main.9c442d42.css", - "main.js": "/Transcendence/static/js/main.cbc48556.js", + "main.css": "/Transcendence/static/css/main.50a4b450.css", + "main.js": "/Transcendence/static/js/main.8f8d8139.js", "static/js/496.b48b2ec3.chunk.js": "/Transcendence/static/js/496.b48b2ec3.chunk.js", "static/media/404.mp4": "/Transcendence/static/media/404.036827f1db48d0ae1d47.mp4", "static/media/welcomebg.jpg": "/Transcendence/static/media/welcomebg.e865aad312e9f209a8e9.jpg", @@ -29,12 +29,12 @@ "static/media/slick.ttf": "/Transcendence/static/media/slick.c94f7671dcc99dce43e2.ttf", "static/media/slick.woff": "/Transcendence/static/media/slick.295183786cd8a1389865.woff", "index.html": "/Transcendence/index.html", - "main.9c442d42.css.map": "/Transcendence/static/css/main.9c442d42.css.map", - "main.cbc48556.js.map": "/Transcendence/static/js/main.cbc48556.js.map", + "main.50a4b450.css.map": "/Transcendence/static/css/main.50a4b450.css.map", + "main.8f8d8139.js.map": "/Transcendence/static/js/main.8f8d8139.js.map", "496.b48b2ec3.chunk.js.map": "/Transcendence/static/js/496.b48b2ec3.chunk.js.map" }, "entrypoints": [ - "static/css/main.9c442d42.css", - "static/js/main.cbc48556.js" + "static/css/main.50a4b450.css", + "static/js/main.8f8d8139.js" ] } \ No newline at end of file diff --git a/index.html b/index.html index 7ea468d4b..361bde8cb 100644 --- a/index.html +++ b/index.html @@ -1 +1 @@ -
p+d/2?r+=n*b*x:m
{let n=p;m>p+d/2?n+=440*b*x:m
{let n=Math.abs((t.width-Math.abs(f))/g),r=m+v*n;r=r>t.height?Math.abs(t.height-r%t.height):r<0?Math.abs(r%t.height):Math.abs(r);let i=p;r>p+d/2+10?i+=500*b*x:r
{let n=p;n=m-d/2,n=Math.max(0,Math.min(n,t.height-d)),p=n,e.fillRect(t.width-u,p,u,d)})(a,r),(e=>{if(f+=g*b*x,m+=v*b*x,m<0?(m=2,v=-v):m>e.height&&(m=e.height-2,v=-v),fh&&m e.width&&(f=e.width/2,m=e.height/2,g=-300,v=-20,s+=1,n=5,i(s))})(r),(e=>{e.beginPath(),e.arc(f,m,8*x,0,2*Math.PI),e.fillStyle="#00FF00",e.fill(),e.closePath()})(a),((e,t)=>{e.fillStyle="#FFFFFF",e.font="80px Helvetica",e.fillText("".concat(s),t.width/2-100,100),e.fillText("".concat(l),t.width/2+60,100)})(a,r),requestAnimationFrame(w),c.current&&(S.ArrowUp||S.w?h-=n*x:(S.ArrowDown||S.s)&&(h+=n*x),h=Math.max(0,Math.min(h,c.current.height-d)))};return(0,t.useEffect)((()=>{const e=e=>{S[e.key]=!0},t=e=>{if(c.current&&e.touches.length>0){const t=c.current.getBoundingClientRect(),n=e.touches[0].clientY-t.top-window.scrollY;h=n-d/2,h=Math.max(0,Math.min(h,c.current.height-d))}};return window.addEventListener("keydown",e),window.addEventListener("keyup",(e=>{S[e.key]=!1})),document.addEventListener("touchmove",t),window.addEventListener("resize",(()=>ji(c,true,u,d,x,y,f,m,h,p))),ji(c,true,u,d,x,y,f,m,h,p),w(0),()=>{document.removeEventListener("keydown",e),document.removeEventListener("touchmove",t),window.removeEventListener("resize",ji)}}),[c]),(0,he.jsx)("div",{className:"flex justify-center items-center h-screen",children:10===r||10===a?10===r?(0,he.jsx)(zi,{GameCanvas:Xi,backgroundImage:Ii,WelcomeButtonStyle:ti,BackButton:ni}):(0,he.jsx)(Fi,{GameCanvas:Xi,backgroundImage:Ii,WelcomeButtonStyle:ti,BackButton:ni}):(0,he.jsx)(he.Fragment,{children:(0,he.jsx)("canvas",{ref:c,className:"border-8 border-solid border-white",style:{backgroundColor:"#0F0F0F"}})})})},qi=()=>{const{t:e}=x(),n=ht(),r=ut(),[i,a]=(0,t.useState)(!1),[o,s]=(0,t.useState)(0);return(0,he.jsxs)("div",{id:"aiP",className:"flex justify-center items-center h-screen",children:[(0,he.jsx)(Vi,{location:r,page:"aiP"}),i?(0,he.jsx)(Xi,{className:"m-4",t:e,navigate:n,aiDifficulty:o}):(0,he.jsxs)("div",{className:"relative",children:[(0,he.jsx)("img",{src:Ii,style:{width:"80vw",height:"45vw",objectFit:"cover"},alt:"Background",className:"rounded-xl shadow-lg"}),(0,he.jsxs)("div",{className:"absolute top-1/2 left-1/2 transform -translate-x-1/2 -translate-y-1/2 text-center",children:[(0,he.jsx)("button",{onClick:()=>{a(!0)},className:ti,children:e("Start Game")}),(0,he.jsxs)("div",{className:"relative",children:["Level: ",o]}),(0,he.jsx)("div",{style:{display:"flex",justifyContent:"center"},children:(0,he.jsx)("input",{type:"range",min:"0",max:"3",value:o,onChange:e=>s(parseInt(e.target.value)),style:{width:"150px",height:"25px"}})})]}),(0,he.jsx)(ni,{navigate:n,t:e})]})]})},Yi="160",Ki=1,Ji=2,Zi=3,$i=0,Qi=1,ea=100,ta=0,na=1,ra=2,ia=0,aa=1,oa=2,sa=3,la=4,ca=5,ua=6,da=301,ha=302,pa=303,fa=304,ma=306,ga=1e3,va=1001,ya=1002,xa=1003,_a=1004,ba=1005,Sa=1006,wa=1008,Ea=1009,Ma=1012,Ta=1013,Aa=1014,Ra=1015,Ca=1016,Pa=1020,La=1023,Na=1026,Oa=1027,Ua=33776,Da=33777,ka=33778,Ia=33779,Fa=36492,za=2300,ja=2301,Ba=2302,Ha=2400,Va=2401,Ga=2402,Wa=3001,Xa="",qa="srgb",Ya="srgb-linear",Ka="display-p3",Ja="display-p3-linear",Za="linear",$a="srgb",Qa="rec709",eo="p3",to=7680,no=35044,ro="300 es",io=1035,ao=2e3,oo=2001;class so{addEventListener(e,t){void 0===this._listeners&&(this._listeners={});const n=this._listeners;void 0===n[e]&&(n[e]=[]),-1===n[e].indexOf(t)&&n[e].push(t)}hasEventListener(e,t){if(void 0===this._listeners)return!1;const n=this._listeners;return void 0!==n[e]&&-1!==n[e].indexOf(t)}removeEventListener(e,t){if(void 0===this._listeners)return;const n=this._listeners[e];if(void 0!==n){const e=n.indexOf(t);-1!==e&&n.splice(e,1)}}dispatchEvent(e){if(void 0===this._listeners)return;const t=this._listeners[e.type];if(void 0!==t){e.target=this;const n=t.slice(0);for(let t=0,r=n.length;t