From 6f448b0c60bf7cc66d000b927cadf78bfc2ffb44 Mon Sep 17 00:00:00 2001 From: Steven Brooks Date: Wed, 18 Jan 2023 14:40:11 +0700 Subject: [PATCH] Final commit Forgot to delete unused bits of code. --- script.js | 19 ------------------- 1 file changed, 19 deletions(-) diff --git a/script.js b/script.js index b68dbb1..0abec45 100644 --- a/script.js +++ b/script.js @@ -19,12 +19,6 @@ function playMusic() { music.play(); } -// setTimeout( () => { -// music.src = 'audio/song.mp3'; -// music.play(); -// }, 2000); - - const toggleSound = document.querySelector('.toggle-sound'); let soundStatus = false; toggleSound.addEventListener('click', () => { @@ -41,19 +35,6 @@ toggleSound.addEventListener('click', () => { toggleSound.innerHTML = 'Sound On'; } }) -// let soundStatus = true; -// toggleSound.addEventListener('click', soundOff); -// function soundOff() { -// soundStatus = false; -// if(music.paused && music.currentTime > 0 && !music.ended) { -// music.play(); -// soundStatus = true; -// } else if(music.ended) { -// music.play(); -// } else { -// music.pause(); -// } -// } // SCOREBOX const scoreBox = document.querySelector('.score-box');