Skip to content

Commit 7cef9e9

Browse files
minor fixes
1 parent 60e03c9 commit 7cef9e9

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

script.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,14 +31,15 @@ function addInstructions() {
3131
}
3232

3333
function openInstructions() {
34-
addInstructions();
3534
gameInstructions.style.display = "block";
3635
}
3736

3837
function closeInstructions() {
3938
gameInstructions.style.display = "none";
4039
}
4140

41+
addInstructions();
42+
4243
// AMBIENCE
4344
let backgroundMusic = new Audio("./sounds/music.mp3");
4445
backgroundMusic.loop = true;
@@ -69,7 +70,6 @@ function createCloud() {
6970
const cloudDetail = getRandomCloud();
7071
const cloudStyle = cloudDetail.name;
7172
const cloudWidth = cloudDetail.width;
72-
console.log(cloudWidth);
7373

7474
newCloud.classList.add("cloud", cloudStyle);
7575
ambience.appendChild(newCloud);
@@ -97,7 +97,7 @@ let cloudTimeOut;
9797
function handleEnvironment() {
9898
if (!gameOver) {
9999
createCloud();
100-
cloudTimeOut = setTimeout(handleEnvironment, Math.random() * 3000);
100+
cloudTimeOut = setTimeout(handleEnvironment, Math.random() * 4000);
101101
}
102102
}
103103

0 commit comments

Comments
 (0)