diff --git a/404.html b/404.html index 546e2999d985652222c96791491ca77df3211b6e..4bd4f073c330f525cb3ebeb4eeab12ce2b304c8f 100644 --- a/404.html +++ b/404.html @@ -6,12 +6,12 @@ <title>Erreur 404</title> </head> <body> - <div class="h-100 container"> + <div class="h-100"> <div id="canvas-container" style="display: none;"> - <canvas id="canvas"></canvas> - <div style="color: #9EFD38; font-size: 20px;"> + <div style="color: #FF69B4; font-size: 30px;"> Score : <span id="score">0</span> Combo : <span id="combo">1</span> </div> + <canvas id="canvas"></canvas> </div> <div class="row text-center" id="main"> <h1 class="h1-404 text-center">Erreur 404</h1> diff --git a/404/oliver.png b/404/olivier.png similarity index 100% rename from 404/oliver.png rename to 404/olivier.png diff --git a/src/404.js b/src/404.js index d8e7aae4a17090c1093f5700626eb5998e7f4bce..5415e9a3d30a7941ab49b24b1668fc752fd85fa8 100644 --- a/src/404.js +++ b/src/404.js @@ -39,7 +39,7 @@ $(document).ready(function() { for(var i = 0; i < images_src.length; i++) { var img = new Image(); // width, height values are optional params img.src = images_src[i]; - images.push(img); + images.push(img); } }); @@ -73,13 +73,14 @@ canvas.addEventListener('click', function(event) { function resizeCanvas() { canvas.width = window.innerWidth; - canvas.height = window.innerHeight; + canvas.height = window.innerHeight - 70; /* * Your drawings need to be inside this function otherwise they will be reset when * you resize the browser window and the canvas goes will be cleared. */ - animate(); + if (running) + animate(); } function reset() {